From 5f2c3661e2b017edf678f0539dd71fffed5a904d Mon Sep 17 00:00:00 2001 From: "github-actions[bot]" Date: Mon, 20 Jul 2026 22:19:58 +0000 Subject: [PATCH] chore: update schemas and regenerate all SDK clients Auto-generated by schema-propagation workflow. Source: constructive-db@4be0322f295 --- .../cli-admin/references/org-is-manager-of.md | 4 +- .agents/skills/cli-api/SKILL.md | 6 +- .../skills/cli-api/references/domain-event.md | 68 + .../cli-api/references/domain-verification.md | 68 + .../cli-api/references/managed-domain.md | 6 +- .../cli-api/references/request-database.md | 2 +- .../cli-api/references/resolve-http-route.md | 4 +- .agents/skills/cli-compute/SKILL.md | 14 +- .../references/function-definition.md | 6 +- .../references/function-invocation-attempt.md | 68 + .../platform-function-definition.md | 6 +- .../platform-function-invocation-attempt.md | 68 + .../platform-resource-declared-capacity.md | 68 + ...platform-resource-installations-install.md | 4 +- ...latform-resource-installations-rollback.md | 4 +- ...atform-resource-installations-uninstall.md | 4 +- ...platform-resource-installations-upgrade.md | 4 +- .../platform-resource-utilization.md | 68 + .../references/resource-declared-capacity.md | 68 + .../resource-installations-install.md | 4 +- .../resource-installations-rollback.md | 4 +- .../resource-installations-uninstall.md | 4 +- .../resource-installations-upgrade.md | 4 +- .../references/resource-utilization.md | 68 + .agents/skills/cli-modules/SKILL.md | 10 +- .../references/api-surface-module.md | 68 + .../cli-modules/references/app-module.md | 68 + .../cli-modules/references/catalog-module.md | 68 + .../references/database-provision-module.md | 6 +- .../cli-modules/references/domain-module.md | 68 + .../references/function-invocation-module.md | 6 +- .../references/provision-spatial-relation.md | 4 +- .../cli-modules/references/route-module.md | 68 + .../references/site-surface-module.md | 68 + .../references/org-is-manager-of.md | 4 +- .agents/skills/hooks-api/SKILL.md | 6 +- .../hooks-api/references/domain-event.md | 34 + .../references/domain-verification.md | 34 + .../hooks-api/references/managed-domain.md | 8 +- .../hooks-api/references/request-database.md | 2 +- .../references/resolve-http-route.md | 4 +- .agents/skills/hooks-compute/SKILL.md | 14 +- .../references/function-invocation-attempt.md | 34 + .../platform-function-definition.md | 8 +- .../platform-function-invocation-attempt.md | 34 + .../platform-resource-declared-capacity.md | 31 + ...platform-resource-installations-install.md | 4 +- ...latform-resource-installations-rollback.md | 4 +- ...atform-resource-installations-uninstall.md | 4 +- ...platform-resource-installations-upgrade.md | 4 +- .../references/platform-resource-usage-log.md | 2 +- .../platform-resource-utilization.md | 31 + .../references/resource-declared-capacity.md | 31 + .../resource-installations-install.md | 4 +- .../resource-installations-rollback.md | 4 +- .../resource-installations-uninstall.md | 4 +- .../resource-installations-upgrade.md | 4 +- .../references/resource-usage-log.md | 2 +- .../references/resource-utilization.md | 31 + .agents/skills/hooks-modules/SKILL.md | 10 +- .../references/api-surface-module.md | 34 + .../hooks-modules/references/app-module.md | 34 + .../references/catalog-module.md | 34 + .../references/database-provision-module.md | 8 +- .../hooks-modules/references/domain-module.md | 34 + .../references/function-invocation-module.md | 8 +- .../hooks-modules/references/route-module.md | 34 + .../references/site-surface-module.md | 34 + .../orm-admin/references/org-is-manager-of.md | 4 +- .agents/skills/orm-api/SKILL.md | 6 +- .../skills/orm-api/references/domain-event.md | 34 + .../orm-api/references/domain-verification.md | 34 + .../orm-api/references/managed-domain.md | 8 +- .../orm-api/references/request-database.md | 2 +- .../orm-api/references/resolve-http-route.md | 4 +- .agents/skills/orm-compute/SKILL.md | 16 +- .../references/function-invocation-attempt.md | 34 + .../platform-function-definition.md | 4 +- .../platform-function-invocation-attempt.md | 34 + .../platform-resource-declared-capacity.md | 34 + ...platform-resource-installations-install.md | 4 +- ...latform-resource-installations-rollback.md | 4 +- ...atform-resource-installations-uninstall.md | 4 +- ...platform-resource-installations-upgrade.md | 4 +- .../references/platform-resource-usage-log.md | 2 +- .../platform-resource-utilization.md | 34 + .../references/resource-declared-capacity.md | 34 + .../resource-installations-install.md | 4 +- .../resource-installations-rollback.md | 4 +- .../resource-installations-uninstall.md | 4 +- .../resource-installations-upgrade.md | 4 +- .../references/resource-usage-log.md | 2 +- .../references/resource-utilization.md | 34 + .agents/skills/orm-modules/SKILL.md | 12 +- .../references/api-surface-module.md | 34 + .../orm-modules/references/app-module.md | 34 + .../orm-modules/references/catalog-module.md | 34 + .../references/database-provision-module.md | 8 +- .../orm-modules/references/domain-module.md | 34 + .../references/function-invocation-module.md | 4 +- .../orm-modules/references/route-module.md | 34 + .../references/site-surface-module.md | 34 + pgpm/export/src/meta-export-tables.json | 30 + sdk/constructive-cli/src/admin/cli/README.md | 8 +- .../admin/cli/commands/org-is-manager-of.ts | 16 +- sdk/constructive-cli/src/admin/orm/README.md | 10 +- .../src/admin/orm/query/index.ts | 20 +- sdk/constructive-cli/src/api/README.md | 2 +- sdk/constructive-cli/src/api/cli/README.md | 82 +- sdk/constructive-cli/src/api/cli/commands.ts | 6 +- .../src/api/cli/commands/domain-event.ts | 385 +++ .../api/cli/commands/domain-verification.ts | 511 +++ .../src/api/cli/commands/managed-domain.ts | 44 + .../src/api/cli/commands/request-database.ts | 2 +- .../api/cli/commands/resolve-http-route.ts | 12 +- sdk/constructive-cli/src/api/orm/README.md | 102 +- sdk/constructive-cli/src/api/orm/index.ts | 4 + .../src/api/orm/input-types.ts | 656 +++- .../src/api/orm/models/domainEvent.ts | 245 ++ .../src/api/orm/models/domainVerification.ts | 245 ++ .../src/api/orm/models/index.ts | 2 + .../src/api/orm/mutation/index.ts | 2 +- .../src/api/orm/query/index.ts | 12 +- sdk/constructive-cli/src/compute/README.md | 2 +- .../src/compute/cli/README.md | 285 +- .../src/compute/cli/commands.ts | 22 +- .../cli/commands/function-definition.ts | 19 - .../commands/function-invocation-attempt.ts | 489 +++ .../commands/platform-function-definition.ts | 63 +- .../platform-function-invocation-attempt.ts | 474 +++ ...=> platform-resource-declared-capacity.ts} | 38 +- ...ly.ts => platform-resource-utilization.ts} | 38 +- ...acity.ts => resource-declared-capacity.ts} | 38 +- ...ation-daily.ts => resource-utilization.ts} | 38 +- .../src/compute/orm/README.md | 311 +- sdk/constructive-cli/src/compute/orm/index.ts | 20 +- .../src/compute/orm/input-types.ts | 1249 +++++--- .../compute/orm/models/declaredCapacity.ts | 134 - .../orm/models/functionInvocationAttempt.ts | 252 ++ .../src/compute/orm/models/index.ts | 10 +- .../orm/models/platformDeclaredCapacity.ts | 136 - .../platformFunctionInvocationAttempt.ts | 280 ++ .../platformResourceDeclaredCapacity.ts | 154 + .../orm/models/platformResourceUtilization.ts | 143 + .../platformResourceUtilizationDaily.ts | 154 - .../orm/models/resourceDeclaredCapacity.ts | 136 + .../compute/orm/models/resourceUtilization.ts | 134 + .../orm/models/resourceUtilizationDaily.ts | 136 - sdk/constructive-cli/src/modules/README.md | 2 +- .../src/modules/cli/README.md | 280 +- .../src/modules/cli/commands.ts | 14 +- .../cli/commands/api-surface-module.ts | 559 ++++ .../src/modules/cli/commands/app-module.ts | 644 ++++ .../modules/cli/commands/catalog-module.ts | 845 +++++ .../cli/commands/database-provision-module.ts | 22 + .../src/modules/cli/commands/domain-module.ts | 647 ++++ .../commands/function-invocation-module.ts | 44 + .../src/modules/cli/commands/route-module.ts | 735 +++++ .../cli/commands/site-surface-module.ts | 559 ++++ .../src/modules/orm/README.md | 316 +- sdk/constructive-cli/src/modules/orm/index.ts | 12 + .../src/modules/orm/input-types.ts | 1907 ++++++++++- .../modules/orm/models/apiSurfaceModule.ts | 245 ++ .../src/modules/orm/models/appModule.ts | 245 ++ .../src/modules/orm/models/catalogModule.ts | 245 ++ .../src/modules/orm/models/domainModule.ts | 245 ++ .../src/modules/orm/models/index.ts | 6 + .../src/modules/orm/models/routeModule.ts | 245 ++ .../modules/orm/models/siteSurfaceModule.ts | 245 ++ .../src/admin/hooks/README.md | 8 +- .../hooks/queries/useOrgIsManagerOfQuery.ts | 6 +- .../src/admin/orm/README.md | 10 +- .../src/admin/orm/query/index.ts | 20 +- .../src/admin/schema-types.ts | 32 + .../src/agent/schema-types.ts | 32 + sdk/constructive-react/src/api/README.md | 2 +- .../src/api/hooks/README.md | 68 +- sdk/constructive-react/src/api/hooks/index.ts | 2 +- .../src/api/hooks/invalidation.ts | 52 + .../src/api/hooks/mutation-keys.ts | 20 + .../src/api/hooks/mutations/index.ts | 6 + .../mutations/useCreateDomainEventMutation.ts | 88 + .../useCreateDomainVerificationMutation.ts | 91 + .../mutations/useDeleteDomainEventMutation.ts | 98 + .../useDeleteDomainVerificationMutation.ts | 104 + .../mutations/useUpdateDomainEventMutation.ts | 110 + .../useUpdateDomainVerificationMutation.ts | 116 + .../src/api/hooks/queries/index.ts | 4 + .../api/hooks/queries/useDomainEventQuery.ts | 138 + .../api/hooks/queries/useDomainEventsQuery.ts | 145 + .../queries/useDomainVerificationQuery.ts | 144 + .../queries/useDomainVerificationsQuery.ts | 171 + .../hooks/queries/useResolveHttpRouteQuery.ts | 6 +- .../src/api/hooks/query-keys.ts | 20 + sdk/constructive-react/src/api/orm/README.md | 102 +- sdk/constructive-react/src/api/orm/index.ts | 4 + .../src/api/orm/input-types.ts | 656 +++- .../src/api/orm/models/domainEvent.ts | 245 ++ .../src/api/orm/models/domainVerification.ts | 245 ++ .../src/api/orm/models/index.ts | 2 + .../src/api/orm/mutation/index.ts | 2 +- .../src/api/orm/query/index.ts | 12 +- .../src/api/schema-types.ts | 435 ++- sdk/constructive-react/src/api/types.ts | 30 + .../src/auth/schema-types.ts | 32 + sdk/constructive-react/src/compute/README.md | 2 +- .../src/compute/hooks/README.md | 174 +- .../src/compute/hooks/index.ts | 2 +- .../src/compute/hooks/invalidation.ts | 208 +- .../src/compute/hooks/mutation-keys.ts | 116 +- .../src/compute/hooks/mutations/index.ts | 14 +- .../useCreateDeclaredCapacityMutation.ts | 91 - ...CreateFunctionInvocationAttemptMutation.ts | 97 + ...eCreatePlatformDeclaredCapacityMutation.ts | 91 - ...atformFunctionInvocationAttemptMutation.ts | 105 + ...latformResourceDeclaredCapacityMutation.ts | 105 + ...eCreatePlatformResourceUsageLogMutation.ts | 4 +- ...latformResourceUtilizationDailyMutation.ts | 105 - ...eatePlatformResourceUtilizationMutation.ts | 100 + ...eCreateResourceDeclaredCapacityMutation.ts | 91 + .../useCreateResourceUsageLogMutation.ts | 4 +- ...eCreateResourceUtilizationDailyMutation.ts | 91 - .../useCreateResourceUtilizationMutation.ts | 91 + ...DeleteFunctionInvocationAttemptMutation.ts | 110 + ...atformFunctionInvocationAttemptMutation.ts | 116 + ...eDeletePlatformResourceUsageLogMutation.ts | 4 +- .../useDeleteResourceUsageLogMutation.ts | 4 +- ...UpdateFunctionInvocationAttemptMutation.ts | 124 + ...atformFunctionInvocationAttemptMutation.ts | 130 + ...eUpdatePlatformResourceUsageLogMutation.ts | 4 +- .../useUpdateResourceUsageLogMutation.ts | 4 +- .../src/compute/hooks/queries/index.ts | 12 +- .../queries/useDeclaredCapacitiesQuery.ts | 163 - .../useFunctionInvocationAttemptQuery.ts | 151 + .../useFunctionInvocationAttemptsQuery.ts | 182 ++ .../usePlatformDeclaredCapacitiesQuery.ts | 182 -- ...ePlatformFunctionInvocationAttemptQuery.ts | 158 + ...PlatformFunctionInvocationAttemptsQuery.ts | 195 ++ ...PlatformResourceDeclaredCapacitiesQuery.ts | 194 ++ .../usePlatformResourceUsageLogQuery.ts | 8 +- .../usePlatformResourceUsageLogsQuery.ts | 8 +- ...PlatformResourceUtilizationDailiesQuery.ts | 194 -- .../usePlatformResourceUtilizationsQuery.ts | 182 ++ .../useResourceDeclaredCapacitiesQuery.ts | 182 ++ .../hooks/queries/useResourceUsageLogQuery.ts | 8 +- .../queries/useResourceUsageLogsQuery.ts | 8 +- .../useResourceUtilizationDailiesQuery.ts | 182 -- .../queries/useResourceUtilizationsQuery.ts | 174 + .../src/compute/hooks/query-keys.ts | 99 +- .../src/compute/orm/README.md | 311 +- .../src/compute/orm/index.ts | 20 +- .../src/compute/orm/input-types.ts | 1249 +++++--- .../compute/orm/models/declaredCapacity.ts | 134 - .../orm/models/functionInvocationAttempt.ts | 252 ++ .../src/compute/orm/models/index.ts | 10 +- .../orm/models/platformDeclaredCapacity.ts | 136 - .../platformFunctionInvocationAttempt.ts | 280 ++ .../platformResourceDeclaredCapacity.ts | 154 + .../orm/models/platformResourceUtilization.ts | 143 + .../platformResourceUtilizationDaily.ts | 154 - .../orm/models/resourceDeclaredCapacity.ts | 136 + .../compute/orm/models/resourceUtilization.ts | 134 + .../orm/models/resourceUtilizationDaily.ts | 136 - .../src/compute/schema-types.ts | 854 +++-- sdk/constructive-react/src/compute/types.ts | 95 +- .../src/config/schema-types.ts | 32 + .../src/infra/schema-types.ts | 32 + sdk/constructive-react/src/modules/README.md | 2 +- .../src/modules/hooks/README.md | 168 +- .../src/modules/hooks/index.ts | 2 +- .../src/modules/hooks/invalidation.ts | 153 + .../src/modules/hooks/mutation-keys.ts | 59 + .../src/modules/hooks/mutations/index.ts | 18 + .../useCreateApiSurfaceModuleMutation.ts | 91 + .../mutations/useCreateAppModuleMutation.ts | 88 + .../useCreateCatalogModuleMutation.ts | 88 + .../useCreateDomainModuleMutation.ts | 88 + .../mutations/useCreateRouteModuleMutation.ts | 88 + .../useCreateSiteSurfaceModuleMutation.ts | 91 + .../useDeleteApiSurfaceModuleMutation.ts | 98 + .../mutations/useDeleteAppModuleMutation.ts | 98 + .../useDeleteCatalogModuleMutation.ts | 98 + .../useDeleteDomainModuleMutation.ts | 98 + .../mutations/useDeleteRouteModuleMutation.ts | 98 + .../useDeleteSiteSurfaceModuleMutation.ts | 104 + .../useUpdateApiSurfaceModuleMutation.ts | 116 + .../mutations/useUpdateAppModuleMutation.ts | 110 + .../useUpdateCatalogModuleMutation.ts | 116 + .../useUpdateDomainModuleMutation.ts | 110 + .../mutations/useUpdateRouteModuleMutation.ts | 110 + .../useUpdateSiteSurfaceModuleMutation.ts | 116 + .../src/modules/hooks/queries/index.ts | 12 + .../hooks/queries/useApiSurfaceModuleQuery.ts | 138 + .../queries/useApiSurfaceModulesQuery.ts | 163 + .../hooks/queries/useAppModuleQuery.ts | 138 + .../hooks/queries/useAppModulesQuery.ts | 145 + .../hooks/queries/useCatalogModuleQuery.ts | 138 + .../hooks/queries/useCatalogModulesQuery.ts | 151 + .../hooks/queries/useDomainModuleQuery.ts | 138 + .../hooks/queries/useDomainModulesQuery.ts | 145 + .../hooks/queries/useRouteModuleQuery.ts | 138 + .../hooks/queries/useRouteModulesQuery.ts | 145 + .../queries/useSiteSurfaceModuleQuery.ts | 144 + .../queries/useSiteSurfaceModulesQuery.ts | 163 + .../src/modules/hooks/query-keys.ts | 60 + .../src/modules/orm/README.md | 316 +- .../src/modules/orm/index.ts | 12 + .../src/modules/orm/input-types.ts | 1907 ++++++++++- .../modules/orm/models/apiSurfaceModule.ts | 245 ++ .../src/modules/orm/models/appModule.ts | 245 ++ .../src/modules/orm/models/catalogModule.ts | 245 ++ .../src/modules/orm/models/domainModule.ts | 245 ++ .../src/modules/orm/models/index.ts | 6 + .../src/modules/orm/models/routeModule.ts | 245 ++ .../modules/orm/models/siteSurfaceModule.ts | 245 ++ .../src/modules/schema-types.ts | 1268 +++++++- sdk/constructive-react/src/modules/types.ts | 140 + .../src/objects/schema-types.ts | 32 + .../src/usage/schema-types.ts | 32 + sdk/constructive-sdk/schemas/admin.graphql | 66 +- sdk/constructive-sdk/schemas/agent.graphql | 52 + sdk/constructive-sdk/schemas/api.graphql | 1143 ++++++- sdk/constructive-sdk/schemas/auth.graphql | 52 + sdk/constructive-sdk/schemas/compute.graphql | 1952 +++++++++--- sdk/constructive-sdk/schemas/config.graphql | 52 + sdk/constructive-sdk/schemas/infra.graphql | 52 + sdk/constructive-sdk/schemas/modules.graphql | 2790 ++++++++++++++++- sdk/constructive-sdk/schemas/objects.graphql | 52 + sdk/constructive-sdk/schemas/usage.graphql | 52 + sdk/constructive-sdk/src/admin/orm/README.md | 10 +- .../src/admin/orm/query/index.ts | 20 +- sdk/constructive-sdk/src/api/README.md | 2 +- sdk/constructive-sdk/src/api/orm/README.md | 102 +- sdk/constructive-sdk/src/api/orm/index.ts | 4 + .../src/api/orm/input-types.ts | 656 +++- .../src/api/orm/models/domainEvent.ts | 245 ++ .../src/api/orm/models/domainVerification.ts | 245 ++ .../src/api/orm/models/index.ts | 2 + .../src/api/orm/mutation/index.ts | 2 +- .../src/api/orm/query/index.ts | 12 +- sdk/constructive-sdk/src/compute/README.md | 2 +- .../src/compute/orm/README.md | 311 +- sdk/constructive-sdk/src/compute/orm/index.ts | 20 +- .../src/compute/orm/input-types.ts | 1249 +++++--- .../compute/orm/models/declaredCapacity.ts | 134 - .../orm/models/functionInvocationAttempt.ts | 252 ++ .../src/compute/orm/models/index.ts | 10 +- .../orm/models/platformDeclaredCapacity.ts | 136 - .../platformFunctionInvocationAttempt.ts | 280 ++ .../platformResourceDeclaredCapacity.ts | 154 + .../orm/models/platformResourceUtilization.ts | 143 + .../platformResourceUtilizationDaily.ts | 154 - .../orm/models/resourceDeclaredCapacity.ts | 136 + .../compute/orm/models/resourceUtilization.ts | 134 + .../orm/models/resourceUtilizationDaily.ts | 136 - sdk/constructive-sdk/src/modules/README.md | 2 +- .../src/modules/orm/README.md | 316 +- sdk/constructive-sdk/src/modules/orm/index.ts | 12 + .../src/modules/orm/input-types.ts | 1907 ++++++++++- .../modules/orm/models/apiSurfaceModule.ts | 245 ++ .../src/modules/orm/models/appModule.ts | 245 ++ .../src/modules/orm/models/catalogModule.ts | 245 ++ .../src/modules/orm/models/domainModule.ts | 245 ++ .../src/modules/orm/models/index.ts | 6 + .../src/modules/orm/models/routeModule.ts | 245 ++ .../modules/orm/models/siteSurfaceModule.ts | 245 ++ sdk/migrate-client/schemas/migrate.graphql | 52 + 367 files changed, 46675 insertions(+), 6325 deletions(-) create mode 100644 .agents/skills/cli-api/references/domain-event.md create mode 100644 .agents/skills/cli-api/references/domain-verification.md create mode 100644 .agents/skills/cli-compute/references/function-invocation-attempt.md create mode 100644 .agents/skills/cli-compute/references/platform-function-invocation-attempt.md create mode 100644 .agents/skills/cli-compute/references/platform-resource-declared-capacity.md create mode 100644 .agents/skills/cli-compute/references/platform-resource-utilization.md create mode 100644 .agents/skills/cli-compute/references/resource-declared-capacity.md create mode 100644 .agents/skills/cli-compute/references/resource-utilization.md create mode 100644 .agents/skills/cli-modules/references/api-surface-module.md create mode 100644 .agents/skills/cli-modules/references/app-module.md create mode 100644 .agents/skills/cli-modules/references/catalog-module.md create mode 100644 .agents/skills/cli-modules/references/domain-module.md create mode 100644 .agents/skills/cli-modules/references/route-module.md create mode 100644 .agents/skills/cli-modules/references/site-surface-module.md create mode 100644 .agents/skills/hooks-api/references/domain-event.md create mode 100644 .agents/skills/hooks-api/references/domain-verification.md create mode 100644 .agents/skills/hooks-compute/references/function-invocation-attempt.md create mode 100644 .agents/skills/hooks-compute/references/platform-function-invocation-attempt.md create mode 100644 .agents/skills/hooks-compute/references/platform-resource-declared-capacity.md create mode 100644 .agents/skills/hooks-compute/references/platform-resource-utilization.md create mode 100644 .agents/skills/hooks-compute/references/resource-declared-capacity.md create mode 100644 .agents/skills/hooks-compute/references/resource-utilization.md create mode 100644 .agents/skills/hooks-modules/references/api-surface-module.md create mode 100644 .agents/skills/hooks-modules/references/app-module.md create mode 100644 .agents/skills/hooks-modules/references/catalog-module.md create mode 100644 .agents/skills/hooks-modules/references/domain-module.md create mode 100644 .agents/skills/hooks-modules/references/route-module.md create mode 100644 .agents/skills/hooks-modules/references/site-surface-module.md create mode 100644 .agents/skills/orm-api/references/domain-event.md create mode 100644 .agents/skills/orm-api/references/domain-verification.md create mode 100644 .agents/skills/orm-compute/references/function-invocation-attempt.md create mode 100644 .agents/skills/orm-compute/references/platform-function-invocation-attempt.md create mode 100644 .agents/skills/orm-compute/references/platform-resource-declared-capacity.md create mode 100644 .agents/skills/orm-compute/references/platform-resource-utilization.md create mode 100644 .agents/skills/orm-compute/references/resource-declared-capacity.md create mode 100644 .agents/skills/orm-compute/references/resource-utilization.md create mode 100644 .agents/skills/orm-modules/references/api-surface-module.md create mode 100644 .agents/skills/orm-modules/references/app-module.md create mode 100644 .agents/skills/orm-modules/references/catalog-module.md create mode 100644 .agents/skills/orm-modules/references/domain-module.md create mode 100644 .agents/skills/orm-modules/references/route-module.md create mode 100644 .agents/skills/orm-modules/references/site-surface-module.md create mode 100644 sdk/constructive-cli/src/api/cli/commands/domain-event.ts create mode 100644 sdk/constructive-cli/src/api/cli/commands/domain-verification.ts create mode 100644 sdk/constructive-cli/src/api/orm/models/domainEvent.ts create mode 100644 sdk/constructive-cli/src/api/orm/models/domainVerification.ts create mode 100644 sdk/constructive-cli/src/compute/cli/commands/function-invocation-attempt.ts create mode 100644 sdk/constructive-cli/src/compute/cli/commands/platform-function-invocation-attempt.ts rename sdk/constructive-cli/src/compute/cli/commands/{declared-capacity.ts => platform-resource-declared-capacity.ts} (75%) rename sdk/constructive-cli/src/compute/cli/commands/{platform-resource-utilization-daily.ts => platform-resource-utilization.ts} (79%) rename sdk/constructive-cli/src/compute/cli/commands/{platform-declared-capacity.ts => resource-declared-capacity.ts} (88%) rename sdk/constructive-cli/src/compute/cli/commands/{resource-utilization-daily.ts => resource-utilization.ts} (80%) delete mode 100644 sdk/constructive-cli/src/compute/orm/models/declaredCapacity.ts create mode 100644 sdk/constructive-cli/src/compute/orm/models/functionInvocationAttempt.ts delete mode 100644 sdk/constructive-cli/src/compute/orm/models/platformDeclaredCapacity.ts create mode 100644 sdk/constructive-cli/src/compute/orm/models/platformFunctionInvocationAttempt.ts create mode 100644 sdk/constructive-cli/src/compute/orm/models/platformResourceDeclaredCapacity.ts create mode 100644 sdk/constructive-cli/src/compute/orm/models/platformResourceUtilization.ts delete mode 100644 sdk/constructive-cli/src/compute/orm/models/platformResourceUtilizationDaily.ts create mode 100644 sdk/constructive-cli/src/compute/orm/models/resourceDeclaredCapacity.ts create mode 100644 sdk/constructive-cli/src/compute/orm/models/resourceUtilization.ts delete mode 100644 sdk/constructive-cli/src/compute/orm/models/resourceUtilizationDaily.ts create mode 100644 sdk/constructive-cli/src/modules/cli/commands/api-surface-module.ts create mode 100644 sdk/constructive-cli/src/modules/cli/commands/app-module.ts create mode 100644 sdk/constructive-cli/src/modules/cli/commands/catalog-module.ts create mode 100644 sdk/constructive-cli/src/modules/cli/commands/domain-module.ts create mode 100644 sdk/constructive-cli/src/modules/cli/commands/route-module.ts create mode 100644 sdk/constructive-cli/src/modules/cli/commands/site-surface-module.ts create mode 100644 sdk/constructive-cli/src/modules/orm/models/apiSurfaceModule.ts create mode 100644 sdk/constructive-cli/src/modules/orm/models/appModule.ts create mode 100644 sdk/constructive-cli/src/modules/orm/models/catalogModule.ts create mode 100644 sdk/constructive-cli/src/modules/orm/models/domainModule.ts create mode 100644 sdk/constructive-cli/src/modules/orm/models/routeModule.ts create mode 100644 sdk/constructive-cli/src/modules/orm/models/siteSurfaceModule.ts create mode 100644 sdk/constructive-react/src/api/hooks/mutations/useCreateDomainEventMutation.ts create mode 100644 sdk/constructive-react/src/api/hooks/mutations/useCreateDomainVerificationMutation.ts create mode 100644 sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainEventMutation.ts create mode 100644 sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainVerificationMutation.ts create mode 100644 sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainEventMutation.ts create mode 100644 sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainVerificationMutation.ts create mode 100644 sdk/constructive-react/src/api/hooks/queries/useDomainEventQuery.ts create mode 100644 sdk/constructive-react/src/api/hooks/queries/useDomainEventsQuery.ts create mode 100644 sdk/constructive-react/src/api/hooks/queries/useDomainVerificationQuery.ts create mode 100644 sdk/constructive-react/src/api/hooks/queries/useDomainVerificationsQuery.ts create mode 100644 sdk/constructive-react/src/api/orm/models/domainEvent.ts create mode 100644 sdk/constructive-react/src/api/orm/models/domainVerification.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreateDeclaredCapacityMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreateFunctionInvocationAttemptMutation.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformDeclaredCapacityMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformFunctionInvocationAttemptMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceDeclaredCapacityMutation.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationDailyMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceDeclaredCapacityMutation.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationDailyMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useDeleteFunctionInvocationAttemptMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformFunctionInvocationAttemptMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useUpdateFunctionInvocationAttemptMutation.ts create mode 100644 sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformFunctionInvocationAttemptMutation.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/queries/useDeclaredCapacitiesQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptsQuery.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/queries/usePlatformDeclaredCapacitiesQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptsQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceDeclaredCapacitiesQuery.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationDailiesQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationsQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/useResourceDeclaredCapacitiesQuery.ts delete mode 100644 sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationDailiesQuery.ts create mode 100644 sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationsQuery.ts delete mode 100644 sdk/constructive-react/src/compute/orm/models/declaredCapacity.ts create mode 100644 sdk/constructive-react/src/compute/orm/models/functionInvocationAttempt.ts delete mode 100644 sdk/constructive-react/src/compute/orm/models/platformDeclaredCapacity.ts create mode 100644 sdk/constructive-react/src/compute/orm/models/platformFunctionInvocationAttempt.ts create mode 100644 sdk/constructive-react/src/compute/orm/models/platformResourceDeclaredCapacity.ts create mode 100644 sdk/constructive-react/src/compute/orm/models/platformResourceUtilization.ts delete mode 100644 sdk/constructive-react/src/compute/orm/models/platformResourceUtilizationDaily.ts create mode 100644 sdk/constructive-react/src/compute/orm/models/resourceDeclaredCapacity.ts create mode 100644 sdk/constructive-react/src/compute/orm/models/resourceUtilization.ts delete mode 100644 sdk/constructive-react/src/compute/orm/models/resourceUtilizationDaily.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useCreateApiSurfaceModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useCreateAppModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useCreateCatalogModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useCreateDomainModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useCreateRouteModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useCreateSiteSurfaceModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useDeleteApiSurfaceModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useDeleteAppModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useDeleteCatalogModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useDeleteDomainModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useDeleteRouteModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useDeleteSiteSurfaceModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useUpdateApiSurfaceModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useUpdateAppModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useUpdateCatalogModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useUpdateDomainModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useUpdateRouteModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/mutations/useUpdateSiteSurfaceModuleMutation.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModuleQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModulesQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useAppModuleQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useAppModulesQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useCatalogModuleQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useCatalogModulesQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useDomainModuleQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useDomainModulesQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useRouteModuleQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useRouteModulesQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModuleQuery.ts create mode 100644 sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModulesQuery.ts create mode 100644 sdk/constructive-react/src/modules/orm/models/apiSurfaceModule.ts create mode 100644 sdk/constructive-react/src/modules/orm/models/appModule.ts create mode 100644 sdk/constructive-react/src/modules/orm/models/catalogModule.ts create mode 100644 sdk/constructive-react/src/modules/orm/models/domainModule.ts create mode 100644 sdk/constructive-react/src/modules/orm/models/routeModule.ts create mode 100644 sdk/constructive-react/src/modules/orm/models/siteSurfaceModule.ts create mode 100644 sdk/constructive-sdk/src/api/orm/models/domainEvent.ts create mode 100644 sdk/constructive-sdk/src/api/orm/models/domainVerification.ts delete mode 100644 sdk/constructive-sdk/src/compute/orm/models/declaredCapacity.ts create mode 100644 sdk/constructive-sdk/src/compute/orm/models/functionInvocationAttempt.ts delete mode 100644 sdk/constructive-sdk/src/compute/orm/models/platformDeclaredCapacity.ts create mode 100644 sdk/constructive-sdk/src/compute/orm/models/platformFunctionInvocationAttempt.ts create mode 100644 sdk/constructive-sdk/src/compute/orm/models/platformResourceDeclaredCapacity.ts create mode 100644 sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilization.ts delete mode 100644 sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilizationDaily.ts create mode 100644 sdk/constructive-sdk/src/compute/orm/models/resourceDeclaredCapacity.ts create mode 100644 sdk/constructive-sdk/src/compute/orm/models/resourceUtilization.ts delete mode 100644 sdk/constructive-sdk/src/compute/orm/models/resourceUtilizationDaily.ts create mode 100644 sdk/constructive-sdk/src/modules/orm/models/apiSurfaceModule.ts create mode 100644 sdk/constructive-sdk/src/modules/orm/models/appModule.ts create mode 100644 sdk/constructive-sdk/src/modules/orm/models/catalogModule.ts create mode 100644 sdk/constructive-sdk/src/modules/orm/models/domainModule.ts create mode 100644 sdk/constructive-sdk/src/modules/orm/models/routeModule.ts create mode 100644 sdk/constructive-sdk/src/modules/orm/models/siteSurfaceModule.ts diff --git a/.agents/skills/cli-admin/references/org-is-manager-of.md b/.agents/skills/cli-admin/references/org-is-manager-of.md index f484f6013..b0d5dcf33 100644 --- a/.agents/skills/cli-admin/references/org-is-manager-of.md +++ b/.agents/skills/cli-admin/references/org-is-manager-of.md @@ -7,7 +7,7 @@ Execute the orgIsManagerOf query ## Usage ```bash -csdk org-is-manager-of --pEntityId --pManagerId --pMaxDepth --pUserId +csdk org-is-manager-of --managerId --maxDepth --targetEntityId --userId ``` ## Examples @@ -15,5 +15,5 @@ csdk org-is-manager-of --pEntityId --pManagerId --pMaxDepth ### Run orgIsManagerOf ```bash -csdk org-is-manager-of --pEntityId --pManagerId --pMaxDepth --pUserId +csdk org-is-manager-of --managerId --maxDepth --targetEntityId --userId ``` diff --git a/.agents/skills/cli-api/SKILL.md b/.agents/skills/cli-api/SKILL.md index 7c634bfaf..be5d4ef7e 100644 --- a/.agents/skills/cli-api/SKILL.md +++ b/.agents/skills/cli-api/SKILL.md @@ -1,13 +1,13 @@ --- name: cli-api -description: CLI tool (csdk) for the api API — provides CRUD commands for 47 tables and 9 custom operations +description: CLI tool (csdk) for the api API — provides CRUD commands for 49 tables and 9 custom operations --- # cli-api -CLI tool (csdk) for the api API — provides CRUD commands for 47 tables and 9 custom operations +CLI tool (csdk) for the api API — provides CRUD commands for 49 tables and 9 custom operations ## Usage @@ -70,6 +70,8 @@ See the `references/` directory for detailed per-entity API documentation: - [database-transfer](references/database-transfer.md) - [default-privilege](references/default-privilege.md) - [domain](references/domain.md) +- [domain-event](references/domain-event.md) +- [domain-verification](references/domain-verification.md) - [embedding-chunk](references/embedding-chunk.md) - [enum](references/enum.md) - [field](references/field.md) diff --git a/.agents/skills/cli-api/references/domain-event.md b/.agents/skills/cli-api/references/domain-event.md new file mode 100644 index 000000000..957b5a2ee --- /dev/null +++ b/.agents/skills/cli-api/references/domain-event.md @@ -0,0 +1,68 @@ +# domainEvent + + + +CRUD operations for DomainEvent records via csdk CLI + +## Usage + +```bash +csdk domain-event list +csdk domain-event list --where.. --orderBy +csdk domain-event list --limit 10 --after +csdk domain-event find-first --where.. +csdk domain-event get --id +csdk domain-event create --eventType --managedDomainId --ownerId [--actorId ] [--domainVerificationId ] [--message ] [--metadata ] +csdk domain-event update --id [--actorId ] [--domainVerificationId ] [--eventType ] [--managedDomainId ] [--message ] [--metadata ] [--ownerId ] +csdk domain-event delete --id +``` + +## Examples + +### List domainEvent records + +```bash +csdk domain-event list +``` + +### List domainEvent records with pagination + +```bash +csdk domain-event list --limit 10 --offset 0 +``` + +### List domainEvent records with cursor pagination + +```bash +csdk domain-event list --limit 10 --after +``` + +### Find first matching domainEvent + +```bash +csdk domain-event find-first --where.id.equalTo +``` + +### List domainEvent records with field selection + +```bash +csdk domain-event list --select id,id +``` + +### List domainEvent records with filtering and ordering + +```bash +csdk domain-event list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a domainEvent + +```bash +csdk domain-event create --eventType --managedDomainId --ownerId [--actorId ] [--domainVerificationId ] [--message ] [--metadata ] +``` + +### Get a domainEvent by id + +```bash +csdk domain-event get --id +``` diff --git a/.agents/skills/cli-api/references/domain-verification.md b/.agents/skills/cli-api/references/domain-verification.md new file mode 100644 index 000000000..9ed3d730a --- /dev/null +++ b/.agents/skills/cli-api/references/domain-verification.md @@ -0,0 +1,68 @@ +# domainVerification + + + +CRUD operations for DomainVerification records via csdk CLI + +## Usage + +```bash +csdk domain-verification list +csdk domain-verification list --where.. --orderBy +csdk domain-verification list --limit 10 --after +csdk domain-verification find-first --where.. +csdk domain-verification get --id +csdk domain-verification create --managedDomainId --ownerId [--attempts ] [--error ] [--expiresAt ] [--lastCheckedAt ] [--method ] [--recordName ] [--recordType ] [--recordValue ] [--status ] [--verifiedAt ] +csdk domain-verification update --id [--attempts ] [--error ] [--expiresAt ] [--lastCheckedAt ] [--managedDomainId ] [--method ] [--ownerId ] [--recordName ] [--recordType ] [--recordValue ] [--status ] [--verifiedAt ] +csdk domain-verification delete --id +``` + +## Examples + +### List domainVerification records + +```bash +csdk domain-verification list +``` + +### List domainVerification records with pagination + +```bash +csdk domain-verification list --limit 10 --offset 0 +``` + +### List domainVerification records with cursor pagination + +```bash +csdk domain-verification list --limit 10 --after +``` + +### Find first matching domainVerification + +```bash +csdk domain-verification find-first --where.id.equalTo +``` + +### List domainVerification records with field selection + +```bash +csdk domain-verification list --select id,id +``` + +### List domainVerification records with filtering and ordering + +```bash +csdk domain-verification list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a domainVerification + +```bash +csdk domain-verification create --managedDomainId --ownerId [--attempts ] [--error ] [--expiresAt ] [--lastCheckedAt ] [--method ] [--recordName ] [--recordType ] [--recordValue ] [--status ] [--verifiedAt ] +``` + +### Get a domainVerification by id + +```bash +csdk domain-verification get --id +``` diff --git a/.agents/skills/cli-api/references/managed-domain.md b/.agents/skills/cli-api/references/managed-domain.md index 000565106..bb6ce9301 100644 --- a/.agents/skills/cli-api/references/managed-domain.md +++ b/.agents/skills/cli-api/references/managed-domain.md @@ -12,8 +12,8 @@ csdk managed-domain list --where.. --orderBy csdk managed-domain list --limit 10 --after csdk managed-domain find-first --where.. csdk managed-domain get --id -csdk managed-domain create --databaseId --domain [--annotations ] [--isWildcard ] [--tlsReadyAt ] [--tlsStatus ] [--verificationStatus ] [--verifiedAt ] -csdk managed-domain update --id [--annotations ] [--databaseId ] [--domain ] [--isWildcard ] [--tlsReadyAt ] [--tlsStatus ] [--verificationStatus ] [--verifiedAt ] +csdk managed-domain create --databaseId --domain [--allowPublicUsage ] [--annotations ] [--certStatus ] [--isWildcard ] [--tlsReadyAt ] [--tlsStatus ] [--verificationStatus ] [--verifiedAt ] +csdk managed-domain update --id [--allowPublicUsage ] [--annotations ] [--certStatus ] [--databaseId ] [--domain ] [--isWildcard ] [--tlsReadyAt ] [--tlsStatus ] [--verificationStatus ] [--verifiedAt ] csdk managed-domain delete --id ``` @@ -58,7 +58,7 @@ csdk managed-domain list --where.id.equalTo --orderBy ID_ASC ### Create a managedDomain ```bash -csdk managed-domain create --databaseId --domain [--annotations ] [--isWildcard ] [--tlsReadyAt ] [--tlsStatus ] [--verificationStatus ] [--verifiedAt ] +csdk managed-domain create --databaseId --domain [--allowPublicUsage ] [--annotations ] [--certStatus ] [--isWildcard ] [--tlsReadyAt ] [--tlsStatus ] [--verificationStatus ] [--verifiedAt ] ``` ### Get a managedDomain by id diff --git a/.agents/skills/cli-api/references/request-database.md b/.agents/skills/cli-api/references/request-database.md index e11482c52..e37cd366b 100644 --- a/.agents/skills/cli-api/references/request-database.md +++ b/.agents/skills/cli-api/references/request-database.md @@ -4,7 +4,7 @@ Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/.agents/skills/cli-api/references/resolve-http-route.md b/.agents/skills/cli-api/references/resolve-http-route.md index 8266c708f..fca7b70a2 100644 --- a/.agents/skills/cli-api/references/resolve-http-route.md +++ b/.agents/skills/cli-api/references/resolve-http-route.md @@ -7,7 +7,7 @@ Execute the resolveHttpRoute query ## Usage ```bash -csdk resolve-http-route --pHost --pMethod --pPath +csdk resolve-http-route --requestHost --requestMethod --requestPath ``` ## Examples @@ -15,5 +15,5 @@ csdk resolve-http-route --pHost --pMethod --pPath ### Run resolveHttpRoute ```bash -csdk resolve-http-route --pHost --pMethod --pPath +csdk resolve-http-route --requestHost --requestMethod --requestPath ``` diff --git a/.agents/skills/cli-compute/SKILL.md b/.agents/skills/cli-compute/SKILL.md index aba2f4802..9fd7d6a2f 100644 --- a/.agents/skills/cli-compute/SKILL.md +++ b/.agents/skills/cli-compute/SKILL.md @@ -1,13 +1,13 @@ --- name: cli-compute -description: CLI tool (csdk) for the compute API — provides CRUD commands for 65 tables and 29 custom operations +description: CLI tool (csdk) for the compute API — provides CRUD commands for 67 tables and 29 custom operations --- # cli-compute -CLI tool (csdk) for the compute API — provides CRUD commands for 65 tables and 29 custom operations +CLI tool (csdk) for the compute API — provides CRUD commands for 67 tables and 29 custom operations ## Usage @@ -57,7 +57,6 @@ See the `references/` directory for detailed per-entity API documentation: - [auth](references/auth.md) - [config](references/config.md) - [db-preset](references/db-preset.md) -- [declared-capacity](references/declared-capacity.md) - [function-api-binding](references/function-api-binding.md) - [function-definition](references/function-definition.md) - [function-deployment](references/function-deployment.md) @@ -71,6 +70,7 @@ See the `references/` directory for detailed per-entity API documentation: - [function-graph-object](references/function-graph-object.md) - [function-graph-ref](references/function-graph-ref.md) - [function-graph-store](references/function-graph-store.md) +- [function-invocation-attempt](references/function-invocation-attempt.md) - [function-invocation](references/function-invocation.md) - [get-all-tree-nodes-record](references/get-all-tree-nodes-record.md) - [infra-commit](references/infra-commit.md) @@ -81,12 +81,12 @@ See the `references/` directory for detailed per-entity API documentation: - [integration-provider](references/integration-provider.md) - [namespace](references/namespace.md) - [namespace-event](references/namespace-event.md) -- [platform-declared-capacity](references/platform-declared-capacity.md) - [platform-function-api-binding](references/platform-function-api-binding.md) - [platform-function-definition](references/platform-function-definition.md) - [platform-function-deployment](references/platform-function-deployment.md) - [platform-function-deployment-event](references/platform-function-deployment-event.md) - [platform-function-execution-log](references/platform-function-execution-log.md) +- [platform-function-invocation-attempt](references/platform-function-invocation-attempt.md) - [platform-function-invocation](references/platform-function-invocation.md) - [platform-infra-commit](references/platform-infra-commit.md) - [platform-infra-get-all-tree-nodes-record](references/platform-infra-get-all-tree-nodes-record.md) @@ -96,26 +96,28 @@ See the `references/` directory for detailed per-entity API documentation: - [platform-namespace](references/platform-namespace.md) - [platform-namespace-event](references/platform-namespace-event.md) - [platform-resource](references/platform-resource.md) +- [platform-resource-declared-capacity](references/platform-resource-declared-capacity.md) - [platform-resource-definition](references/platform-resource-definition.md) - [platform-resource-event](references/platform-resource-event.md) - [platform-resource-installation](references/platform-resource-installation.md) - [platform-resource-status-check](references/platform-resource-status-check.md) - [platform-resource-usage-log](references/platform-resource-usage-log.md) - [platform-resource-usage-summary](references/platform-resource-usage-summary.md) -- [platform-resource-utilization-daily](references/platform-resource-utilization-daily.md) +- [platform-resource-utilization](references/platform-resource-utilization.md) - [platform-resources-health](references/platform-resources-health.md) - [platform-resources-requirements-state](references/platform-resources-requirements-state.md) - [platform-resources-resolved-requirement](references/platform-resources-resolved-requirement.md) - [platform-webhook-endpoint](references/platform-webhook-endpoint.md) - [platform-webhook-event](references/platform-webhook-event.md) - [resource](references/resource.md) +- [resource-declared-capacity](references/resource-declared-capacity.md) - [resource-definition](references/resource-definition.md) - [resource-event](references/resource-event.md) - [resource-installation](references/resource-installation.md) - [resource-status-check](references/resource-status-check.md) - [resource-usage-log](references/resource-usage-log.md) - [resource-usage-summary](references/resource-usage-summary.md) -- [resource-utilization-daily](references/resource-utilization-daily.md) +- [resource-utilization](references/resource-utilization.md) - [resources-health](references/resources-health.md) - [resources-requirements-state](references/resources-requirements-state.md) - [resources-resolved-requirement](references/resources-resolved-requirement.md) diff --git a/.agents/skills/cli-compute/references/function-definition.md b/.agents/skills/cli-compute/references/function-definition.md index 3001e925e..42f8c39b1 100644 --- a/.agents/skills/cli-compute/references/function-definition.md +++ b/.agents/skills/cli-compute/references/function-definition.md @@ -12,8 +12,8 @@ csdk function-definition list --where.. --orderBy csdk function-definition list --limit 10 --after csdk function-definition find-first --where.. csdk function-definition get --id -csdk function-definition create --category --databaseId --name --taskIdentifier [--accessChannels ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] -csdk function-definition update --id [--accessChannels ] [--category ] [--concurrency ] [--databaseId ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--name ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--taskIdentifier ] [--timeoutSeconds ] [--volatile ] +csdk function-definition create --category --databaseId --name [--accessChannels ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] +csdk function-definition update --id [--accessChannels ] [--category ] [--concurrency ] [--databaseId ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--name ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] csdk function-definition delete --id ``` @@ -58,7 +58,7 @@ csdk function-definition list --where.id.equalTo --orderBy ID_ASC ### Create a functionDefinition ```bash -csdk function-definition create --category --databaseId --name --taskIdentifier [--accessChannels ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] +csdk function-definition create --category --databaseId --name [--accessChannels ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] ``` ### Get a functionDefinition by id diff --git a/.agents/skills/cli-compute/references/function-invocation-attempt.md b/.agents/skills/cli-compute/references/function-invocation-attempt.md new file mode 100644 index 000000000..6b233cdcb --- /dev/null +++ b/.agents/skills/cli-compute/references/function-invocation-attempt.md @@ -0,0 +1,68 @@ +# functionInvocationAttempt + + + +CRUD operations for FunctionInvocationAttempt records via csdk CLI + +## Usage + +```bash +csdk function-invocation-attempt list +csdk function-invocation-attempt list --where.. --orderBy +csdk function-invocation-attempt list --limit 10 --after +csdk function-invocation-attempt find-first --where.. +csdk function-invocation-attempt get --id +csdk function-invocation-attempt create --attempt --databaseId --invocationCreatedAt --invocationId --success --taskIdentifier [--actorId ] [--durationMs ] [--error ] [--errorDetail ] [--startedAt ] +csdk function-invocation-attempt update --id [--actorId ] [--attempt ] [--databaseId ] [--durationMs ] [--error ] [--errorDetail ] [--invocationCreatedAt ] [--invocationId ] [--startedAt ] [--success ] [--taskIdentifier ] +csdk function-invocation-attempt delete --id +``` + +## Examples + +### List functionInvocationAttempt records + +```bash +csdk function-invocation-attempt list +``` + +### List functionInvocationAttempt records with pagination + +```bash +csdk function-invocation-attempt list --limit 10 --offset 0 +``` + +### List functionInvocationAttempt records with cursor pagination + +```bash +csdk function-invocation-attempt list --limit 10 --after +``` + +### Find first matching functionInvocationAttempt + +```bash +csdk function-invocation-attempt find-first --where.id.equalTo +``` + +### List functionInvocationAttempt records with field selection + +```bash +csdk function-invocation-attempt list --select id,id +``` + +### List functionInvocationAttempt records with filtering and ordering + +```bash +csdk function-invocation-attempt list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a functionInvocationAttempt + +```bash +csdk function-invocation-attempt create --attempt --databaseId --invocationCreatedAt --invocationId --success --taskIdentifier [--actorId ] [--durationMs ] [--error ] [--errorDetail ] [--startedAt ] +``` + +### Get a functionInvocationAttempt by id + +```bash +csdk function-invocation-attempt get --id +``` diff --git a/.agents/skills/cli-compute/references/platform-function-definition.md b/.agents/skills/cli-compute/references/platform-function-definition.md index fbebaecaa..0f4b696f4 100644 --- a/.agents/skills/cli-compute/references/platform-function-definition.md +++ b/.agents/skills/cli-compute/references/platform-function-definition.md @@ -12,8 +12,8 @@ csdk platform-function-definition list --where.. --orderBy csdk platform-function-definition find-first --where.. csdk platform-function-definition get --id -csdk platform-function-definition create --category --name --taskIdentifier [--accessChannels ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] -csdk platform-function-definition update --id [--accessChannels ] [--category ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--name ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--taskIdentifier ] [--timeoutSeconds ] [--volatile ] +csdk platform-function-definition create --category --name [--accessChannels ] [--billable ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--system ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] +csdk platform-function-definition update --id [--accessChannels ] [--billable ] [--category ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--name ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--system ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] csdk platform-function-definition delete --id ``` @@ -58,7 +58,7 @@ csdk platform-function-definition list --where.id.equalTo --orderBy ID_A ### Create a platformFunctionDefinition ```bash -csdk platform-function-definition create --category --name --taskIdentifier [--accessChannels ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] +csdk platform-function-definition create --category --name [--accessChannels ] [--billable ] [--concurrency ] [--description ] [--fnCategory ] [--functionColumns ] [--graphId ] [--icon ] [--image ] [--inputs ] [--integrations ] [--isPublished ] [--maxAttempts ] [--moduleTable ] [--outputs ] [--payloadArgs ] [--priority ] [--props ] [--protected ] [--publishedAt ] [--queueName ] [--requiredBuckets ] [--requiredConfigs ] [--requiredModels ] [--requiredSecrets ] [--resources ] [--runtime ] [--scaleMax ] [--scaleMin ] [--system ] [--targetFunction ] [--targetSchema ] [--timeoutSeconds ] [--volatile ] ``` ### Get a platformFunctionDefinition by id diff --git a/.agents/skills/cli-compute/references/platform-function-invocation-attempt.md b/.agents/skills/cli-compute/references/platform-function-invocation-attempt.md new file mode 100644 index 000000000..f3fbc91d2 --- /dev/null +++ b/.agents/skills/cli-compute/references/platform-function-invocation-attempt.md @@ -0,0 +1,68 @@ +# platformFunctionInvocationAttempt + + + +CRUD operations for PlatformFunctionInvocationAttempt records via csdk CLI + +## Usage + +```bash +csdk platform-function-invocation-attempt list +csdk platform-function-invocation-attempt list --where.. --orderBy +csdk platform-function-invocation-attempt list --limit 10 --after +csdk platform-function-invocation-attempt find-first --where.. +csdk platform-function-invocation-attempt get --id +csdk platform-function-invocation-attempt create --attempt --invocationCreatedAt --invocationId --success --taskIdentifier [--actorId ] [--durationMs ] [--error ] [--errorDetail ] [--startedAt ] +csdk platform-function-invocation-attempt update --id [--actorId ] [--attempt ] [--durationMs ] [--error ] [--errorDetail ] [--invocationCreatedAt ] [--invocationId ] [--startedAt ] [--success ] [--taskIdentifier ] +csdk platform-function-invocation-attempt delete --id +``` + +## Examples + +### List platformFunctionInvocationAttempt records + +```bash +csdk platform-function-invocation-attempt list +``` + +### List platformFunctionInvocationAttempt records with pagination + +```bash +csdk platform-function-invocation-attempt list --limit 10 --offset 0 +``` + +### List platformFunctionInvocationAttempt records with cursor pagination + +```bash +csdk platform-function-invocation-attempt list --limit 10 --after +``` + +### Find first matching platformFunctionInvocationAttempt + +```bash +csdk platform-function-invocation-attempt find-first --where.id.equalTo +``` + +### List platformFunctionInvocationAttempt records with field selection + +```bash +csdk platform-function-invocation-attempt list --select id,id +``` + +### List platformFunctionInvocationAttempt records with filtering and ordering + +```bash +csdk platform-function-invocation-attempt list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a platformFunctionInvocationAttempt + +```bash +csdk platform-function-invocation-attempt create --attempt --invocationCreatedAt --invocationId --success --taskIdentifier [--actorId ] [--durationMs ] [--error ] [--errorDetail ] [--startedAt ] +``` + +### Get a platformFunctionInvocationAttempt by id + +```bash +csdk platform-function-invocation-attempt get --id +``` diff --git a/.agents/skills/cli-compute/references/platform-resource-declared-capacity.md b/.agents/skills/cli-compute/references/platform-resource-declared-capacity.md new file mode 100644 index 000000000..fc3879fc6 --- /dev/null +++ b/.agents/skills/cli-compute/references/platform-resource-declared-capacity.md @@ -0,0 +1,68 @@ +# platformResourceDeclaredCapacity + + + +CRUD operations for PlatformResourceDeclaredCapacity records via csdk CLI + +## Usage + +```bash +csdk platform-resource-declared-capacity list +csdk platform-resource-declared-capacity list --where.. --orderBy +csdk platform-resource-declared-capacity list --limit 10 --after +csdk platform-resource-declared-capacity find-first --where.. +csdk platform-resource-declared-capacity get --id +csdk platform-resource-declared-capacity create --cpuLimitMillicores --cpuRequestMillicores --installationId --isTransient --kind --memoryLimitBytes --memoryRequestBytes --namespaceId --podCountMax --podCountMin --source --sourceId --storageSizeBytes +csdk platform-resource-declared-capacity update --id [--cpuLimitMillicores ] [--cpuRequestMillicores ] [--installationId ] [--isTransient ] [--kind ] [--memoryLimitBytes ] [--memoryRequestBytes ] [--namespaceId ] [--podCountMax ] [--podCountMin ] [--source ] [--sourceId ] [--storageSizeBytes ] +csdk platform-resource-declared-capacity delete --id +``` + +## Examples + +### List platformResourceDeclaredCapacity records + +```bash +csdk platform-resource-declared-capacity list +``` + +### List platformResourceDeclaredCapacity records with pagination + +```bash +csdk platform-resource-declared-capacity list --limit 10 --offset 0 +``` + +### List platformResourceDeclaredCapacity records with cursor pagination + +```bash +csdk platform-resource-declared-capacity list --limit 10 --after +``` + +### Find first matching platformResourceDeclaredCapacity + +```bash +csdk platform-resource-declared-capacity find-first --where.id.equalTo +``` + +### List platformResourceDeclaredCapacity records with field selection + +```bash +csdk platform-resource-declared-capacity list --select id,id +``` + +### List platformResourceDeclaredCapacity records with filtering and ordering + +```bash +csdk platform-resource-declared-capacity list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a platformResourceDeclaredCapacity + +```bash +csdk platform-resource-declared-capacity create --cpuLimitMillicores --cpuRequestMillicores --installationId --isTransient --kind --memoryLimitBytes --memoryRequestBytes --namespaceId --podCountMax --podCountMin --source --sourceId --storageSizeBytes +``` + +### Get a platformResourceDeclaredCapacity by id + +```bash +csdk platform-resource-declared-capacity get --id +``` diff --git a/.agents/skills/cli-compute/references/platform-resource-installations-install.md b/.agents/skills/cli-compute/references/platform-resource-installations-install.md index 9aceebdb1..cc7084783 100644 --- a/.agents/skills/cli-compute/references/platform-resource-installations-install.md +++ b/.agents/skills/cli-compute/references/platform-resource-installations-install.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsInstall mutation ## Usage ```bash -csdk platform-resource-installations-install --input.clientMutationId --input.pName --input.pNamespaceId --input.pParams --input.pSlug +csdk platform-resource-installations-install --input.clientMutationId --input.name --input.namespaceId --input.newParams --input.slug ``` ## Examples @@ -15,5 +15,5 @@ csdk platform-resource-installations-install --input.clientMutationId - ### Run platformResourceInstallationsInstall ```bash -csdk platform-resource-installations-install --input.clientMutationId --input.pName --input.pNamespaceId --input.pParams --input.pSlug +csdk platform-resource-installations-install --input.clientMutationId --input.name --input.namespaceId --input.newParams --input.slug ``` diff --git a/.agents/skills/cli-compute/references/platform-resource-installations-rollback.md b/.agents/skills/cli-compute/references/platform-resource-installations-rollback.md index 8f4dfd622..e81327af6 100644 --- a/.agents/skills/cli-compute/references/platform-resource-installations-rollback.md +++ b/.agents/skills/cli-compute/references/platform-resource-installations-rollback.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsRollback mutation ## Usage ```bash -csdk platform-resource-installations-rollback --input.clientMutationId --input.pCommitId --input.pInstallationId +csdk platform-resource-installations-rollback --input.clientMutationId --input.commitId --input.targetInstallationId ``` ## Examples @@ -15,5 +15,5 @@ csdk platform-resource-installations-rollback --input.clientMutationId ### Run platformResourceInstallationsRollback ```bash -csdk platform-resource-installations-rollback --input.clientMutationId --input.pCommitId --input.pInstallationId +csdk platform-resource-installations-rollback --input.clientMutationId --input.commitId --input.targetInstallationId ``` diff --git a/.agents/skills/cli-compute/references/platform-resource-installations-uninstall.md b/.agents/skills/cli-compute/references/platform-resource-installations-uninstall.md index e48f521aa..3fa19c42a 100644 --- a/.agents/skills/cli-compute/references/platform-resource-installations-uninstall.md +++ b/.agents/skills/cli-compute/references/platform-resource-installations-uninstall.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsUninstall mutation ## Usage ```bash -csdk platform-resource-installations-uninstall --input.clientMutationId --input.pInstallationId +csdk platform-resource-installations-uninstall --input.clientMutationId --input.targetInstallationId ``` ## Examples @@ -15,5 +15,5 @@ csdk platform-resource-installations-uninstall --input.clientMutationId ### Run platformResourceInstallationsUninstall ```bash -csdk platform-resource-installations-uninstall --input.clientMutationId --input.pInstallationId +csdk platform-resource-installations-uninstall --input.clientMutationId --input.targetInstallationId ``` diff --git a/.agents/skills/cli-compute/references/platform-resource-installations-upgrade.md b/.agents/skills/cli-compute/references/platform-resource-installations-upgrade.md index fc3627bcd..f2ca74a87 100644 --- a/.agents/skills/cli-compute/references/platform-resource-installations-upgrade.md +++ b/.agents/skills/cli-compute/references/platform-resource-installations-upgrade.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsUpgrade mutation ## Usage ```bash -csdk platform-resource-installations-upgrade --input.clientMutationId --input.pInstallationId --input.pParams +csdk platform-resource-installations-upgrade --input.clientMutationId --input.newParams --input.targetInstallationId ``` ## Examples @@ -15,5 +15,5 @@ csdk platform-resource-installations-upgrade --input.clientMutationId - ### Run platformResourceInstallationsUpgrade ```bash -csdk platform-resource-installations-upgrade --input.clientMutationId --input.pInstallationId --input.pParams +csdk platform-resource-installations-upgrade --input.clientMutationId --input.newParams --input.targetInstallationId ``` diff --git a/.agents/skills/cli-compute/references/platform-resource-utilization.md b/.agents/skills/cli-compute/references/platform-resource-utilization.md new file mode 100644 index 000000000..d50a119c6 --- /dev/null +++ b/.agents/skills/cli-compute/references/platform-resource-utilization.md @@ -0,0 +1,68 @@ +# platformResourceUtilization + + + +CRUD operations for PlatformResourceUtilization records via csdk CLI + +## Usage + +```bash +csdk platform-resource-utilization list +csdk platform-resource-utilization list --where.. --orderBy +csdk platform-resource-utilization list --limit 10 --after +csdk platform-resource-utilization find-first --where.. +csdk platform-resource-utilization get --id +csdk platform-resource-utilization create --avgMemoryBytes --cpuLimitMillicores --cpuPeakUtilization --cpuRequestHeadroomMillicores --cpuRequestMillicores --date --gbSeconds --kind --maxCpuMillicores --maxMemoryBytes --memoryLimitBytes --memoryPeakUtilization --memoryRequestBytes --memoryRequestHeadroomBytes --namespaceId --replicas --resourceId --runtimeSeconds --sampleCount +csdk platform-resource-utilization update --id [--avgMemoryBytes ] [--cpuLimitMillicores ] [--cpuPeakUtilization ] [--cpuRequestHeadroomMillicores ] [--cpuRequestMillicores ] [--date ] [--gbSeconds ] [--kind ] [--maxCpuMillicores ] [--maxMemoryBytes ] [--memoryLimitBytes ] [--memoryPeakUtilization ] [--memoryRequestBytes ] [--memoryRequestHeadroomBytes ] [--namespaceId ] [--replicas ] [--resourceId ] [--runtimeSeconds ] [--sampleCount ] +csdk platform-resource-utilization delete --id +``` + +## Examples + +### List platformResourceUtilization records + +```bash +csdk platform-resource-utilization list +``` + +### List platformResourceUtilization records with pagination + +```bash +csdk platform-resource-utilization list --limit 10 --offset 0 +``` + +### List platformResourceUtilization records with cursor pagination + +```bash +csdk platform-resource-utilization list --limit 10 --after +``` + +### Find first matching platformResourceUtilization + +```bash +csdk platform-resource-utilization find-first --where.id.equalTo +``` + +### List platformResourceUtilization records with field selection + +```bash +csdk platform-resource-utilization list --select id,id +``` + +### List platformResourceUtilization records with filtering and ordering + +```bash +csdk platform-resource-utilization list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a platformResourceUtilization + +```bash +csdk platform-resource-utilization create --avgMemoryBytes --cpuLimitMillicores --cpuPeakUtilization --cpuRequestHeadroomMillicores --cpuRequestMillicores --date --gbSeconds --kind --maxCpuMillicores --maxMemoryBytes --memoryLimitBytes --memoryPeakUtilization --memoryRequestBytes --memoryRequestHeadroomBytes --namespaceId --replicas --resourceId --runtimeSeconds --sampleCount +``` + +### Get a platformResourceUtilization by id + +```bash +csdk platform-resource-utilization get --id +``` diff --git a/.agents/skills/cli-compute/references/resource-declared-capacity.md b/.agents/skills/cli-compute/references/resource-declared-capacity.md new file mode 100644 index 000000000..7aa736632 --- /dev/null +++ b/.agents/skills/cli-compute/references/resource-declared-capacity.md @@ -0,0 +1,68 @@ +# resourceDeclaredCapacity + + + +CRUD operations for ResourceDeclaredCapacity records via csdk CLI + +## Usage + +```bash +csdk resource-declared-capacity list +csdk resource-declared-capacity list --where.. --orderBy +csdk resource-declared-capacity list --limit 10 --after +csdk resource-declared-capacity find-first --where.. +csdk resource-declared-capacity get --id +csdk resource-declared-capacity create --cpuLimitMillicores --cpuRequestMillicores --installationId --isTransient --kind --memoryLimitBytes --memoryRequestBytes --namespaceId --podCountMax --podCountMin --source --sourceId --storageSizeBytes +csdk resource-declared-capacity update --id [--cpuLimitMillicores ] [--cpuRequestMillicores ] [--installationId ] [--isTransient ] [--kind ] [--memoryLimitBytes ] [--memoryRequestBytes ] [--namespaceId ] [--podCountMax ] [--podCountMin ] [--source ] [--sourceId ] [--storageSizeBytes ] +csdk resource-declared-capacity delete --id +``` + +## Examples + +### List resourceDeclaredCapacity records + +```bash +csdk resource-declared-capacity list +``` + +### List resourceDeclaredCapacity records with pagination + +```bash +csdk resource-declared-capacity list --limit 10 --offset 0 +``` + +### List resourceDeclaredCapacity records with cursor pagination + +```bash +csdk resource-declared-capacity list --limit 10 --after +``` + +### Find first matching resourceDeclaredCapacity + +```bash +csdk resource-declared-capacity find-first --where.id.equalTo +``` + +### List resourceDeclaredCapacity records with field selection + +```bash +csdk resource-declared-capacity list --select id,id +``` + +### List resourceDeclaredCapacity records with filtering and ordering + +```bash +csdk resource-declared-capacity list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a resourceDeclaredCapacity + +```bash +csdk resource-declared-capacity create --cpuLimitMillicores --cpuRequestMillicores --installationId --isTransient --kind --memoryLimitBytes --memoryRequestBytes --namespaceId --podCountMax --podCountMin --source --sourceId --storageSizeBytes +``` + +### Get a resourceDeclaredCapacity by id + +```bash +csdk resource-declared-capacity get --id +``` diff --git a/.agents/skills/cli-compute/references/resource-installations-install.md b/.agents/skills/cli-compute/references/resource-installations-install.md index c7c5cea03..9db040a8a 100644 --- a/.agents/skills/cli-compute/references/resource-installations-install.md +++ b/.agents/skills/cli-compute/references/resource-installations-install.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsInstall mutation ## Usage ```bash -csdk resource-installations-install --input.clientMutationId --input.pName --input.pNamespaceId --input.pParams --input.pSlug +csdk resource-installations-install --input.clientMutationId --input.name --input.namespaceId --input.newParams --input.slug ``` ## Examples @@ -15,5 +15,5 @@ csdk resource-installations-install --input.clientMutationId --input.pN ### Run resourceInstallationsInstall ```bash -csdk resource-installations-install --input.clientMutationId --input.pName --input.pNamespaceId --input.pParams --input.pSlug +csdk resource-installations-install --input.clientMutationId --input.name --input.namespaceId --input.newParams --input.slug ``` diff --git a/.agents/skills/cli-compute/references/resource-installations-rollback.md b/.agents/skills/cli-compute/references/resource-installations-rollback.md index 335224edc..0c72ce8b1 100644 --- a/.agents/skills/cli-compute/references/resource-installations-rollback.md +++ b/.agents/skills/cli-compute/references/resource-installations-rollback.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsRollback mutation ## Usage ```bash -csdk resource-installations-rollback --input.clientMutationId --input.pCommitId --input.pInstallationId +csdk resource-installations-rollback --input.clientMutationId --input.commitId --input.targetInstallationId ``` ## Examples @@ -15,5 +15,5 @@ csdk resource-installations-rollback --input.clientMutationId --input.p ### Run resourceInstallationsRollback ```bash -csdk resource-installations-rollback --input.clientMutationId --input.pCommitId --input.pInstallationId +csdk resource-installations-rollback --input.clientMutationId --input.commitId --input.targetInstallationId ``` diff --git a/.agents/skills/cli-compute/references/resource-installations-uninstall.md b/.agents/skills/cli-compute/references/resource-installations-uninstall.md index 07309b0e9..b6e36f424 100644 --- a/.agents/skills/cli-compute/references/resource-installations-uninstall.md +++ b/.agents/skills/cli-compute/references/resource-installations-uninstall.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsUninstall mutation ## Usage ```bash -csdk resource-installations-uninstall --input.clientMutationId --input.pInstallationId +csdk resource-installations-uninstall --input.clientMutationId --input.targetInstallationId ``` ## Examples @@ -15,5 +15,5 @@ csdk resource-installations-uninstall --input.clientMutationId --input. ### Run resourceInstallationsUninstall ```bash -csdk resource-installations-uninstall --input.clientMutationId --input.pInstallationId +csdk resource-installations-uninstall --input.clientMutationId --input.targetInstallationId ``` diff --git a/.agents/skills/cli-compute/references/resource-installations-upgrade.md b/.agents/skills/cli-compute/references/resource-installations-upgrade.md index 84c09c8af..add28e8be 100644 --- a/.agents/skills/cli-compute/references/resource-installations-upgrade.md +++ b/.agents/skills/cli-compute/references/resource-installations-upgrade.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsUpgrade mutation ## Usage ```bash -csdk resource-installations-upgrade --input.clientMutationId --input.pInstallationId --input.pParams +csdk resource-installations-upgrade --input.clientMutationId --input.newParams --input.targetInstallationId ``` ## Examples @@ -15,5 +15,5 @@ csdk resource-installations-upgrade --input.clientMutationId --input.pI ### Run resourceInstallationsUpgrade ```bash -csdk resource-installations-upgrade --input.clientMutationId --input.pInstallationId --input.pParams +csdk resource-installations-upgrade --input.clientMutationId --input.newParams --input.targetInstallationId ``` diff --git a/.agents/skills/cli-compute/references/resource-utilization.md b/.agents/skills/cli-compute/references/resource-utilization.md new file mode 100644 index 000000000..7d67a62cb --- /dev/null +++ b/.agents/skills/cli-compute/references/resource-utilization.md @@ -0,0 +1,68 @@ +# resourceUtilization + + + +CRUD operations for ResourceUtilization records via csdk CLI + +## Usage + +```bash +csdk resource-utilization list +csdk resource-utilization list --where.. --orderBy +csdk resource-utilization list --limit 10 --after +csdk resource-utilization find-first --where.. +csdk resource-utilization get --id +csdk resource-utilization create --avgMemoryBytes --cpuLimitMillicores --cpuPeakUtilization --cpuRequestHeadroomMillicores --cpuRequestMillicores --date --gbSeconds --kind --maxCpuMillicores --maxMemoryBytes --memoryLimitBytes --memoryPeakUtilization --memoryRequestBytes --memoryRequestHeadroomBytes --namespaceId --replicas --resourceId --runtimeSeconds --sampleCount +csdk resource-utilization update --id [--avgMemoryBytes ] [--cpuLimitMillicores ] [--cpuPeakUtilization ] [--cpuRequestHeadroomMillicores ] [--cpuRequestMillicores ] [--date ] [--gbSeconds ] [--kind ] [--maxCpuMillicores ] [--maxMemoryBytes ] [--memoryLimitBytes ] [--memoryPeakUtilization ] [--memoryRequestBytes ] [--memoryRequestHeadroomBytes ] [--namespaceId ] [--replicas ] [--resourceId ] [--runtimeSeconds ] [--sampleCount ] +csdk resource-utilization delete --id +``` + +## Examples + +### List resourceUtilization records + +```bash +csdk resource-utilization list +``` + +### List resourceUtilization records with pagination + +```bash +csdk resource-utilization list --limit 10 --offset 0 +``` + +### List resourceUtilization records with cursor pagination + +```bash +csdk resource-utilization list --limit 10 --after +``` + +### Find first matching resourceUtilization + +```bash +csdk resource-utilization find-first --where.id.equalTo +``` + +### List resourceUtilization records with field selection + +```bash +csdk resource-utilization list --select id,id +``` + +### List resourceUtilization records with filtering and ordering + +```bash +csdk resource-utilization list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a resourceUtilization + +```bash +csdk resource-utilization create --avgMemoryBytes --cpuLimitMillicores --cpuPeakUtilization --cpuRequestHeadroomMillicores --cpuRequestMillicores --date --gbSeconds --kind --maxCpuMillicores --maxMemoryBytes --memoryLimitBytes --memoryPeakUtilization --memoryRequestBytes --memoryRequestHeadroomBytes --namespaceId --replicas --resourceId --runtimeSeconds --sampleCount +``` + +### Get a resourceUtilization by id + +```bash +csdk resource-utilization get --id +``` diff --git a/.agents/skills/cli-modules/SKILL.md b/.agents/skills/cli-modules/SKILL.md index 73450b18d..1b2db02d2 100644 --- a/.agents/skills/cli-modules/SKILL.md +++ b/.agents/skills/cli-modules/SKILL.md @@ -1,13 +1,13 @@ --- name: cli-modules -description: CLI tool (csdk) for the modules API — provides CRUD commands for 68 tables and 12 custom operations +description: CLI tool (csdk) for the modules API — provides CRUD commands for 74 tables and 12 custom operations --- # cli-modules -CLI tool (csdk) for the modules API — provides CRUD commands for 68 tables and 12 custom operations +CLI tool (csdk) for the modules API — provides CRUD commands for 74 tables and 12 custom operations ## Usage @@ -57,11 +57,14 @@ See the `references/` directory for detailed per-entity API documentation: - [auth](references/auth.md) - [config](references/config.md) - [agent-module](references/agent-module.md) +- [api-surface-module](references/api-surface-module.md) +- [app-module](references/app-module.md) - [billing-module](references/billing-module.md) - [billing-provider-module](references/billing-provider-module.md) - [blueprint](references/blueprint.md) - [blueprint-construction](references/blueprint-construction.md) - [blueprint-template](references/blueprint-template.md) +- [catalog-module](references/catalog-module.md) - [compute-log-module](references/compute-log-module.md) - [config-secrets-user-module](references/config-secrets-user-module.md) - [connected-accounts-module](references/connected-accounts-module.md) @@ -75,6 +78,7 @@ See the `references/` directory for detailed per-entity API documentation: - [default-ids-module](references/default-ids-module.md) - [denormalized-table-field](references/denormalized-table-field.md) - [devices-module](references/devices-module.md) +- [domain-module](references/domain-module.md) - [emails-module](references/emails-module.md) - [entity-type-provision](references/entity-type-provision.md) - [events-module](references/events-module.md) @@ -110,9 +114,11 @@ See the `references/` directory for detailed per-entity API documentation: - [relation-provision](references/relation-provision.md) - [resource-module](references/resource-module.md) - [rls-module](references/rls-module.md) +- [route-module](references/route-module.md) - [secure-table-provision](references/secure-table-provision.md) - [session-secrets-module](references/session-secrets-module.md) - [sessions-module](references/sessions-module.md) +- [site-surface-module](references/site-surface-module.md) - [storage-log-module](references/storage-log-module.md) - [storage-module](references/storage-module.md) - [transfer-log-module](references/transfer-log-module.md) diff --git a/.agents/skills/cli-modules/references/api-surface-module.md b/.agents/skills/cli-modules/references/api-surface-module.md new file mode 100644 index 000000000..7bdae3216 --- /dev/null +++ b/.agents/skills/cli-modules/references/api-surface-module.md @@ -0,0 +1,68 @@ +# apiSurfaceModule + + + +CRUD operations for ApiSurfaceModule records via csdk CLI + +## Usage + +```bash +csdk api-surface-module list +csdk api-surface-module list --where.. --orderBy +csdk api-surface-module list --limit 10 --after +csdk api-surface-module find-first --where.. +csdk api-surface-module get --id +csdk api-surface-module create --databaseId [--apiName ] [--apisTableId ] [--apisTableName ] [--catalogModuleId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk api-surface-module update --id [--apiName ] [--apisTableId ] [--apisTableName ] [--catalogModuleId ] [--databaseId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk api-surface-module delete --id +``` + +## Examples + +### List apiSurfaceModule records + +```bash +csdk api-surface-module list +``` + +### List apiSurfaceModule records with pagination + +```bash +csdk api-surface-module list --limit 10 --offset 0 +``` + +### List apiSurfaceModule records with cursor pagination + +```bash +csdk api-surface-module list --limit 10 --after +``` + +### Find first matching apiSurfaceModule + +```bash +csdk api-surface-module find-first --where.id.equalTo +``` + +### List apiSurfaceModule records with field selection + +```bash +csdk api-surface-module list --select id,id +``` + +### List apiSurfaceModule records with filtering and ordering + +```bash +csdk api-surface-module list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a apiSurfaceModule + +```bash +csdk api-surface-module create --databaseId [--apiName ] [--apisTableId ] [--apisTableName ] [--catalogModuleId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +``` + +### Get a apiSurfaceModule by id + +```bash +csdk api-surface-module get --id +``` diff --git a/.agents/skills/cli-modules/references/app-module.md b/.agents/skills/cli-modules/references/app-module.md new file mode 100644 index 000000000..a62e4c361 --- /dev/null +++ b/.agents/skills/cli-modules/references/app-module.md @@ -0,0 +1,68 @@ +# appModule + + + +CRUD operations for AppModule records via csdk CLI + +## Usage + +```bash +csdk app-module list +csdk app-module list --where.. --orderBy +csdk app-module list --limit 10 --after +csdk app-module find-first --where.. +csdk app-module get --id +csdk app-module create --databaseId [--apiName ] [--appMembersTableId ] [--appMembersTableName ] [--appsTableId ] [--appsTableName ] [--catalogModuleId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk app-module update --id [--apiName ] [--appMembersTableId ] [--appMembersTableName ] [--appsTableId ] [--appsTableName ] [--catalogModuleId ] [--databaseId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk app-module delete --id +``` + +## Examples + +### List appModule records + +```bash +csdk app-module list +``` + +### List appModule records with pagination + +```bash +csdk app-module list --limit 10 --offset 0 +``` + +### List appModule records with cursor pagination + +```bash +csdk app-module list --limit 10 --after +``` + +### Find first matching appModule + +```bash +csdk app-module find-first --where.id.equalTo +``` + +### List appModule records with field selection + +```bash +csdk app-module list --select id,id +``` + +### List appModule records with filtering and ordering + +```bash +csdk app-module list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a appModule + +```bash +csdk app-module create --databaseId [--apiName ] [--appMembersTableId ] [--appMembersTableName ] [--appsTableId ] [--appsTableName ] [--catalogModuleId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +``` + +### Get a appModule by id + +```bash +csdk app-module get --id +``` diff --git a/.agents/skills/cli-modules/references/catalog-module.md b/.agents/skills/cli-modules/references/catalog-module.md new file mode 100644 index 000000000..9592c81a3 --- /dev/null +++ b/.agents/skills/cli-modules/references/catalog-module.md @@ -0,0 +1,68 @@ +# catalogModule + + + +CRUD operations for CatalogModule records via csdk CLI + +## Usage + +```bash +csdk catalog-module list +csdk catalog-module list --where.. --orderBy +csdk catalog-module list --limit 10 --after +csdk catalog-module find-first --where.. +csdk catalog-module get --id +csdk catalog-module create --databaseId [--apiName ] [--apisTableId ] [--apisTableName ] [--appsTableId ] [--appsTableName ] [--defaultPermissions ] [--domainsTableId ] [--domainsTableName ] [--entityTableId ] [--functionsTableId ] [--functionsTableName ] [--namespacesTableId ] [--namespacesTableName ] [--policies ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--resourceDefinitionsTableId ] [--resourceDefinitionsTableName ] [--resourceInstallationsTableId ] [--resourceInstallationsTableName ] [--resourcesTableId ] [--resourcesTableName ] [--schemaId ] [--scope ] [--sitesTableId ] [--sitesTableName ] +csdk catalog-module update --id [--apiName ] [--apisTableId ] [--apisTableName ] [--appsTableId ] [--appsTableName ] [--databaseId ] [--defaultPermissions ] [--domainsTableId ] [--domainsTableName ] [--entityTableId ] [--functionsTableId ] [--functionsTableName ] [--namespacesTableId ] [--namespacesTableName ] [--policies ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--resourceDefinitionsTableId ] [--resourceDefinitionsTableName ] [--resourceInstallationsTableId ] [--resourceInstallationsTableName ] [--resourcesTableId ] [--resourcesTableName ] [--schemaId ] [--scope ] [--sitesTableId ] [--sitesTableName ] +csdk catalog-module delete --id +``` + +## Examples + +### List catalogModule records + +```bash +csdk catalog-module list +``` + +### List catalogModule records with pagination + +```bash +csdk catalog-module list --limit 10 --offset 0 +``` + +### List catalogModule records with cursor pagination + +```bash +csdk catalog-module list --limit 10 --after +``` + +### Find first matching catalogModule + +```bash +csdk catalog-module find-first --where.id.equalTo +``` + +### List catalogModule records with field selection + +```bash +csdk catalog-module list --select id,id +``` + +### List catalogModule records with filtering and ordering + +```bash +csdk catalog-module list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a catalogModule + +```bash +csdk catalog-module create --databaseId [--apiName ] [--apisTableId ] [--apisTableName ] [--appsTableId ] [--appsTableName ] [--defaultPermissions ] [--domainsTableId ] [--domainsTableName ] [--entityTableId ] [--functionsTableId ] [--functionsTableName ] [--namespacesTableId ] [--namespacesTableName ] [--policies ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--resourceDefinitionsTableId ] [--resourceDefinitionsTableName ] [--resourceInstallationsTableId ] [--resourceInstallationsTableName ] [--resourcesTableId ] [--resourcesTableName ] [--schemaId ] [--scope ] [--sitesTableId ] [--sitesTableName ] +``` + +### Get a catalogModule by id + +```bash +csdk catalog-module get --id +``` diff --git a/.agents/skills/cli-modules/references/database-provision-module.md b/.agents/skills/cli-modules/references/database-provision-module.md index 70af3c69c..b28babbbd 100644 --- a/.agents/skills/cli-modules/references/database-provision-module.md +++ b/.agents/skills/cli-modules/references/database-provision-module.md @@ -12,8 +12,8 @@ csdk database-provision-module list --where.. --orderBy csdk database-provision-module find-first --where.. csdk database-provision-module get --id -csdk database-provision-module create --databaseName --domain --ownerId [--bootstrapError ] [--bootstrapStatus ] [--bootstrapUser ] [--completedAt ] [--databaseId ] [--errorMessage ] [--fulfilledAt ] [--modules ] [--options ] [--sourceDatabaseId ] [--status ] [--subdomain ] -csdk database-provision-module update --id [--bootstrapError ] [--bootstrapStatus ] [--bootstrapUser ] [--completedAt ] [--databaseId ] [--databaseName ] [--domain ] [--errorMessage ] [--fulfilledAt ] [--modules ] [--options ] [--ownerId ] [--sourceDatabaseId ] [--status ] [--subdomain ] +csdk database-provision-module create --databaseName --domain --ownerId [--async ] [--bootstrapError ] [--bootstrapStatus ] [--bootstrapUser ] [--completedAt ] [--databaseId ] [--errorMessage ] [--fulfilledAt ] [--modules ] [--options ] [--sourceDatabaseId ] [--status ] [--subdomain ] +csdk database-provision-module update --id [--async ] [--bootstrapError ] [--bootstrapStatus ] [--bootstrapUser ] [--completedAt ] [--databaseId ] [--databaseName ] [--domain ] [--errorMessage ] [--fulfilledAt ] [--modules ] [--options ] [--ownerId ] [--sourceDatabaseId ] [--status ] [--subdomain ] csdk database-provision-module delete --id ``` @@ -58,7 +58,7 @@ csdk database-provision-module list --where.id.equalTo --orderBy ID_ASC ### Create a databaseProvisionModule ```bash -csdk database-provision-module create --databaseName --domain --ownerId [--bootstrapError ] [--bootstrapStatus ] [--bootstrapUser ] [--completedAt ] [--databaseId ] [--errorMessage ] [--fulfilledAt ] [--modules ] [--options ] [--sourceDatabaseId ] [--status ] [--subdomain ] +csdk database-provision-module create --databaseName --domain --ownerId [--async ] [--bootstrapError ] [--bootstrapStatus ] [--bootstrapUser ] [--completedAt ] [--databaseId ] [--errorMessage ] [--fulfilledAt ] [--modules ] [--options ] [--sourceDatabaseId ] [--status ] [--subdomain ] ``` ### Get a databaseProvisionModule by id diff --git a/.agents/skills/cli-modules/references/domain-module.md b/.agents/skills/cli-modules/references/domain-module.md new file mode 100644 index 000000000..5d9f4b38d --- /dev/null +++ b/.agents/skills/cli-modules/references/domain-module.md @@ -0,0 +1,68 @@ +# domainModule + + + +CRUD operations for DomainModule records via csdk CLI + +## Usage + +```bash +csdk domain-module list +csdk domain-module list --where.. --orderBy +csdk domain-module list --limit 10 --after +csdk domain-module find-first --where.. +csdk domain-module get --id +csdk domain-module create --databaseId [--apiName ] [--catalogModuleId ] [--defaultPermissions ] [--domainEventsTableId ] [--domainEventsTableName ] [--domainVerificationsTableId ] [--domainVerificationsTableName ] [--domainsTableId ] [--domainsTableName ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk domain-module update --id [--apiName ] [--catalogModuleId ] [--databaseId ] [--defaultPermissions ] [--domainEventsTableId ] [--domainEventsTableName ] [--domainVerificationsTableId ] [--domainVerificationsTableName ] [--domainsTableId ] [--domainsTableName ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk domain-module delete --id +``` + +## Examples + +### List domainModule records + +```bash +csdk domain-module list +``` + +### List domainModule records with pagination + +```bash +csdk domain-module list --limit 10 --offset 0 +``` + +### List domainModule records with cursor pagination + +```bash +csdk domain-module list --limit 10 --after +``` + +### Find first matching domainModule + +```bash +csdk domain-module find-first --where.id.equalTo +``` + +### List domainModule records with field selection + +```bash +csdk domain-module list --select id,id +``` + +### List domainModule records with filtering and ordering + +```bash +csdk domain-module list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a domainModule + +```bash +csdk domain-module create --databaseId [--apiName ] [--catalogModuleId ] [--defaultPermissions ] [--domainEventsTableId ] [--domainEventsTableName ] [--domainVerificationsTableId ] [--domainVerificationsTableName ] [--domainsTableId ] [--domainsTableName ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +``` + +### Get a domainModule by id + +```bash +csdk domain-module get --id +``` diff --git a/.agents/skills/cli-modules/references/function-invocation-module.md b/.agents/skills/cli-modules/references/function-invocation-module.md index 59efd5729..ede6f7710 100644 --- a/.agents/skills/cli-modules/references/function-invocation-module.md +++ b/.agents/skills/cli-modules/references/function-invocation-module.md @@ -12,8 +12,8 @@ csdk function-invocation-module list --where.. --orderBy csdk function-invocation-module find-first --where.. csdk function-invocation-module get --id -csdk function-invocation-module create --databaseId [--apiName ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--executionLogsTableId ] [--executionLogsTableName ] [--invocationsTableId ] [--invocationsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] -csdk function-invocation-module update --id [--apiName ] [--databaseId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--executionLogsTableId ] [--executionLogsTableName ] [--invocationsTableId ] [--invocationsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk function-invocation-module create --databaseId [--apiName ] [--attemptsTableId ] [--attemptsTableName ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--executionLogsTableId ] [--executionLogsTableName ] [--invocationsTableId ] [--invocationsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk function-invocation-module update --id [--apiName ] [--attemptsTableId ] [--attemptsTableName ] [--databaseId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--executionLogsTableId ] [--executionLogsTableName ] [--invocationsTableId ] [--invocationsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] csdk function-invocation-module delete --id ``` @@ -58,7 +58,7 @@ csdk function-invocation-module list --where.id.equalTo --orderBy ID_ASC ### Create a functionInvocationModule ```bash -csdk function-invocation-module create --databaseId [--apiName ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--executionLogsTableId ] [--executionLogsTableName ] [--invocationsTableId ] [--invocationsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] +csdk function-invocation-module create --databaseId [--apiName ] [--attemptsTableId ] [--attemptsTableName ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--executionLogsTableId ] [--executionLogsTableName ] [--invocationsTableId ] [--invocationsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] ``` ### Get a functionInvocationModule by id diff --git a/.agents/skills/cli-modules/references/provision-spatial-relation.md b/.agents/skills/cli-modules/references/provision-spatial-relation.md index f10552000..291650952 100644 --- a/.agents/skills/cli-modules/references/provision-spatial-relation.md +++ b/.agents/skills/cli-modules/references/provision-spatial-relation.md @@ -7,7 +7,7 @@ Idempotent provisioner for metaschema_public.spatial_relation. Inserts a row dec ## Usage ```bash -csdk provision-spatial-relation --input.clientMutationId --input.pDatabaseId --input.pName --input.pOperator --input.pParamName --input.pSourceFieldId --input.pSourceTableId --input.pTargetFieldId --input.pTargetTableId +csdk provision-spatial-relation --input.clientMutationId --input.databaseId --input.name --input.operator --input.paramName --input.sourceFieldId --input.sourceTableId --input.targetFieldId --input.targetTableId ``` ## Examples @@ -15,5 +15,5 @@ csdk provision-spatial-relation --input.clientMutationId --input.pDatab ### Run provisionSpatialRelation ```bash -csdk provision-spatial-relation --input.clientMutationId --input.pDatabaseId --input.pName --input.pOperator --input.pParamName --input.pSourceFieldId --input.pSourceTableId --input.pTargetFieldId --input.pTargetTableId +csdk provision-spatial-relation --input.clientMutationId --input.databaseId --input.name --input.operator --input.paramName --input.sourceFieldId --input.sourceTableId --input.targetFieldId --input.targetTableId ``` diff --git a/.agents/skills/cli-modules/references/route-module.md b/.agents/skills/cli-modules/references/route-module.md new file mode 100644 index 000000000..a2bba4c48 --- /dev/null +++ b/.agents/skills/cli-modules/references/route-module.md @@ -0,0 +1,68 @@ +# routeModule + + + +CRUD operations for RouteModule records via csdk CLI + +## Usage + +```bash +csdk route-module list +csdk route-module list --where.. --orderBy +csdk route-module list --limit 10 --after +csdk route-module find-first --where.. +csdk route-module get --id +csdk route-module create --databaseId [--apiName ] [--catalogModuleId ] [--defaultPermissions ] [--domainModuleId ] [--entityField ] [--entityTableId ] [--hostnameBindingsTableId ] [--hostnameBindingsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--resolverFunctionName ] [--routeBindingsTableId ] [--routeBindingsTableName ] [--routesTableId ] [--routesTableName ] [--schemaId ] [--scope ] +csdk route-module update --id [--apiName ] [--catalogModuleId ] [--databaseId ] [--defaultPermissions ] [--domainModuleId ] [--entityField ] [--entityTableId ] [--hostnameBindingsTableId ] [--hostnameBindingsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--resolverFunctionName ] [--routeBindingsTableId ] [--routeBindingsTableName ] [--routesTableId ] [--routesTableName ] [--schemaId ] [--scope ] +csdk route-module delete --id +``` + +## Examples + +### List routeModule records + +```bash +csdk route-module list +``` + +### List routeModule records with pagination + +```bash +csdk route-module list --limit 10 --offset 0 +``` + +### List routeModule records with cursor pagination + +```bash +csdk route-module list --limit 10 --after +``` + +### Find first matching routeModule + +```bash +csdk route-module find-first --where.id.equalTo +``` + +### List routeModule records with field selection + +```bash +csdk route-module list --select id,id +``` + +### List routeModule records with filtering and ordering + +```bash +csdk route-module list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a routeModule + +```bash +csdk route-module create --databaseId [--apiName ] [--catalogModuleId ] [--defaultPermissions ] [--domainModuleId ] [--entityField ] [--entityTableId ] [--hostnameBindingsTableId ] [--hostnameBindingsTableName ] [--policies ] [--prefix ] [--privateApiName ] [--privateSchemaId ] [--privateSchemaName ] [--provisions ] [--publicSchemaName ] [--resolverFunctionName ] [--routeBindingsTableId ] [--routeBindingsTableName ] [--routesTableId ] [--routesTableName ] [--schemaId ] [--scope ] +``` + +### Get a routeModule by id + +```bash +csdk route-module get --id +``` diff --git a/.agents/skills/cli-modules/references/site-surface-module.md b/.agents/skills/cli-modules/references/site-surface-module.md new file mode 100644 index 000000000..ae88ea55d --- /dev/null +++ b/.agents/skills/cli-modules/references/site-surface-module.md @@ -0,0 +1,68 @@ +# siteSurfaceModule + + + +CRUD operations for SiteSurfaceModule records via csdk CLI + +## Usage + +```bash +csdk site-surface-module list +csdk site-surface-module list --where.. --orderBy +csdk site-surface-module list --limit 10 --after +csdk site-surface-module find-first --where.. +csdk site-surface-module get --id +csdk site-surface-module create --databaseId [--apiName ] [--catalogModuleId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] [--sitesTableId ] [--sitesTableName ] +csdk site-surface-module update --id [--apiName ] [--catalogModuleId ] [--databaseId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] [--sitesTableId ] [--sitesTableName ] +csdk site-surface-module delete --id +``` + +## Examples + +### List siteSurfaceModule records + +```bash +csdk site-surface-module list +``` + +### List siteSurfaceModule records with pagination + +```bash +csdk site-surface-module list --limit 10 --offset 0 +``` + +### List siteSurfaceModule records with cursor pagination + +```bash +csdk site-surface-module list --limit 10 --after +``` + +### Find first matching siteSurfaceModule + +```bash +csdk site-surface-module find-first --where.id.equalTo +``` + +### List siteSurfaceModule records with field selection + +```bash +csdk site-surface-module list --select id,id +``` + +### List siteSurfaceModule records with filtering and ordering + +```bash +csdk site-surface-module list --where.id.equalTo --orderBy ID_ASC +``` + +### Create a siteSurfaceModule + +```bash +csdk site-surface-module create --databaseId [--apiName ] [--catalogModuleId ] [--defaultPermissions ] [--entityField ] [--entityTableId ] [--policies ] [--prefix ] [--privateApiName ] [--provisions ] [--publicSchemaName ] [--schemaId ] [--scope ] [--sitesTableId ] [--sitesTableName ] +``` + +### Get a siteSurfaceModule by id + +```bash +csdk site-surface-module get --id +``` diff --git a/.agents/skills/hooks-admin/references/org-is-manager-of.md b/.agents/skills/hooks-admin/references/org-is-manager-of.md index a441357bc..580cd218b 100644 --- a/.agents/skills/hooks-admin/references/org-is-manager-of.md +++ b/.agents/skills/hooks-admin/references/org-is-manager-of.md @@ -7,7 +7,7 @@ React Query query hook for orgIsManagerOf ## Usage ```typescript -useOrgIsManagerOfQuery({ pEntityId: '', pManagerId: '', pMaxDepth: '', pUserId: '' }) +useOrgIsManagerOfQuery({ managerId: '', maxDepth: '', targetEntityId: '', userId: '' }) ``` ## Examples @@ -15,5 +15,5 @@ useOrgIsManagerOfQuery({ pEntityId: '', pManagerId: '', pMaxDepth: ' ### Use useOrgIsManagerOfQuery ```typescript -const { data, isLoading } = useOrgIsManagerOfQuery({ pEntityId: '', pManagerId: '', pMaxDepth: '', pUserId: '' }); +const { data, isLoading } = useOrgIsManagerOfQuery({ managerId: '', maxDepth: '', targetEntityId: '', userId: '' }); ``` diff --git a/.agents/skills/hooks-api/SKILL.md b/.agents/skills/hooks-api/SKILL.md index 7e02f82c0..defd6ea48 100644 --- a/.agents/skills/hooks-api/SKILL.md +++ b/.agents/skills/hooks-api/SKILL.md @@ -1,13 +1,13 @@ --- name: hooks-api -description: React Query hooks for the api API — provides typed query and mutation hooks for 47 tables and 9 custom operations +description: React Query hooks for the api API — provides typed query and mutation hooks for 49 tables and 9 custom operations --- # hooks-api -React Query hooks for the api API — provides typed query and mutation hooks for 47 tables and 9 custom operations +React Query hooks for the api API — provides typed query and mutation hooks for 49 tables and 9 custom operations ## Usage @@ -52,6 +52,8 @@ See the `references/` directory for detailed per-entity API documentation: - [database-transfer](references/database-transfer.md) - [default-privilege](references/default-privilege.md) - [domain](references/domain.md) +- [domain-event](references/domain-event.md) +- [domain-verification](references/domain-verification.md) - [embedding-chunk](references/embedding-chunk.md) - [enum](references/enum.md) - [field](references/field.md) diff --git a/.agents/skills/hooks-api/references/domain-event.md b/.agents/skills/hooks-api/references/domain-event.md new file mode 100644 index 000000000..61ecb78d6 --- /dev/null +++ b/.agents/skills/hooks-api/references/domain-event.md @@ -0,0 +1,34 @@ +# domainEvent + + + +Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + +## Usage + +```typescript +useDomainEventsQuery({ selection: { fields: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } } }) +useDomainEventQuery({ id: '', selection: { fields: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } } }) +useCreateDomainEventMutation({ selection: { fields: { id: true } } }) +useUpdateDomainEventMutation({ selection: { fields: { id: true } } }) +useDeleteDomainEventMutation({}) +``` + +## Examples + +### List all domainEvents + +```typescript +const { data, isLoading } = useDomainEventsQuery({ + selection: { fields: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }, +}); +``` + +### Create a domainEvent + +```typescript +const { mutate } = useCreateDomainEventMutation({ + selection: { fields: { id: true } }, +}); +mutate({ actorId: '', domainVerificationId: '', eventType: '', managedDomainId: '', message: '', metadata: '', ownerId: '' }); +``` diff --git a/.agents/skills/hooks-api/references/domain-verification.md b/.agents/skills/hooks-api/references/domain-verification.md new file mode 100644 index 000000000..263937b9c --- /dev/null +++ b/.agents/skills/hooks-api/references/domain-verification.md @@ -0,0 +1,34 @@ +# domainVerification + + + +One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + +## Usage + +```typescript +useDomainVerificationsQuery({ selection: { fields: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } } }) +useDomainVerificationQuery({ id: '', selection: { fields: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } } }) +useCreateDomainVerificationMutation({ selection: { fields: { id: true } } }) +useUpdateDomainVerificationMutation({ selection: { fields: { id: true } } }) +useDeleteDomainVerificationMutation({}) +``` + +## Examples + +### List all domainVerifications + +```typescript +const { data, isLoading } = useDomainVerificationsQuery({ + selection: { fields: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }, +}); +``` + +### Create a domainVerification + +```typescript +const { mutate } = useCreateDomainVerificationMutation({ + selection: { fields: { id: true } }, +}); +mutate({ attempts: '', error: '', expiresAt: '', lastCheckedAt: '', managedDomainId: '', method: '', ownerId: '', recordName: '', recordType: '', recordValue: '', status: '', verifiedAt: '' }); +``` diff --git a/.agents/skills/hooks-api/references/managed-domain.md b/.agents/skills/hooks-api/references/managed-domain.md index 5973a4109..728923e32 100644 --- a/.agents/skills/hooks-api/references/managed-domain.md +++ b/.agents/skills/hooks-api/references/managed-domain.md @@ -7,8 +7,8 @@ One row per cert-bearing host or wildcard; tracks domain verification and TLS pr ## Usage ```typescript -useManagedDomainsQuery({ selection: { fields: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } } }) -useManagedDomainQuery({ id: '', selection: { fields: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } } }) +useManagedDomainsQuery({ selection: { fields: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } } }) +useManagedDomainQuery({ id: '', selection: { fields: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } } }) useCreateManagedDomainMutation({ selection: { fields: { id: true } } }) useUpdateManagedDomainMutation({ selection: { fields: { id: true } } }) useDeleteManagedDomainMutation({}) @@ -20,7 +20,7 @@ useDeleteManagedDomainMutation({}) ```typescript const { data, isLoading } = useManagedDomainsQuery({ - selection: { fields: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }, + selection: { fields: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }, }); ``` @@ -30,5 +30,5 @@ const { data, isLoading } = useManagedDomainsQuery({ const { mutate } = useCreateManagedDomainMutation({ selection: { fields: { id: true } }, }); -mutate({ annotations: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }); +mutate({ allowPublicUsage: '', annotations: '', certStatus: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }); ``` diff --git a/.agents/skills/hooks-api/references/request-database.md b/.agents/skills/hooks-api/references/request-database.md index b464c30fc..987df6a1f 100644 --- a/.agents/skills/hooks-api/references/request-database.md +++ b/.agents/skills/hooks-api/references/request-database.md @@ -4,7 +4,7 @@ Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/.agents/skills/hooks-api/references/resolve-http-route.md b/.agents/skills/hooks-api/references/resolve-http-route.md index 4a37cf4f4..602f0df62 100644 --- a/.agents/skills/hooks-api/references/resolve-http-route.md +++ b/.agents/skills/hooks-api/references/resolve-http-route.md @@ -7,7 +7,7 @@ React Query query hook for resolveHttpRoute ## Usage ```typescript -useResolveHttpRouteQuery({ pHost: '', pMethod: '', pPath: '' }) +useResolveHttpRouteQuery({ requestHost: '', requestMethod: '', requestPath: '' }) ``` ## Examples @@ -15,5 +15,5 @@ useResolveHttpRouteQuery({ pHost: '', pMethod: '', pPath: '', pMethod: '', pPath: '' }); +const { data, isLoading } = useResolveHttpRouteQuery({ requestHost: '', requestMethod: '', requestPath: '' }); ``` diff --git a/.agents/skills/hooks-compute/SKILL.md b/.agents/skills/hooks-compute/SKILL.md index 42bbe6eb5..71080d4f7 100644 --- a/.agents/skills/hooks-compute/SKILL.md +++ b/.agents/skills/hooks-compute/SKILL.md @@ -1,13 +1,13 @@ --- name: hooks-compute -description: React Query hooks for the compute API — provides typed query and mutation hooks for 65 tables and 29 custom operations +description: React Query hooks for the compute API — provides typed query and mutation hooks for 67 tables and 29 custom operations --- # hooks-compute -React Query hooks for the compute API — provides typed query and mutation hooks for 65 tables and 29 custom operations +React Query hooks for the compute API — provides typed query and mutation hooks for 67 tables and 29 custom operations ## Usage @@ -39,7 +39,6 @@ const { data, isLoading } = useDbPresetsQuery({ See the `references/` directory for detailed per-entity API documentation: - [db-preset](references/db-preset.md) -- [declared-capacity](references/declared-capacity.md) - [function-api-binding](references/function-api-binding.md) - [function-definition](references/function-definition.md) - [function-deployment](references/function-deployment.md) @@ -53,6 +52,7 @@ See the `references/` directory for detailed per-entity API documentation: - [function-graph-object](references/function-graph-object.md) - [function-graph-ref](references/function-graph-ref.md) - [function-graph-store](references/function-graph-store.md) +- [function-invocation-attempt](references/function-invocation-attempt.md) - [function-invocation](references/function-invocation.md) - [get-all-tree-nodes-record](references/get-all-tree-nodes-record.md) - [infra-commit](references/infra-commit.md) @@ -63,12 +63,12 @@ See the `references/` directory for detailed per-entity API documentation: - [integration-provider](references/integration-provider.md) - [namespace](references/namespace.md) - [namespace-event](references/namespace-event.md) -- [platform-declared-capacity](references/platform-declared-capacity.md) - [platform-function-api-binding](references/platform-function-api-binding.md) - [platform-function-definition](references/platform-function-definition.md) - [platform-function-deployment](references/platform-function-deployment.md) - [platform-function-deployment-event](references/platform-function-deployment-event.md) - [platform-function-execution-log](references/platform-function-execution-log.md) +- [platform-function-invocation-attempt](references/platform-function-invocation-attempt.md) - [platform-function-invocation](references/platform-function-invocation.md) - [platform-infra-commit](references/platform-infra-commit.md) - [platform-infra-get-all-tree-nodes-record](references/platform-infra-get-all-tree-nodes-record.md) @@ -78,26 +78,28 @@ See the `references/` directory for detailed per-entity API documentation: - [platform-namespace](references/platform-namespace.md) - [platform-namespace-event](references/platform-namespace-event.md) - [platform-resource](references/platform-resource.md) +- [platform-resource-declared-capacity](references/platform-resource-declared-capacity.md) - [platform-resource-definition](references/platform-resource-definition.md) - [platform-resource-event](references/platform-resource-event.md) - [platform-resource-installation](references/platform-resource-installation.md) - [platform-resource-status-check](references/platform-resource-status-check.md) - [platform-resource-usage-log](references/platform-resource-usage-log.md) - [platform-resource-usage-summary](references/platform-resource-usage-summary.md) -- [platform-resource-utilization-daily](references/platform-resource-utilization-daily.md) +- [platform-resource-utilization](references/platform-resource-utilization.md) - [platform-resources-health](references/platform-resources-health.md) - [platform-resources-requirements-state](references/platform-resources-requirements-state.md) - [platform-resources-resolved-requirement](references/platform-resources-resolved-requirement.md) - [platform-webhook-endpoint](references/platform-webhook-endpoint.md) - [platform-webhook-event](references/platform-webhook-event.md) - [resource](references/resource.md) +- [resource-declared-capacity](references/resource-declared-capacity.md) - [resource-definition](references/resource-definition.md) - [resource-event](references/resource-event.md) - [resource-installation](references/resource-installation.md) - [resource-status-check](references/resource-status-check.md) - [resource-usage-log](references/resource-usage-log.md) - [resource-usage-summary](references/resource-usage-summary.md) -- [resource-utilization-daily](references/resource-utilization-daily.md) +- [resource-utilization](references/resource-utilization.md) - [resources-health](references/resources-health.md) - [resources-requirements-state](references/resources-requirements-state.md) - [resources-resolved-requirement](references/resources-resolved-requirement.md) diff --git a/.agents/skills/hooks-compute/references/function-invocation-attempt.md b/.agents/skills/hooks-compute/references/function-invocation-attempt.md new file mode 100644 index 000000000..44b5f3d7f --- /dev/null +++ b/.agents/skills/hooks-compute/references/function-invocation-attempt.md @@ -0,0 +1,34 @@ +# functionInvocationAttempt + + + +Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + +## Usage + +```typescript +useFunctionInvocationAttemptsQuery({ selection: { fields: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } } }) +useFunctionInvocationAttemptQuery({ id: '', selection: { fields: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } } }) +useCreateFunctionInvocationAttemptMutation({ selection: { fields: { id: true } } }) +useUpdateFunctionInvocationAttemptMutation({ selection: { fields: { id: true } } }) +useDeleteFunctionInvocationAttemptMutation({}) +``` + +## Examples + +### List all functionInvocationAttempts + +```typescript +const { data, isLoading } = useFunctionInvocationAttemptsQuery({ + selection: { fields: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }, +}); +``` + +### Create a functionInvocationAttempt + +```typescript +const { mutate } = useCreateFunctionInvocationAttemptMutation({ + selection: { fields: { id: true } }, +}); +mutate({ actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }); +``` diff --git a/.agents/skills/hooks-compute/references/platform-function-definition.md b/.agents/skills/hooks-compute/references/platform-function-definition.md index edf61b696..739c3642b 100644 --- a/.agents/skills/hooks-compute/references/platform-function-definition.md +++ b/.agents/skills/hooks-compute/references/platform-function-definition.md @@ -7,8 +7,8 @@ Function definitions — registered cloud functions with routing, queue, and ret ## Usage ```typescript -usePlatformFunctionDefinitionsQuery({ selection: { fields: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } } }) -usePlatformFunctionDefinitionQuery({ id: '', selection: { fields: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } } }) +usePlatformFunctionDefinitionsQuery({ selection: { fields: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } } }) +usePlatformFunctionDefinitionQuery({ id: '', selection: { fields: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } } }) useCreatePlatformFunctionDefinitionMutation({ selection: { fields: { id: true } } }) useUpdatePlatformFunctionDefinitionMutation({ selection: { fields: { id: true } } }) useDeletePlatformFunctionDefinitionMutation({}) @@ -20,7 +20,7 @@ useDeletePlatformFunctionDefinitionMutation({}) ```typescript const { data, isLoading } = usePlatformFunctionDefinitionsQuery({ - selection: { fields: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }, + selection: { fields: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }, }); ``` @@ -30,5 +30,5 @@ const { data, isLoading } = usePlatformFunctionDefinitionsQuery({ const { mutate } = useCreatePlatformFunctionDefinitionMutation({ selection: { fields: { id: true } }, }); -mutate({ accessChannels: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }); +mutate({ accessChannels: '', billable: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }); ``` diff --git a/.agents/skills/hooks-compute/references/platform-function-invocation-attempt.md b/.agents/skills/hooks-compute/references/platform-function-invocation-attempt.md new file mode 100644 index 000000000..0b5dc5d2e --- /dev/null +++ b/.agents/skills/hooks-compute/references/platform-function-invocation-attempt.md @@ -0,0 +1,34 @@ +# platformFunctionInvocationAttempt + + + +Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + +## Usage + +```typescript +usePlatformFunctionInvocationAttemptsQuery({ selection: { fields: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } } }) +usePlatformFunctionInvocationAttemptQuery({ id: '', selection: { fields: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } } }) +useCreatePlatformFunctionInvocationAttemptMutation({ selection: { fields: { id: true } } }) +useUpdatePlatformFunctionInvocationAttemptMutation({ selection: { fields: { id: true } } }) +useDeletePlatformFunctionInvocationAttemptMutation({}) +``` + +## Examples + +### List all platformFunctionInvocationAttempts + +```typescript +const { data, isLoading } = usePlatformFunctionInvocationAttemptsQuery({ + selection: { fields: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }, +}); +``` + +### Create a platformFunctionInvocationAttempt + +```typescript +const { mutate } = useCreatePlatformFunctionInvocationAttemptMutation({ + selection: { fields: { id: true } }, +}); +mutate({ actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }); +``` diff --git a/.agents/skills/hooks-compute/references/platform-resource-declared-capacity.md b/.agents/skills/hooks-compute/references/platform-resource-declared-capacity.md new file mode 100644 index 000000000..b6bb58d82 --- /dev/null +++ b/.agents/skills/hooks-compute/references/platform-resource-declared-capacity.md @@ -0,0 +1,31 @@ +# platformResourceDeclaredCapacity + + + +React Query hooks for PlatformResourceDeclaredCapacity data operations + +## Usage + +```typescript +usePlatformResourceDeclaredCapacitiesQuery({ selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } } }) +useCreatePlatformResourceDeclaredCapacityMutation({ selection: { fields: { id: true } } }) +``` + +## Examples + +### List all platformResourceDeclaredCapacities + +```typescript +const { data, isLoading } = usePlatformResourceDeclaredCapacitiesQuery({ + selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }, +}); +``` + +### Create a platformResourceDeclaredCapacity + +```typescript +const { mutate } = useCreatePlatformResourceDeclaredCapacityMutation({ + selection: { fields: { id: true } }, +}); +mutate({ cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }); +``` diff --git a/.agents/skills/hooks-compute/references/platform-resource-installations-install.md b/.agents/skills/hooks-compute/references/platform-resource-installations-install.md index 49be7db4b..4b7e6f120 100644 --- a/.agents/skills/hooks-compute/references/platform-resource-installations-install.md +++ b/.agents/skills/hooks-compute/references/platform-resource-installations-install.md @@ -7,7 +7,7 @@ React Query mutation hook for platformResourceInstallationsInstall ## Usage ```typescript -const { mutate } = usePlatformResourceInstallationsInstallMutation(); mutate({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }); +const { mutate } = usePlatformResourceInstallationsInstallMutation(); mutate({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = usePlatformResourceInstallationsInstallMutation(); mutate({ i ```typescript const { mutate, isLoading } = usePlatformResourceInstallationsInstallMutation(); -mutate({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }); +mutate({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/platform-resource-installations-rollback.md b/.agents/skills/hooks-compute/references/platform-resource-installations-rollback.md index e074494c3..e92044f3c 100644 --- a/.agents/skills/hooks-compute/references/platform-resource-installations-rollback.md +++ b/.agents/skills/hooks-compute/references/platform-resource-installations-rollback.md @@ -7,7 +7,7 @@ React Query mutation hook for platformResourceInstallationsRollback ## Usage ```typescript -const { mutate } = usePlatformResourceInstallationsRollbackMutation(); mutate({ input: { pCommitId: '', pInstallationId: '' } }); +const { mutate } = usePlatformResourceInstallationsRollbackMutation(); mutate({ input: { commitId: '', targetInstallationId: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = usePlatformResourceInstallationsRollbackMutation(); mutate({ ```typescript const { mutate, isLoading } = usePlatformResourceInstallationsRollbackMutation(); -mutate({ input: { pCommitId: '', pInstallationId: '' } }); +mutate({ input: { commitId: '', targetInstallationId: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/platform-resource-installations-uninstall.md b/.agents/skills/hooks-compute/references/platform-resource-installations-uninstall.md index 49ebd9583..0bd9f312f 100644 --- a/.agents/skills/hooks-compute/references/platform-resource-installations-uninstall.md +++ b/.agents/skills/hooks-compute/references/platform-resource-installations-uninstall.md @@ -7,7 +7,7 @@ React Query mutation hook for platformResourceInstallationsUninstall ## Usage ```typescript -const { mutate } = usePlatformResourceInstallationsUninstallMutation(); mutate({ input: { pInstallationId: '' } }); +const { mutate } = usePlatformResourceInstallationsUninstallMutation(); mutate({ input: { targetInstallationId: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = usePlatformResourceInstallationsUninstallMutation(); mutate({ ```typescript const { mutate, isLoading } = usePlatformResourceInstallationsUninstallMutation(); -mutate({ input: { pInstallationId: '' } }); +mutate({ input: { targetInstallationId: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/platform-resource-installations-upgrade.md b/.agents/skills/hooks-compute/references/platform-resource-installations-upgrade.md index a2460afd0..cdd29596b 100644 --- a/.agents/skills/hooks-compute/references/platform-resource-installations-upgrade.md +++ b/.agents/skills/hooks-compute/references/platform-resource-installations-upgrade.md @@ -7,7 +7,7 @@ React Query mutation hook for platformResourceInstallationsUpgrade ## Usage ```typescript -const { mutate } = usePlatformResourceInstallationsUpgradeMutation(); mutate({ input: { pInstallationId: '', pParams: '' } }); +const { mutate } = usePlatformResourceInstallationsUpgradeMutation(); mutate({ input: { newParams: '', targetInstallationId: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = usePlatformResourceInstallationsUpgradeMutation(); mutate({ i ```typescript const { mutate, isLoading } = usePlatformResourceInstallationsUpgradeMutation(); -mutate({ input: { pInstallationId: '', pParams: '' } }); +mutate({ input: { newParams: '', targetInstallationId: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/platform-resource-usage-log.md b/.agents/skills/hooks-compute/references/platform-resource-usage-log.md index be1710c46..3a759d5df 100644 --- a/.agents/skills/hooks-compute/references/platform-resource-usage-log.md +++ b/.agents/skills/hooks-compute/references/platform-resource-usage-log.md @@ -2,7 +2,7 @@ -Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) +Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) ## Usage diff --git a/.agents/skills/hooks-compute/references/platform-resource-utilization.md b/.agents/skills/hooks-compute/references/platform-resource-utilization.md new file mode 100644 index 000000000..445ced6e9 --- /dev/null +++ b/.agents/skills/hooks-compute/references/platform-resource-utilization.md @@ -0,0 +1,31 @@ +# platformResourceUtilization + + + +React Query hooks for PlatformResourceUtilization data operations + +## Usage + +```typescript +usePlatformResourceUtilizationsQuery({ selection: { fields: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } } }) +useCreatePlatformResourceUtilizationMutation({ selection: { fields: { id: true } } }) +``` + +## Examples + +### List all platformResourceUtilizations + +```typescript +const { data, isLoading } = usePlatformResourceUtilizationsQuery({ + selection: { fields: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }, +}); +``` + +### Create a platformResourceUtilization + +```typescript +const { mutate } = useCreatePlatformResourceUtilizationMutation({ + selection: { fields: { id: true } }, +}); +mutate({ avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }); +``` diff --git a/.agents/skills/hooks-compute/references/resource-declared-capacity.md b/.agents/skills/hooks-compute/references/resource-declared-capacity.md new file mode 100644 index 000000000..0e6fa41d9 --- /dev/null +++ b/.agents/skills/hooks-compute/references/resource-declared-capacity.md @@ -0,0 +1,31 @@ +# resourceDeclaredCapacity + + + +React Query hooks for ResourceDeclaredCapacity data operations + +## Usage + +```typescript +useResourceDeclaredCapacitiesQuery({ selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } } }) +useCreateResourceDeclaredCapacityMutation({ selection: { fields: { id: true } } }) +``` + +## Examples + +### List all resourceDeclaredCapacities + +```typescript +const { data, isLoading } = useResourceDeclaredCapacitiesQuery({ + selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }, +}); +``` + +### Create a resourceDeclaredCapacity + +```typescript +const { mutate } = useCreateResourceDeclaredCapacityMutation({ + selection: { fields: { id: true } }, +}); +mutate({ cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }); +``` diff --git a/.agents/skills/hooks-compute/references/resource-installations-install.md b/.agents/skills/hooks-compute/references/resource-installations-install.md index 6614092fd..b467d9111 100644 --- a/.agents/skills/hooks-compute/references/resource-installations-install.md +++ b/.agents/skills/hooks-compute/references/resource-installations-install.md @@ -7,7 +7,7 @@ React Query mutation hook for resourceInstallationsInstall ## Usage ```typescript -const { mutate } = useResourceInstallationsInstallMutation(); mutate({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }); +const { mutate } = useResourceInstallationsInstallMutation(); mutate({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = useResourceInstallationsInstallMutation(); mutate({ input: { ```typescript const { mutate, isLoading } = useResourceInstallationsInstallMutation(); -mutate({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }); +mutate({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/resource-installations-rollback.md b/.agents/skills/hooks-compute/references/resource-installations-rollback.md index 0a45d0e7c..be8a44b62 100644 --- a/.agents/skills/hooks-compute/references/resource-installations-rollback.md +++ b/.agents/skills/hooks-compute/references/resource-installations-rollback.md @@ -7,7 +7,7 @@ React Query mutation hook for resourceInstallationsRollback ## Usage ```typescript -const { mutate } = useResourceInstallationsRollbackMutation(); mutate({ input: { pCommitId: '', pInstallationId: '' } }); +const { mutate } = useResourceInstallationsRollbackMutation(); mutate({ input: { commitId: '', targetInstallationId: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = useResourceInstallationsRollbackMutation(); mutate({ input: { ```typescript const { mutate, isLoading } = useResourceInstallationsRollbackMutation(); -mutate({ input: { pCommitId: '', pInstallationId: '' } }); +mutate({ input: { commitId: '', targetInstallationId: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/resource-installations-uninstall.md b/.agents/skills/hooks-compute/references/resource-installations-uninstall.md index af2b5ef89..ce0ce2a2b 100644 --- a/.agents/skills/hooks-compute/references/resource-installations-uninstall.md +++ b/.agents/skills/hooks-compute/references/resource-installations-uninstall.md @@ -7,7 +7,7 @@ React Query mutation hook for resourceInstallationsUninstall ## Usage ```typescript -const { mutate } = useResourceInstallationsUninstallMutation(); mutate({ input: { pInstallationId: '' } }); +const { mutate } = useResourceInstallationsUninstallMutation(); mutate({ input: { targetInstallationId: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = useResourceInstallationsUninstallMutation(); mutate({ input: ```typescript const { mutate, isLoading } = useResourceInstallationsUninstallMutation(); -mutate({ input: { pInstallationId: '' } }); +mutate({ input: { targetInstallationId: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/resource-installations-upgrade.md b/.agents/skills/hooks-compute/references/resource-installations-upgrade.md index ccf7f61bf..a46aef488 100644 --- a/.agents/skills/hooks-compute/references/resource-installations-upgrade.md +++ b/.agents/skills/hooks-compute/references/resource-installations-upgrade.md @@ -7,7 +7,7 @@ React Query mutation hook for resourceInstallationsUpgrade ## Usage ```typescript -const { mutate } = useResourceInstallationsUpgradeMutation(); mutate({ input: { pInstallationId: '', pParams: '' } }); +const { mutate } = useResourceInstallationsUpgradeMutation(); mutate({ input: { newParams: '', targetInstallationId: '' } }); ``` ## Examples @@ -16,5 +16,5 @@ const { mutate } = useResourceInstallationsUpgradeMutation(); mutate({ input: { ```typescript const { mutate, isLoading } = useResourceInstallationsUpgradeMutation(); -mutate({ input: { pInstallationId: '', pParams: '' } }); +mutate({ input: { newParams: '', targetInstallationId: '' } }); ``` diff --git a/.agents/skills/hooks-compute/references/resource-usage-log.md b/.agents/skills/hooks-compute/references/resource-usage-log.md index 45e5b8e6d..977d4dfbb 100644 --- a/.agents/skills/hooks-compute/references/resource-usage-log.md +++ b/.agents/skills/hooks-compute/references/resource-usage-log.md @@ -2,7 +2,7 @@ -Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) +Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) ## Usage diff --git a/.agents/skills/hooks-compute/references/resource-utilization.md b/.agents/skills/hooks-compute/references/resource-utilization.md new file mode 100644 index 000000000..bac248c8d --- /dev/null +++ b/.agents/skills/hooks-compute/references/resource-utilization.md @@ -0,0 +1,31 @@ +# resourceUtilization + + + +React Query hooks for ResourceUtilization data operations + +## Usage + +```typescript +useResourceUtilizationsQuery({ selection: { fields: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } } }) +useCreateResourceUtilizationMutation({ selection: { fields: { id: true } } }) +``` + +## Examples + +### List all resourceUtilizations + +```typescript +const { data, isLoading } = useResourceUtilizationsQuery({ + selection: { fields: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }, +}); +``` + +### Create a resourceUtilization + +```typescript +const { mutate } = useCreateResourceUtilizationMutation({ + selection: { fields: { id: true } }, +}); +mutate({ avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }); +``` diff --git a/.agents/skills/hooks-modules/SKILL.md b/.agents/skills/hooks-modules/SKILL.md index 53acd86cb..c4afca4b9 100644 --- a/.agents/skills/hooks-modules/SKILL.md +++ b/.agents/skills/hooks-modules/SKILL.md @@ -1,13 +1,13 @@ --- name: hooks-modules -description: React Query hooks for the modules API — provides typed query and mutation hooks for 68 tables and 12 custom operations +description: React Query hooks for the modules API — provides typed query and mutation hooks for 74 tables and 12 custom operations --- # hooks-modules -React Query hooks for the modules API — provides typed query and mutation hooks for 68 tables and 12 custom operations +React Query hooks for the modules API — provides typed query and mutation hooks for 74 tables and 12 custom operations ## Usage @@ -39,11 +39,14 @@ const { data, isLoading } = useAgentModulesQuery({ See the `references/` directory for detailed per-entity API documentation: - [agent-module](references/agent-module.md) +- [api-surface-module](references/api-surface-module.md) +- [app-module](references/app-module.md) - [billing-module](references/billing-module.md) - [billing-provider-module](references/billing-provider-module.md) - [blueprint](references/blueprint.md) - [blueprint-construction](references/blueprint-construction.md) - [blueprint-template](references/blueprint-template.md) +- [catalog-module](references/catalog-module.md) - [compute-log-module](references/compute-log-module.md) - [config-secrets-user-module](references/config-secrets-user-module.md) - [connected-accounts-module](references/connected-accounts-module.md) @@ -57,6 +60,7 @@ See the `references/` directory for detailed per-entity API documentation: - [default-ids-module](references/default-ids-module.md) - [denormalized-table-field](references/denormalized-table-field.md) - [devices-module](references/devices-module.md) +- [domain-module](references/domain-module.md) - [emails-module](references/emails-module.md) - [entity-type-provision](references/entity-type-provision.md) - [events-module](references/events-module.md) @@ -92,9 +96,11 @@ See the `references/` directory for detailed per-entity API documentation: - [relation-provision](references/relation-provision.md) - [resource-module](references/resource-module.md) - [rls-module](references/rls-module.md) +- [route-module](references/route-module.md) - [secure-table-provision](references/secure-table-provision.md) - [session-secrets-module](references/session-secrets-module.md) - [sessions-module](references/sessions-module.md) +- [site-surface-module](references/site-surface-module.md) - [storage-log-module](references/storage-log-module.md) - [storage-module](references/storage-module.md) - [transfer-log-module](references/transfer-log-module.md) diff --git a/.agents/skills/hooks-modules/references/api-surface-module.md b/.agents/skills/hooks-modules/references/api-surface-module.md new file mode 100644 index 000000000..078f24733 --- /dev/null +++ b/.agents/skills/hooks-modules/references/api-surface-module.md @@ -0,0 +1,34 @@ +# apiSurfaceModule + + + +React Query hooks for ApiSurfaceModule data operations + +## Usage + +```typescript +useApiSurfaceModulesQuery({ selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useApiSurfaceModuleQuery({ id: '', selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useCreateApiSurfaceModuleMutation({ selection: { fields: { id: true } } }) +useUpdateApiSurfaceModuleMutation({ selection: { fields: { id: true } } }) +useDeleteApiSurfaceModuleMutation({}) +``` + +## Examples + +### List all apiSurfaceModules + +```typescript +const { data, isLoading } = useApiSurfaceModulesQuery({ + selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); +``` + +### Create a apiSurfaceModule + +```typescript +const { mutate } = useCreateApiSurfaceModuleMutation({ + selection: { fields: { id: true } }, +}); +mutate({ apiName: '', apisTableId: '', apisTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +``` diff --git a/.agents/skills/hooks-modules/references/app-module.md b/.agents/skills/hooks-modules/references/app-module.md new file mode 100644 index 000000000..6019df100 --- /dev/null +++ b/.agents/skills/hooks-modules/references/app-module.md @@ -0,0 +1,34 @@ +# appModule + + + +React Query hooks for AppModule data operations + +## Usage + +```typescript +useAppModulesQuery({ selection: { fields: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useAppModuleQuery({ id: '', selection: { fields: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useCreateAppModuleMutation({ selection: { fields: { id: true } } }) +useUpdateAppModuleMutation({ selection: { fields: { id: true } } }) +useDeleteAppModuleMutation({}) +``` + +## Examples + +### List all appModules + +```typescript +const { data, isLoading } = useAppModulesQuery({ + selection: { fields: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); +``` + +### Create a appModule + +```typescript +const { mutate } = useCreateAppModuleMutation({ + selection: { fields: { id: true } }, +}); +mutate({ apiName: '', appMembersTableId: '', appMembersTableName: '', appsTableId: '', appsTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +``` diff --git a/.agents/skills/hooks-modules/references/catalog-module.md b/.agents/skills/hooks-modules/references/catalog-module.md new file mode 100644 index 000000000..e4ceeb1ae --- /dev/null +++ b/.agents/skills/hooks-modules/references/catalog-module.md @@ -0,0 +1,34 @@ +# catalogModule + + + +React Query hooks for CatalogModule data operations + +## Usage + +```typescript +useCatalogModulesQuery({ selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } } }) +useCatalogModuleQuery({ id: '', selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } } }) +useCreateCatalogModuleMutation({ selection: { fields: { id: true } } }) +useUpdateCatalogModuleMutation({ selection: { fields: { id: true } } }) +useDeleteCatalogModuleMutation({}) +``` + +## Examples + +### List all catalogModules + +```typescript +const { data, isLoading } = useCatalogModulesQuery({ + selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }, +}); +``` + +### Create a catalogModule + +```typescript +const { mutate } = useCreateCatalogModuleMutation({ + selection: { fields: { id: true } }, +}); +mutate({ apiName: '', apisTableId: '', apisTableName: '', appsTableId: '', appsTableName: '', databaseId: '', defaultPermissions: '', domainsTableId: '', domainsTableName: '', entityTableId: '', functionsTableId: '', functionsTableName: '', namespacesTableId: '', namespacesTableName: '', policies: '', privateApiName: '', provisions: '', publicSchemaName: '', resourceDefinitionsTableId: '', resourceDefinitionsTableName: '', resourceInstallationsTableId: '', resourceInstallationsTableName: '', resourcesTableId: '', resourcesTableName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }); +``` diff --git a/.agents/skills/hooks-modules/references/database-provision-module.md b/.agents/skills/hooks-modules/references/database-provision-module.md index 516cbc156..c0ee4b241 100644 --- a/.agents/skills/hooks-modules/references/database-provision-module.md +++ b/.agents/skills/hooks-modules/references/database-provision-module.md @@ -7,8 +7,8 @@ Tracks database provisioning requests and their status. The BEFORE INSERT trigge ## Usage ```typescript -useDatabaseProvisionModulesQuery({ selection: { fields: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } } }) -useDatabaseProvisionModuleQuery({ id: '', selection: { fields: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } } }) +useDatabaseProvisionModulesQuery({ selection: { fields: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } } }) +useDatabaseProvisionModuleQuery({ id: '', selection: { fields: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } } }) useCreateDatabaseProvisionModuleMutation({ selection: { fields: { id: true } } }) useUpdateDatabaseProvisionModuleMutation({ selection: { fields: { id: true } } }) useDeleteDatabaseProvisionModuleMutation({}) @@ -20,7 +20,7 @@ useDeleteDatabaseProvisionModuleMutation({}) ```typescript const { data, isLoading } = useDatabaseProvisionModulesQuery({ - selection: { fields: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }, + selection: { fields: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }, }); ``` @@ -30,5 +30,5 @@ const { data, isLoading } = useDatabaseProvisionModulesQuery({ const { mutate } = useCreateDatabaseProvisionModuleMutation({ selection: { fields: { id: true } }, }); -mutate({ bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }); +mutate({ async: '', bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }); ``` diff --git a/.agents/skills/hooks-modules/references/domain-module.md b/.agents/skills/hooks-modules/references/domain-module.md new file mode 100644 index 000000000..5b9fd448a --- /dev/null +++ b/.agents/skills/hooks-modules/references/domain-module.md @@ -0,0 +1,34 @@ +# domainModule + + + +React Query hooks for DomainModule data operations + +## Usage + +```typescript +useDomainModulesQuery({ selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useDomainModuleQuery({ id: '', selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useCreateDomainModuleMutation({ selection: { fields: { id: true } } }) +useUpdateDomainModuleMutation({ selection: { fields: { id: true } } }) +useDeleteDomainModuleMutation({}) +``` + +## Examples + +### List all domainModules + +```typescript +const { data, isLoading } = useDomainModulesQuery({ + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); +``` + +### Create a domainModule + +```typescript +const { mutate } = useCreateDomainModuleMutation({ + selection: { fields: { id: true } }, +}); +mutate({ apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainEventsTableId: '', domainEventsTableName: '', domainVerificationsTableId: '', domainVerificationsTableName: '', domainsTableId: '', domainsTableName: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +``` diff --git a/.agents/skills/hooks-modules/references/function-invocation-module.md b/.agents/skills/hooks-modules/references/function-invocation-module.md index 523b40f2f..62781b0db 100644 --- a/.agents/skills/hooks-modules/references/function-invocation-module.md +++ b/.agents/skills/hooks-modules/references/function-invocation-module.md @@ -7,8 +7,8 @@ React Query hooks for FunctionInvocationModule data operations ## Usage ```typescript -useFunctionInvocationModulesQuery({ selection: { fields: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) -useFunctionInvocationModuleQuery({ id: '', selection: { fields: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useFunctionInvocationModulesQuery({ selection: { fields: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) +useFunctionInvocationModuleQuery({ id: '', selection: { fields: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } } }) useCreateFunctionInvocationModuleMutation({ selection: { fields: { id: true } } }) useUpdateFunctionInvocationModuleMutation({ selection: { fields: { id: true } } }) useDeleteFunctionInvocationModuleMutation({}) @@ -20,7 +20,7 @@ useDeleteFunctionInvocationModuleMutation({}) ```typescript const { data, isLoading } = useFunctionInvocationModulesQuery({ - selection: { fields: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, + selection: { fields: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, }); ``` @@ -30,5 +30,5 @@ const { data, isLoading } = useFunctionInvocationModulesQuery({ const { mutate } = useCreateFunctionInvocationModuleMutation({ selection: { fields: { id: true } }, }); -mutate({ apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +mutate({ apiName: '', attemptsTableId: '', attemptsTableName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); ``` diff --git a/.agents/skills/hooks-modules/references/route-module.md b/.agents/skills/hooks-modules/references/route-module.md new file mode 100644 index 000000000..9d8b50490 --- /dev/null +++ b/.agents/skills/hooks-modules/references/route-module.md @@ -0,0 +1,34 @@ +# routeModule + + + +React Query hooks for RouteModule data operations + +## Usage + +```typescript +useRouteModulesQuery({ selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } } }) +useRouteModuleQuery({ id: '', selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } } }) +useCreateRouteModuleMutation({ selection: { fields: { id: true } } }) +useUpdateRouteModuleMutation({ selection: { fields: { id: true } } }) +useDeleteRouteModuleMutation({}) +``` + +## Examples + +### List all routeModules + +```typescript +const { data, isLoading } = useRouteModulesQuery({ + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }, +}); +``` + +### Create a routeModule + +```typescript +const { mutate } = useCreateRouteModuleMutation({ + selection: { fields: { id: true } }, +}); +mutate({ apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainModuleId: '', entityField: '', entityTableId: '', hostnameBindingsTableId: '', hostnameBindingsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', resolverFunctionName: '', routeBindingsTableId: '', routeBindingsTableName: '', routesTableId: '', routesTableName: '', schemaId: '', scope: '' }); +``` diff --git a/.agents/skills/hooks-modules/references/site-surface-module.md b/.agents/skills/hooks-modules/references/site-surface-module.md new file mode 100644 index 000000000..41dde2cd2 --- /dev/null +++ b/.agents/skills/hooks-modules/references/site-surface-module.md @@ -0,0 +1,34 @@ +# siteSurfaceModule + + + +React Query hooks for SiteSurfaceModule data operations + +## Usage + +```typescript +useSiteSurfaceModulesQuery({ selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } } }) +useSiteSurfaceModuleQuery({ id: '', selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } } }) +useCreateSiteSurfaceModuleMutation({ selection: { fields: { id: true } } }) +useUpdateSiteSurfaceModuleMutation({ selection: { fields: { id: true } } }) +useDeleteSiteSurfaceModuleMutation({}) +``` + +## Examples + +### List all siteSurfaceModules + +```typescript +const { data, isLoading } = useSiteSurfaceModulesQuery({ + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }, +}); +``` + +### Create a siteSurfaceModule + +```typescript +const { mutate } = useCreateSiteSurfaceModuleMutation({ + selection: { fields: { id: true } }, +}); +mutate({ apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }); +``` diff --git a/.agents/skills/orm-admin/references/org-is-manager-of.md b/.agents/skills/orm-admin/references/org-is-manager-of.md index e330084cb..95cd69d34 100644 --- a/.agents/skills/orm-admin/references/org-is-manager-of.md +++ b/.agents/skills/orm-admin/references/org-is-manager-of.md @@ -7,7 +7,7 @@ Execute the orgIsManagerOf query ## Usage ```typescript -db.query.orgIsManagerOf({ pEntityId: '', pManagerId: '', pMaxDepth: '', pUserId: '' }).execute() +db.query.orgIsManagerOf({ managerId: '', maxDepth: '', targetEntityId: '', userId: '' }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.query.orgIsManagerOf({ pEntityId: '', pManagerId: '', pMaxDepth: ### Run orgIsManagerOf ```typescript -const result = await db.query.orgIsManagerOf({ pEntityId: '', pManagerId: '', pMaxDepth: '', pUserId: '' }).execute(); +const result = await db.query.orgIsManagerOf({ managerId: '', maxDepth: '', targetEntityId: '', userId: '' }).execute(); ``` diff --git a/.agents/skills/orm-api/SKILL.md b/.agents/skills/orm-api/SKILL.md index c41b21f9d..aca791a4c 100644 --- a/.agents/skills/orm-api/SKILL.md +++ b/.agents/skills/orm-api/SKILL.md @@ -1,13 +1,13 @@ --- name: orm-api -description: ORM client for the api API — provides typed CRUD operations for 47 tables and 9 custom operations +description: ORM client for the api API — provides typed CRUD operations for 49 tables and 9 custom operations --- # orm-api -ORM client for the api API — provides typed CRUD operations for 47 tables and 9 custom operations +ORM client for the api API — provides typed CRUD operations for 49 tables and 9 custom operations ## Usage @@ -51,6 +51,8 @@ See the `references/` directory for detailed per-entity API documentation: - [database-transfer](references/database-transfer.md) - [default-privilege](references/default-privilege.md) - [domain](references/domain.md) +- [domain-event](references/domain-event.md) +- [domain-verification](references/domain-verification.md) - [embedding-chunk](references/embedding-chunk.md) - [enum](references/enum.md) - [field](references/field.md) diff --git a/.agents/skills/orm-api/references/domain-event.md b/.agents/skills/orm-api/references/domain-event.md new file mode 100644 index 000000000..1b1b1b23d --- /dev/null +++ b/.agents/skills/orm-api/references/domain-event.md @@ -0,0 +1,34 @@ +# domainEvent + + + +Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + +## Usage + +```typescript +db.domainEvent.findMany({ select: { id: true } }).execute() +db.domainEvent.findOne({ id: '', select: { id: true } }).execute() +db.domainEvent.create({ data: { actorId: '', domainVerificationId: '', eventType: '', managedDomainId: '', message: '', metadata: '', ownerId: '' }, select: { id: true } }).execute() +db.domainEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute() +db.domainEvent.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all domainEvent records + +```typescript +const items = await db.domainEvent.findMany({ + select: { id: true, actorId: true } +}).execute(); +``` + +### Create a domainEvent + +```typescript +const item = await db.domainEvent.create({ + data: { actorId: '', domainVerificationId: '', eventType: '', managedDomainId: '', message: '', metadata: '', ownerId: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-api/references/domain-verification.md b/.agents/skills/orm-api/references/domain-verification.md new file mode 100644 index 000000000..5a5704491 --- /dev/null +++ b/.agents/skills/orm-api/references/domain-verification.md @@ -0,0 +1,34 @@ +# domainVerification + + + +One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + +## Usage + +```typescript +db.domainVerification.findMany({ select: { id: true } }).execute() +db.domainVerification.findOne({ id: '', select: { id: true } }).execute() +db.domainVerification.create({ data: { attempts: '', error: '', expiresAt: '', lastCheckedAt: '', managedDomainId: '', method: '', ownerId: '', recordName: '', recordType: '', recordValue: '', status: '', verifiedAt: '' }, select: { id: true } }).execute() +db.domainVerification.update({ where: { id: '' }, data: { attempts: '' }, select: { id: true } }).execute() +db.domainVerification.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all domainVerification records + +```typescript +const items = await db.domainVerification.findMany({ + select: { id: true, attempts: true } +}).execute(); +``` + +### Create a domainVerification + +```typescript +const item = await db.domainVerification.create({ + data: { attempts: '', error: '', expiresAt: '', lastCheckedAt: '', managedDomainId: '', method: '', ownerId: '', recordName: '', recordType: '', recordValue: '', status: '', verifiedAt: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-api/references/managed-domain.md b/.agents/skills/orm-api/references/managed-domain.md index e9c44b156..4d320e0b3 100644 --- a/.agents/skills/orm-api/references/managed-domain.md +++ b/.agents/skills/orm-api/references/managed-domain.md @@ -9,8 +9,8 @@ One row per cert-bearing host or wildcard; tracks domain verification and TLS pr ```typescript db.managedDomain.findMany({ select: { id: true } }).execute() db.managedDomain.findOne({ id: '', select: { id: true } }).execute() -db.managedDomain.create({ data: { annotations: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute() -db.managedDomain.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute() +db.managedDomain.create({ data: { allowPublicUsage: '', annotations: '', certStatus: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute() +db.managedDomain.update({ where: { id: '' }, data: { allowPublicUsage: '' }, select: { id: true } }).execute() db.managedDomain.delete({ where: { id: '' } }).execute() ``` @@ -20,7 +20,7 @@ db.managedDomain.delete({ where: { id: '' } }).execute() ```typescript const items = await db.managedDomain.findMany({ - select: { id: true, annotations: true } + select: { id: true, allowPublicUsage: true } }).execute(); ``` @@ -28,7 +28,7 @@ const items = await db.managedDomain.findMany({ ```typescript const item = await db.managedDomain.create({ - data: { annotations: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, + data: { allowPublicUsage: '', annotations: '', certStatus: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute(); ``` diff --git a/.agents/skills/orm-api/references/request-database.md b/.agents/skills/orm-api/references/request-database.md index 2b9835b74..78a6ec95a 100644 --- a/.agents/skills/orm-api/references/request-database.md +++ b/.agents/skills/orm-api/references/request-database.md @@ -4,7 +4,7 @@ Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/.agents/skills/orm-api/references/resolve-http-route.md b/.agents/skills/orm-api/references/resolve-http-route.md index 822783831..90a5ea278 100644 --- a/.agents/skills/orm-api/references/resolve-http-route.md +++ b/.agents/skills/orm-api/references/resolve-http-route.md @@ -7,7 +7,7 @@ Execute the resolveHttpRoute query ## Usage ```typescript -db.query.resolveHttpRoute({ pHost: '', pMethod: '', pPath: '' }).execute() +db.query.resolveHttpRoute({ requestHost: '', requestMethod: '', requestPath: '' }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.query.resolveHttpRoute({ pHost: '', pMethod: '', pPath: '', pMethod: '', pPath: '' }).execute(); +const result = await db.query.resolveHttpRoute({ requestHost: '', requestMethod: '', requestPath: '' }).execute(); ``` diff --git a/.agents/skills/orm-compute/SKILL.md b/.agents/skills/orm-compute/SKILL.md index c8471bc02..409174732 100644 --- a/.agents/skills/orm-compute/SKILL.md +++ b/.agents/skills/orm-compute/SKILL.md @@ -1,13 +1,13 @@ --- name: orm-compute -description: ORM client for the compute API — provides typed CRUD operations for 65 tables and 29 custom operations +description: ORM client for the compute API — provides typed CRUD operations for 67 tables and 29 custom operations --- # orm-compute -ORM client for the compute API — provides typed CRUD operations for 65 tables and 29 custom operations +ORM client for the compute API — provides typed CRUD operations for 67 tables and 29 custom operations ## Usage @@ -15,7 +15,7 @@ ORM client for the compute API — provides typed CRUD operations for 65 tables // Import the ORM client import { db } from './orm'; -// Available models: dbPreset, declaredCapacity, functionApiBinding, functionDefinition, functionDeployment, functionDeploymentEvent, functionExecutionLog, functionGraphCommit, ... +// Available models: dbPreset, functionApiBinding, functionDefinition, functionDeployment, functionDeploymentEvent, functionExecutionLog, functionGraphCommit, functionGraph, ... db..findMany({ select: { id: true } }).execute() db..findOne({ id: '', select: { id: true } }).execute() db..create({ data: { ... }, select: { id: true } }).execute() @@ -38,7 +38,6 @@ const items = await db.dbPreset.findMany({ See the `references/` directory for detailed per-entity API documentation: - [db-preset](references/db-preset.md) -- [declared-capacity](references/declared-capacity.md) - [function-api-binding](references/function-api-binding.md) - [function-definition](references/function-definition.md) - [function-deployment](references/function-deployment.md) @@ -52,6 +51,7 @@ See the `references/` directory for detailed per-entity API documentation: - [function-graph-object](references/function-graph-object.md) - [function-graph-ref](references/function-graph-ref.md) - [function-graph-store](references/function-graph-store.md) +- [function-invocation-attempt](references/function-invocation-attempt.md) - [function-invocation](references/function-invocation.md) - [get-all-tree-nodes-record](references/get-all-tree-nodes-record.md) - [infra-commit](references/infra-commit.md) @@ -62,12 +62,12 @@ See the `references/` directory for detailed per-entity API documentation: - [integration-provider](references/integration-provider.md) - [namespace](references/namespace.md) - [namespace-event](references/namespace-event.md) -- [platform-declared-capacity](references/platform-declared-capacity.md) - [platform-function-api-binding](references/platform-function-api-binding.md) - [platform-function-definition](references/platform-function-definition.md) - [platform-function-deployment](references/platform-function-deployment.md) - [platform-function-deployment-event](references/platform-function-deployment-event.md) - [platform-function-execution-log](references/platform-function-execution-log.md) +- [platform-function-invocation-attempt](references/platform-function-invocation-attempt.md) - [platform-function-invocation](references/platform-function-invocation.md) - [platform-infra-commit](references/platform-infra-commit.md) - [platform-infra-get-all-tree-nodes-record](references/platform-infra-get-all-tree-nodes-record.md) @@ -77,26 +77,28 @@ See the `references/` directory for detailed per-entity API documentation: - [platform-namespace](references/platform-namespace.md) - [platform-namespace-event](references/platform-namespace-event.md) - [platform-resource](references/platform-resource.md) +- [platform-resource-declared-capacity](references/platform-resource-declared-capacity.md) - [platform-resource-definition](references/platform-resource-definition.md) - [platform-resource-event](references/platform-resource-event.md) - [platform-resource-installation](references/platform-resource-installation.md) - [platform-resource-status-check](references/platform-resource-status-check.md) - [platform-resource-usage-log](references/platform-resource-usage-log.md) - [platform-resource-usage-summary](references/platform-resource-usage-summary.md) -- [platform-resource-utilization-daily](references/platform-resource-utilization-daily.md) +- [platform-resource-utilization](references/platform-resource-utilization.md) - [platform-resources-health](references/platform-resources-health.md) - [platform-resources-requirements-state](references/platform-resources-requirements-state.md) - [platform-resources-resolved-requirement](references/platform-resources-resolved-requirement.md) - [platform-webhook-endpoint](references/platform-webhook-endpoint.md) - [platform-webhook-event](references/platform-webhook-event.md) - [resource](references/resource.md) +- [resource-declared-capacity](references/resource-declared-capacity.md) - [resource-definition](references/resource-definition.md) - [resource-event](references/resource-event.md) - [resource-installation](references/resource-installation.md) - [resource-status-check](references/resource-status-check.md) - [resource-usage-log](references/resource-usage-log.md) - [resource-usage-summary](references/resource-usage-summary.md) -- [resource-utilization-daily](references/resource-utilization-daily.md) +- [resource-utilization](references/resource-utilization.md) - [resources-health](references/resources-health.md) - [resources-requirements-state](references/resources-requirements-state.md) - [resources-resolved-requirement](references/resources-resolved-requirement.md) diff --git a/.agents/skills/orm-compute/references/function-invocation-attempt.md b/.agents/skills/orm-compute/references/function-invocation-attempt.md new file mode 100644 index 000000000..8c4031350 --- /dev/null +++ b/.agents/skills/orm-compute/references/function-invocation-attempt.md @@ -0,0 +1,34 @@ +# functionInvocationAttempt + + + +Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + +## Usage + +```typescript +db.functionInvocationAttempt.findMany({ select: { id: true } }).execute() +db.functionInvocationAttempt.findOne({ id: '', select: { id: true } }).execute() +db.functionInvocationAttempt.create({ data: { actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute() +db.functionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute() +db.functionInvocationAttempt.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all functionInvocationAttempt records + +```typescript +const items = await db.functionInvocationAttempt.findMany({ + select: { id: true, actorId: true } +}).execute(); +``` + +### Create a functionInvocationAttempt + +```typescript +const item = await db.functionInvocationAttempt.create({ + data: { actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-compute/references/platform-function-definition.md b/.agents/skills/orm-compute/references/platform-function-definition.md index c505a3db6..25c601cbd 100644 --- a/.agents/skills/orm-compute/references/platform-function-definition.md +++ b/.agents/skills/orm-compute/references/platform-function-definition.md @@ -9,7 +9,7 @@ Function definitions — registered cloud functions with routing, queue, and ret ```typescript db.platformFunctionDefinition.findMany({ select: { id: true } }).execute() db.platformFunctionDefinition.findOne({ id: '', select: { id: true } }).execute() -db.platformFunctionDefinition.create({ data: { accessChannels: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute() +db.platformFunctionDefinition.create({ data: { accessChannels: '', billable: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute() db.platformFunctionDefinition.update({ where: { id: '' }, data: { accessChannels: '' }, select: { id: true } }).execute() db.platformFunctionDefinition.delete({ where: { id: '' } }).execute() ``` @@ -28,7 +28,7 @@ const items = await db.platformFunctionDefinition.findMany({ ```typescript const item = await db.platformFunctionDefinition.create({ - data: { accessChannels: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, + data: { accessChannels: '', billable: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/platform-function-invocation-attempt.md b/.agents/skills/orm-compute/references/platform-function-invocation-attempt.md new file mode 100644 index 000000000..8cc0523be --- /dev/null +++ b/.agents/skills/orm-compute/references/platform-function-invocation-attempt.md @@ -0,0 +1,34 @@ +# platformFunctionInvocationAttempt + + + +Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + +## Usage + +```typescript +db.platformFunctionInvocationAttempt.findMany({ select: { id: true } }).execute() +db.platformFunctionInvocationAttempt.findOne({ id: '', select: { id: true } }).execute() +db.platformFunctionInvocationAttempt.create({ data: { actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute() +db.platformFunctionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute() +db.platformFunctionInvocationAttempt.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all platformFunctionInvocationAttempt records + +```typescript +const items = await db.platformFunctionInvocationAttempt.findMany({ + select: { id: true, actorId: true } +}).execute(); +``` + +### Create a platformFunctionInvocationAttempt + +```typescript +const item = await db.platformFunctionInvocationAttempt.create({ + data: { actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-compute/references/platform-resource-declared-capacity.md b/.agents/skills/orm-compute/references/platform-resource-declared-capacity.md new file mode 100644 index 000000000..0ee48d4d8 --- /dev/null +++ b/.agents/skills/orm-compute/references/platform-resource-declared-capacity.md @@ -0,0 +1,34 @@ +# platformResourceDeclaredCapacity + + + +ORM operations for PlatformResourceDeclaredCapacity records + +## Usage + +```typescript +db.platformResourceDeclaredCapacity.findMany({ select: { id: true } }).execute() +db.platformResourceDeclaredCapacity.findOne({ id: '', select: { id: true } }).execute() +db.platformResourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute() +db.platformResourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute() +db.platformResourceDeclaredCapacity.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all platformResourceDeclaredCapacity records + +```typescript +const items = await db.platformResourceDeclaredCapacity.findMany({ + select: { id: true, cpuLimitMillicores: true } +}).execute(); +``` + +### Create a platformResourceDeclaredCapacity + +```typescript +const item = await db.platformResourceDeclaredCapacity.create({ + data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-compute/references/platform-resource-installations-install.md b/.agents/skills/orm-compute/references/platform-resource-installations-install.md index ee203e6c5..924256dc5 100644 --- a/.agents/skills/orm-compute/references/platform-resource-installations-install.md +++ b/.agents/skills/orm-compute/references/platform-resource-installations-install.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsInstall mutation ## Usage ```typescript -db.mutation.platformResourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute() +db.mutation.platformResourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.platformResourceInstallationsInstall({ input: { pName: '', p ### Run platformResourceInstallationsInstall ```typescript -const result = await db.mutation.platformResourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/platform-resource-installations-rollback.md b/.agents/skills/orm-compute/references/platform-resource-installations-rollback.md index ad8807863..9361451e4 100644 --- a/.agents/skills/orm-compute/references/platform-resource-installations-rollback.md +++ b/.agents/skills/orm-compute/references/platform-resource-installations-rollback.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsRollback mutation ## Usage ```typescript -db.mutation.platformResourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute() +db.mutation.platformResourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.platformResourceInstallationsRollback({ input: { pCommitId: '' ### Run platformResourceInstallationsRollback ```typescript -const result = await db.mutation.platformResourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/platform-resource-installations-uninstall.md b/.agents/skills/orm-compute/references/platform-resource-installations-uninstall.md index 851b8cee8..fb306bc22 100644 --- a/.agents/skills/orm-compute/references/platform-resource-installations-uninstall.md +++ b/.agents/skills/orm-compute/references/platform-resource-installations-uninstall.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsUninstall mutation ## Usage ```typescript -db.mutation.platformResourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute() +db.mutation.platformResourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.platformResourceInstallationsUninstall({ input: { pInstallationId: ' ### Run platformResourceInstallationsUninstall ```typescript -const result = await db.mutation.platformResourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/platform-resource-installations-upgrade.md b/.agents/skills/orm-compute/references/platform-resource-installations-upgrade.md index 4f36f1822..8a70bd738 100644 --- a/.agents/skills/orm-compute/references/platform-resource-installations-upgrade.md +++ b/.agents/skills/orm-compute/references/platform-resource-installations-upgrade.md @@ -7,7 +7,7 @@ Execute the platformResourceInstallationsUpgrade mutation ## Usage ```typescript -db.mutation.platformResourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute() +db.mutation.platformResourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.platformResourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/platform-resource-usage-log.md b/.agents/skills/orm-compute/references/platform-resource-usage-log.md index d6304f53d..883265b42 100644 --- a/.agents/skills/orm-compute/references/platform-resource-usage-log.md +++ b/.agents/skills/orm-compute/references/platform-resource-usage-log.md @@ -2,7 +2,7 @@ -Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) +Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) ## Usage diff --git a/.agents/skills/orm-compute/references/platform-resource-utilization.md b/.agents/skills/orm-compute/references/platform-resource-utilization.md new file mode 100644 index 000000000..8ea11dd25 --- /dev/null +++ b/.agents/skills/orm-compute/references/platform-resource-utilization.md @@ -0,0 +1,34 @@ +# platformResourceUtilization + + + +ORM operations for PlatformResourceUtilization records + +## Usage + +```typescript +db.platformResourceUtilization.findMany({ select: { id: true } }).execute() +db.platformResourceUtilization.findOne({ id: '', select: { id: true } }).execute() +db.platformResourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute() +db.platformResourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute() +db.platformResourceUtilization.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all platformResourceUtilization records + +```typescript +const items = await db.platformResourceUtilization.findMany({ + select: { id: true, avgMemoryBytes: true } +}).execute(); +``` + +### Create a platformResourceUtilization + +```typescript +const item = await db.platformResourceUtilization.create({ + data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-compute/references/resource-declared-capacity.md b/.agents/skills/orm-compute/references/resource-declared-capacity.md new file mode 100644 index 000000000..064823274 --- /dev/null +++ b/.agents/skills/orm-compute/references/resource-declared-capacity.md @@ -0,0 +1,34 @@ +# resourceDeclaredCapacity + + + +ORM operations for ResourceDeclaredCapacity records + +## Usage + +```typescript +db.resourceDeclaredCapacity.findMany({ select: { id: true } }).execute() +db.resourceDeclaredCapacity.findOne({ id: '', select: { id: true } }).execute() +db.resourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute() +db.resourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute() +db.resourceDeclaredCapacity.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all resourceDeclaredCapacity records + +```typescript +const items = await db.resourceDeclaredCapacity.findMany({ + select: { id: true, cpuLimitMillicores: true } +}).execute(); +``` + +### Create a resourceDeclaredCapacity + +```typescript +const item = await db.resourceDeclaredCapacity.create({ + data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-compute/references/resource-installations-install.md b/.agents/skills/orm-compute/references/resource-installations-install.md index 61b1f3362..443cfb007 100644 --- a/.agents/skills/orm-compute/references/resource-installations-install.md +++ b/.agents/skills/orm-compute/references/resource-installations-install.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsInstall mutation ## Usage ```typescript -db.mutation.resourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute() +db.mutation.resourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.resourceInstallationsInstall({ input: { pName: '', pNamespac ### Run resourceInstallationsInstall ```typescript -const result = await db.mutation.resourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.resourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/resource-installations-rollback.md b/.agents/skills/orm-compute/references/resource-installations-rollback.md index 0a2c1feaa..09e1ea0d8 100644 --- a/.agents/skills/orm-compute/references/resource-installations-rollback.md +++ b/.agents/skills/orm-compute/references/resource-installations-rollback.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsRollback mutation ## Usage ```typescript -db.mutation.resourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute() +db.mutation.resourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.resourceInstallationsRollback({ input: { pCommitId: '', pInsta ### Run resourceInstallationsRollback ```typescript -const result = await db.mutation.resourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/resource-installations-uninstall.md b/.agents/skills/orm-compute/references/resource-installations-uninstall.md index a87b1c25b..f7c0f1d86 100644 --- a/.agents/skills/orm-compute/references/resource-installations-uninstall.md +++ b/.agents/skills/orm-compute/references/resource-installations-uninstall.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsUninstall mutation ## Usage ```typescript -db.mutation.resourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute() +db.mutation.resourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.resourceInstallationsUninstall({ input: { pInstallationId: '' ### Run resourceInstallationsUninstall ```typescript -const result = await db.mutation.resourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/resource-installations-upgrade.md b/.agents/skills/orm-compute/references/resource-installations-upgrade.md index a5ad4335e..60c2c17dd 100644 --- a/.agents/skills/orm-compute/references/resource-installations-upgrade.md +++ b/.agents/skills/orm-compute/references/resource-installations-upgrade.md @@ -7,7 +7,7 @@ Execute the resourceInstallationsUpgrade mutation ## Usage ```typescript -db.mutation.resourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute() +db.mutation.resourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute() ``` ## Examples @@ -15,5 +15,5 @@ db.mutation.resourceInstallationsUpgrade({ input: { pInstallationId: '', p ### Run resourceInstallationsUpgrade ```typescript -const result = await db.mutation.resourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` diff --git a/.agents/skills/orm-compute/references/resource-usage-log.md b/.agents/skills/orm-compute/references/resource-usage-log.md index 26a0edd17..9665aca43 100644 --- a/.agents/skills/orm-compute/references/resource-usage-log.md +++ b/.agents/skills/orm-compute/references/resource-usage-log.md @@ -2,7 +2,7 @@ -Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) +Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) ## Usage diff --git a/.agents/skills/orm-compute/references/resource-utilization.md b/.agents/skills/orm-compute/references/resource-utilization.md new file mode 100644 index 000000000..995446292 --- /dev/null +++ b/.agents/skills/orm-compute/references/resource-utilization.md @@ -0,0 +1,34 @@ +# resourceUtilization + + + +ORM operations for ResourceUtilization records + +## Usage + +```typescript +db.resourceUtilization.findMany({ select: { id: true } }).execute() +db.resourceUtilization.findOne({ id: '', select: { id: true } }).execute() +db.resourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute() +db.resourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute() +db.resourceUtilization.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all resourceUtilization records + +```typescript +const items = await db.resourceUtilization.findMany({ + select: { id: true, avgMemoryBytes: true } +}).execute(); +``` + +### Create a resourceUtilization + +```typescript +const item = await db.resourceUtilization.create({ + data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-modules/SKILL.md b/.agents/skills/orm-modules/SKILL.md index 1ed43baa6..d83369e4b 100644 --- a/.agents/skills/orm-modules/SKILL.md +++ b/.agents/skills/orm-modules/SKILL.md @@ -1,13 +1,13 @@ --- name: orm-modules -description: ORM client for the modules API — provides typed CRUD operations for 68 tables and 12 custom operations +description: ORM client for the modules API — provides typed CRUD operations for 74 tables and 12 custom operations --- # orm-modules -ORM client for the modules API — provides typed CRUD operations for 68 tables and 12 custom operations +ORM client for the modules API — provides typed CRUD operations for 74 tables and 12 custom operations ## Usage @@ -15,7 +15,7 @@ ORM client for the modules API — provides typed CRUD operations for 68 tables // Import the ORM client import { db } from './orm'; -// Available models: agentModule, billingModule, billingProviderModule, blueprint, blueprintConstruction, blueprintTemplate, computeLogModule, configSecretsUserModule, ... +// Available models: agentModule, apiSurfaceModule, appModule, billingModule, billingProviderModule, blueprint, blueprintConstruction, blueprintTemplate, ... db..findMany({ select: { id: true } }).execute() db..findOne({ id: '', select: { id: true } }).execute() db..create({ data: { ... }, select: { id: true } }).execute() @@ -38,11 +38,14 @@ const items = await db.agentModule.findMany({ See the `references/` directory for detailed per-entity API documentation: - [agent-module](references/agent-module.md) +- [api-surface-module](references/api-surface-module.md) +- [app-module](references/app-module.md) - [billing-module](references/billing-module.md) - [billing-provider-module](references/billing-provider-module.md) - [blueprint](references/blueprint.md) - [blueprint-construction](references/blueprint-construction.md) - [blueprint-template](references/blueprint-template.md) +- [catalog-module](references/catalog-module.md) - [compute-log-module](references/compute-log-module.md) - [config-secrets-user-module](references/config-secrets-user-module.md) - [connected-accounts-module](references/connected-accounts-module.md) @@ -56,6 +59,7 @@ See the `references/` directory for detailed per-entity API documentation: - [default-ids-module](references/default-ids-module.md) - [denormalized-table-field](references/denormalized-table-field.md) - [devices-module](references/devices-module.md) +- [domain-module](references/domain-module.md) - [emails-module](references/emails-module.md) - [entity-type-provision](references/entity-type-provision.md) - [events-module](references/events-module.md) @@ -91,9 +95,11 @@ See the `references/` directory for detailed per-entity API documentation: - [relation-provision](references/relation-provision.md) - [resource-module](references/resource-module.md) - [rls-module](references/rls-module.md) +- [route-module](references/route-module.md) - [secure-table-provision](references/secure-table-provision.md) - [session-secrets-module](references/session-secrets-module.md) - [sessions-module](references/sessions-module.md) +- [site-surface-module](references/site-surface-module.md) - [storage-log-module](references/storage-log-module.md) - [storage-module](references/storage-module.md) - [transfer-log-module](references/transfer-log-module.md) diff --git a/.agents/skills/orm-modules/references/api-surface-module.md b/.agents/skills/orm-modules/references/api-surface-module.md new file mode 100644 index 000000000..442138311 --- /dev/null +++ b/.agents/skills/orm-modules/references/api-surface-module.md @@ -0,0 +1,34 @@ +# apiSurfaceModule + + + +ORM operations for ApiSurfaceModule records + +## Usage + +```typescript +db.apiSurfaceModule.findMany({ select: { id: true } }).execute() +db.apiSurfaceModule.findOne({ id: '', select: { id: true } }).execute() +db.apiSurfaceModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute() +db.apiSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute() +db.apiSurfaceModule.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all apiSurfaceModule records + +```typescript +const items = await db.apiSurfaceModule.findMany({ + select: { id: true, apiName: true } +}).execute(); +``` + +### Create a apiSurfaceModule + +```typescript +const item = await db.apiSurfaceModule.create({ + data: { apiName: '', apisTableId: '', apisTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-modules/references/app-module.md b/.agents/skills/orm-modules/references/app-module.md new file mode 100644 index 000000000..9fbcc09c1 --- /dev/null +++ b/.agents/skills/orm-modules/references/app-module.md @@ -0,0 +1,34 @@ +# appModule + + + +ORM operations for AppModule records + +## Usage + +```typescript +db.appModule.findMany({ select: { id: true } }).execute() +db.appModule.findOne({ id: '', select: { id: true } }).execute() +db.appModule.create({ data: { apiName: '', appMembersTableId: '', appMembersTableName: '', appsTableId: '', appsTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute() +db.appModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute() +db.appModule.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all appModule records + +```typescript +const items = await db.appModule.findMany({ + select: { id: true, apiName: true } +}).execute(); +``` + +### Create a appModule + +```typescript +const item = await db.appModule.create({ + data: { apiName: '', appMembersTableId: '', appMembersTableName: '', appsTableId: '', appsTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-modules/references/catalog-module.md b/.agents/skills/orm-modules/references/catalog-module.md new file mode 100644 index 000000000..b39528d42 --- /dev/null +++ b/.agents/skills/orm-modules/references/catalog-module.md @@ -0,0 +1,34 @@ +# catalogModule + + + +ORM operations for CatalogModule records + +## Usage + +```typescript +db.catalogModule.findMany({ select: { id: true } }).execute() +db.catalogModule.findOne({ id: '', select: { id: true } }).execute() +db.catalogModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', appsTableId: '', appsTableName: '', databaseId: '', defaultPermissions: '', domainsTableId: '', domainsTableName: '', entityTableId: '', functionsTableId: '', functionsTableName: '', namespacesTableId: '', namespacesTableName: '', policies: '', privateApiName: '', provisions: '', publicSchemaName: '', resourceDefinitionsTableId: '', resourceDefinitionsTableName: '', resourceInstallationsTableId: '', resourceInstallationsTableName: '', resourcesTableId: '', resourcesTableName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute() +db.catalogModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute() +db.catalogModule.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all catalogModule records + +```typescript +const items = await db.catalogModule.findMany({ + select: { id: true, apiName: true } +}).execute(); +``` + +### Create a catalogModule + +```typescript +const item = await db.catalogModule.create({ + data: { apiName: '', apisTableId: '', apisTableName: '', appsTableId: '', appsTableName: '', databaseId: '', defaultPermissions: '', domainsTableId: '', domainsTableName: '', entityTableId: '', functionsTableId: '', functionsTableName: '', namespacesTableId: '', namespacesTableName: '', policies: '', privateApiName: '', provisions: '', publicSchemaName: '', resourceDefinitionsTableId: '', resourceDefinitionsTableName: '', resourceInstallationsTableId: '', resourceInstallationsTableName: '', resourcesTableId: '', resourcesTableName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-modules/references/database-provision-module.md b/.agents/skills/orm-modules/references/database-provision-module.md index a48859f62..17aeae738 100644 --- a/.agents/skills/orm-modules/references/database-provision-module.md +++ b/.agents/skills/orm-modules/references/database-provision-module.md @@ -9,8 +9,8 @@ Tracks database provisioning requests and their status. The BEFORE INSERT trigge ```typescript db.databaseProvisionModule.findMany({ select: { id: true } }).execute() db.databaseProvisionModule.findOne({ id: '', select: { id: true } }).execute() -db.databaseProvisionModule.create({ data: { bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute() -db.databaseProvisionModule.update({ where: { id: '' }, data: { bootstrapError: '' }, select: { id: true } }).execute() +db.databaseProvisionModule.create({ data: { async: '', bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute() +db.databaseProvisionModule.update({ where: { id: '' }, data: { async: '' }, select: { id: true } }).execute() db.databaseProvisionModule.delete({ where: { id: '' } }).execute() ``` @@ -20,7 +20,7 @@ db.databaseProvisionModule.delete({ where: { id: '' } }).execute() ```typescript const items = await db.databaseProvisionModule.findMany({ - select: { id: true, bootstrapError: true } + select: { id: true, async: true } }).execute(); ``` @@ -28,7 +28,7 @@ const items = await db.databaseProvisionModule.findMany({ ```typescript const item = await db.databaseProvisionModule.create({ - data: { bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, + data: { async: '', bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute(); ``` diff --git a/.agents/skills/orm-modules/references/domain-module.md b/.agents/skills/orm-modules/references/domain-module.md new file mode 100644 index 000000000..c452ab24b --- /dev/null +++ b/.agents/skills/orm-modules/references/domain-module.md @@ -0,0 +1,34 @@ +# domainModule + + + +ORM operations for DomainModule records + +## Usage + +```typescript +db.domainModule.findMany({ select: { id: true } }).execute() +db.domainModule.findOne({ id: '', select: { id: true } }).execute() +db.domainModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainEventsTableId: '', domainEventsTableName: '', domainVerificationsTableId: '', domainVerificationsTableName: '', domainsTableId: '', domainsTableName: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute() +db.domainModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute() +db.domainModule.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all domainModule records + +```typescript +const items = await db.domainModule.findMany({ + select: { id: true, apiName: true } +}).execute(); +``` + +### Create a domainModule + +```typescript +const item = await db.domainModule.create({ + data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainEventsTableId: '', domainEventsTableName: '', domainVerificationsTableId: '', domainVerificationsTableName: '', domainsTableId: '', domainsTableName: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-modules/references/function-invocation-module.md b/.agents/skills/orm-modules/references/function-invocation-module.md index 75cf84094..39c9f0925 100644 --- a/.agents/skills/orm-modules/references/function-invocation-module.md +++ b/.agents/skills/orm-modules/references/function-invocation-module.md @@ -9,7 +9,7 @@ ORM operations for FunctionInvocationModule records ```typescript db.functionInvocationModule.findMany({ select: { id: true } }).execute() db.functionInvocationModule.findOne({ id: '', select: { id: true } }).execute() -db.functionInvocationModule.create({ data: { apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute() +db.functionInvocationModule.create({ data: { apiName: '', attemptsTableId: '', attemptsTableName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute() db.functionInvocationModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute() db.functionInvocationModule.delete({ where: { id: '' } }).execute() ``` @@ -28,7 +28,7 @@ const items = await db.functionInvocationModule.findMany({ ```typescript const item = await db.functionInvocationModule.create({ - data: { apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, + data: { apiName: '', attemptsTableId: '', attemptsTableName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); ``` diff --git a/.agents/skills/orm-modules/references/route-module.md b/.agents/skills/orm-modules/references/route-module.md new file mode 100644 index 000000000..7d7fc877a --- /dev/null +++ b/.agents/skills/orm-modules/references/route-module.md @@ -0,0 +1,34 @@ +# routeModule + + + +ORM operations for RouteModule records + +## Usage + +```typescript +db.routeModule.findMany({ select: { id: true } }).execute() +db.routeModule.findOne({ id: '', select: { id: true } }).execute() +db.routeModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainModuleId: '', entityField: '', entityTableId: '', hostnameBindingsTableId: '', hostnameBindingsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', resolverFunctionName: '', routeBindingsTableId: '', routeBindingsTableName: '', routesTableId: '', routesTableName: '', schemaId: '', scope: '' }, select: { id: true } }).execute() +db.routeModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute() +db.routeModule.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all routeModule records + +```typescript +const items = await db.routeModule.findMany({ + select: { id: true, apiName: true } +}).execute(); +``` + +### Create a routeModule + +```typescript +const item = await db.routeModule.create({ + data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainModuleId: '', entityField: '', entityTableId: '', hostnameBindingsTableId: '', hostnameBindingsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', resolverFunctionName: '', routeBindingsTableId: '', routeBindingsTableName: '', routesTableId: '', routesTableName: '', schemaId: '', scope: '' }, + select: { id: true } +}).execute(); +``` diff --git a/.agents/skills/orm-modules/references/site-surface-module.md b/.agents/skills/orm-modules/references/site-surface-module.md new file mode 100644 index 000000000..d346c803d --- /dev/null +++ b/.agents/skills/orm-modules/references/site-surface-module.md @@ -0,0 +1,34 @@ +# siteSurfaceModule + + + +ORM operations for SiteSurfaceModule records + +## Usage + +```typescript +db.siteSurfaceModule.findMany({ select: { id: true } }).execute() +db.siteSurfaceModule.findOne({ id: '', select: { id: true } }).execute() +db.siteSurfaceModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute() +db.siteSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute() +db.siteSurfaceModule.delete({ where: { id: '' } }).execute() +``` + +## Examples + +### List all siteSurfaceModule records + +```typescript +const items = await db.siteSurfaceModule.findMany({ + select: { id: true, apiName: true } +}).execute(); +``` + +### Create a siteSurfaceModule + +```typescript +const item = await db.siteSurfaceModule.create({ + data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, + select: { id: true } +}).execute(); +``` diff --git a/pgpm/export/src/meta-export-tables.json b/pgpm/export/src/meta-export-tables.json index 204babc93..6a50ea40e 100644 --- a/pgpm/export/src/meta-export-tables.json +++ b/pgpm/export/src/meta-export-tables.json @@ -206,6 +206,11 @@ "schema": "metaschema_modules_public", "table": "billing_provider_module" }, + { + "key": "catalog_module", + "schema": "metaschema_modules_public", + "table": "catalog_module" + }, { "key": "compute_log_module", "schema": "metaschema_modules_public", @@ -476,6 +481,16 @@ "schema": "services_public", "table": "webauthn_settings" }, + { + "key": "api_surface_module", + "schema": "metaschema_modules_public", + "table": "api_surface_module" + }, + { + "key": "app_module", + "schema": "metaschema_modules_public", + "table": "app_module" + }, { "key": "db_preset_module", "schema": "metaschema_modules_public", @@ -486,6 +501,11 @@ "schema": "metaschema_modules_public", "table": "denormalized_table_field" }, + { + "key": "domain_module", + "schema": "metaschema_modules_public", + "table": "domain_module" + }, { "key": "function_deployment_module", "schema": "metaschema_modules_public", @@ -506,6 +526,11 @@ "schema": "metaschema_modules_public", "table": "resource_module" }, + { + "key": "site_surface_module", + "schema": "metaschema_modules_public", + "table": "site_surface_module" + }, { "key": "webhook_module", "schema": "metaschema_modules_public", @@ -520,6 +545,11 @@ "key": "http_route_module", "schema": "metaschema_modules_public", "table": "http_route_module" + }, + { + "key": "route_module", + "schema": "metaschema_modules_public", + "table": "route_module" } ], "timestampDefaultColumns": { diff --git a/sdk/constructive-cli/src/admin/cli/README.md b/sdk/constructive-cli/src/admin/cli/README.md index 833da47cb..1d9c5628a 100644 --- a/sdk/constructive-cli/src/admin/cli/README.md +++ b/sdk/constructive-cli/src/admin/cli/README.md @@ -1016,10 +1016,10 @@ orgIsManagerOf | Argument | Type | |----------|------| - | `--pEntityId` | UUID | - | `--pManagerId` | UUID | - | `--pMaxDepth` | Int | - | `--pUserId` | UUID | + | `--managerId` | UUID | + | `--maxDepth` | Int | + | `--targetEntityId` | UUID | + | `--userId` | UUID | ### `org-permissions-get-by-mask` diff --git a/sdk/constructive-cli/src/admin/cli/commands/org-is-manager-of.ts b/sdk/constructive-cli/src/admin/cli/commands/org-is-manager-of.ts index 0ae2ef5e3..d6a68291e 100644 --- a/sdk/constructive-cli/src/admin/cli/commands/org-is-manager-of.ts +++ b/sdk/constructive-cli/src/admin/cli/commands/org-is-manager-of.ts @@ -19,23 +19,23 @@ export default async ( const answers = await prompter.prompt(argv, [ { type: 'text', - name: 'pEntityId', - message: 'pEntityId', + name: 'managerId', + message: 'managerId', }, { type: 'text', - name: 'pManagerId', - message: 'pManagerId', + name: 'maxDepth', + message: 'maxDepth (number)', }, { type: 'text', - name: 'pMaxDepth', - message: 'pMaxDepth (number)', + name: 'targetEntityId', + message: 'targetEntityId', }, { type: 'text', - name: 'pUserId', - message: 'pUserId', + name: 'userId', + message: 'userId', }, ]); const client = getClient(); diff --git a/sdk/constructive-cli/src/admin/orm/README.md b/sdk/constructive-cli/src/admin/orm/README.md index af0e170ff..c5a36159a 100644 --- a/sdk/constructive-cli/src/admin/orm/README.md +++ b/sdk/constructive-cli/src/admin/orm/README.md @@ -1196,13 +1196,13 @@ orgIsManagerOf | Argument | Type | |----------|------| - | `pEntityId` | UUID | - | `pManagerId` | UUID | - | `pMaxDepth` | Int | - | `pUserId` | UUID | + | `managerId` | UUID | + | `maxDepth` | Int | + | `targetEntityId` | UUID | + | `userId` | UUID | ```typescript -const result = await db.query.orgIsManagerOf({ pEntityId: '', pManagerId: '', pMaxDepth: '', pUserId: '' }).execute(); +const result = await db.query.orgIsManagerOf({ managerId: '', maxDepth: '', targetEntityId: '', userId: '' }).execute(); ``` ### `db.query.orgPermissionsGetByMask` diff --git a/sdk/constructive-cli/src/admin/orm/query/index.ts b/sdk/constructive-cli/src/admin/orm/query/index.ts index 79642089b..6d5f48130 100644 --- a/sdk/constructive-cli/src/admin/orm/query/index.ts +++ b/sdk/constructive-cli/src/admin/orm/query/index.ts @@ -30,10 +30,10 @@ export interface AppPermissionsGetPaddedMaskVariables { mask?: string; } export interface OrgIsManagerOfVariables { - pEntityId?: string; - pManagerId?: string; - pMaxDepth?: number; - pUserId?: string; + managerId?: string; + maxDepth?: number; + targetEntityId?: string; + userId?: string; } export interface OrgPermissionsGetByMaskVariables { /** Read all values in the set after (below) this cursor. */ @@ -207,19 +207,19 @@ export function createQueryOperations(client: OrmClient) { args, [ { - name: 'pEntityId', + name: 'managerId', type: 'UUID', }, { - name: 'pManagerId', - type: 'UUID', + name: 'maxDepth', + type: 'Int', }, { - name: 'pMaxDepth', - type: 'Int', + name: 'targetEntityId', + type: 'UUID', }, { - name: 'pUserId', + name: 'userId', type: 'UUID', }, ], diff --git a/sdk/constructive-cli/src/api/README.md b/sdk/constructive-cli/src/api/README.md index c34e5da2a..e1e1fe8dd 100644 --- a/sdk/constructive-cli/src/api/README.md +++ b/sdk/constructive-cli/src/api/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 47 +- **Tables:** 49 - **Custom queries:** 2 - **Custom mutations:** 7 diff --git a/sdk/constructive-cli/src/api/cli/README.md b/sdk/constructive-cli/src/api/cli/README.md index 069bfe042..95482f5b7 100644 --- a/sdk/constructive-cli/src/api/cli/README.md +++ b/sdk/constructive-cli/src/api/cli/README.md @@ -40,6 +40,8 @@ csdk auth set-token | `database-transfer` | databaseTransfer CRUD operations | | `default-privilege` | defaultPrivilege CRUD operations | | `domain` | domain CRUD operations | +| `domain-event` | domainEvent CRUD operations | +| `domain-verification` | domainVerification CRUD operations | | `embedding-chunk` | embeddingChunk CRUD operations | | `enum` | enum CRUD operations | | `field` | field CRUD operations | @@ -85,7 +87,7 @@ and lifecycle settings. | | `reject-database-transfer` | rejectDatabaseTransfer | | `request-database` | Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); @@ -561,6 +563,72 @@ CRUD operations for Domain records. **Required create fields:** `databaseId` **Optional create fields (backend defaults):** `annotations`, `apiId`, `domain`, `labels`, `serviceId`, `siteId`, `subdomain` +### `domain-event` + +CRUD operations for DomainEvent records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all domainEvent records | +| `find-first` | Find first matching domainEvent record | +| `get` | Get a domainEvent by id | +| `create` | Create a new domainEvent | +| `update` | Update an existing domainEvent | +| `delete` | Delete a domainEvent | + +**Fields:** + +| Field | Type | +|-------|------| +| `actorId` | UUID | +| `createdAt` | Datetime | +| `domainVerificationId` | UUID | +| `eventType` | String | +| `id` | UUID | +| `managedDomainId` | UUID | +| `message` | String | +| `metadata` | JSON | +| `ownerId` | UUID | + +**Required create fields:** `eventType`, `managedDomainId`, `ownerId` +**Optional create fields (backend defaults):** `actorId`, `domainVerificationId`, `message`, `metadata` + +### `domain-verification` + +CRUD operations for DomainVerification records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all domainVerification records | +| `find-first` | Find first matching domainVerification record | +| `get` | Get a domainVerification by id | +| `create` | Create a new domainVerification | +| `update` | Update an existing domainVerification | +| `delete` | Delete a domainVerification | + +**Fields:** + +| Field | Type | +|-------|------| +| `attempts` | Int | +| `createdAt` | Datetime | +| `error` | String | +| `expiresAt` | Datetime | +| `id` | UUID | +| `lastCheckedAt` | Datetime | +| `managedDomainId` | UUID | +| `method` | String | +| `ownerId` | UUID | +| `recordName` | String | +| `recordType` | String | +| `recordValue` | String | +| `status` | String | +| `updatedAt` | Datetime | +| `verifiedAt` | Datetime | + +**Required create fields:** `managedDomainId`, `ownerId` +**Optional create fields (backend defaults):** `attempts`, `error`, `expiresAt`, `lastCheckedAt`, `method`, `recordName`, `recordType`, `recordValue`, `status`, `verifiedAt` + ### `embedding-chunk` CRUD operations for EmbeddingChunk records. @@ -859,7 +927,9 @@ CRUD operations for ManagedDomain records. | Field | Type | |-------|------| +| `allowPublicUsage` | Boolean | | `annotations` | JSON | +| `certStatus` | String | | `databaseId` | UUID | | `domain` | Hostname | | `id` | UUID | @@ -870,7 +940,7 @@ CRUD operations for ManagedDomain records. | `verifiedAt` | Datetime | **Required create fields:** `databaseId`, `domain` -**Optional create fields (backend defaults):** `annotations`, `isWildcard`, `tlsReadyAt`, `tlsStatus`, `verificationStatus`, `verifiedAt` +**Optional create fields (backend defaults):** `allowPublicUsage`, `annotations`, `certStatus`, `isWildcard`, `tlsReadyAt`, `tlsStatus`, `verificationStatus`, `verifiedAt` ### `node-type-registry` @@ -1643,9 +1713,9 @@ resolveHttpRoute | Argument | Type | |----------|------| - | `--pHost` | String | - | `--pMethod` | String | - | `--pPath` | String | + | `--requestHost` | String | + | `--requestMethod` | String | + | `--requestPath` | String | ### `accept-database-transfer` @@ -1720,7 +1790,7 @@ rejectDatabaseTransfer Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-cli/src/api/cli/commands.ts b/sdk/constructive-cli/src/api/cli/commands.ts index 86e177d10..24ae1030d 100644 --- a/sdk/constructive-cli/src/api/cli/commands.ts +++ b/sdk/constructive-cli/src/api/cli/commands.ts @@ -20,6 +20,8 @@ import databaseSettingCmd from './commands/database-setting'; import databaseTransferCmd from './commands/database-transfer'; import defaultPrivilegeCmd from './commands/default-privilege'; import domainCmd from './commands/domain'; +import domainEventCmd from './commands/domain-event'; +import domainVerificationCmd from './commands/domain-verification'; import embeddingChunkCmd from './commands/embedding-chunk'; import enumCmd from './commands/enum'; import fieldCmd from './commands/field'; @@ -86,6 +88,8 @@ const createCommandMap: () => Record< 'database-transfer': databaseTransferCmd, 'default-privilege': defaultPrivilegeCmd, domain: domainCmd, + 'domain-event': domainEventCmd, + 'domain-verification': domainVerificationCmd, 'embedding-chunk': embeddingChunkCmd, enum: enumCmd, field: fieldCmd, @@ -130,7 +134,7 @@ const createCommandMap: () => Record< 'set-field-order': setFieldOrderCmd, }); const usage = - "\ncsdk \n\nCommands:\n context Manage API contexts\n auth Manage authentication\n api api CRUD operations\n api-module apiModule CRUD operations\n api-schema apiSchema CRUD operations\n api-setting apiSetting CRUD operations\n app app CRUD operations\n ast-migration astMigration CRUD operations\n check-constraint checkConstraint CRUD operations\n composite-type compositeType CRUD operations\n cors-setting corsSetting CRUD operations\n database database CRUD operations\n database-setting databaseSetting CRUD operations\n database-transfer databaseTransfer CRUD operations\n default-privilege defaultPrivilege CRUD operations\n domain domain CRUD operations\n embedding-chunk embeddingChunk CRUD operations\n enum enum CRUD operations\n field field CRUD operations\n foreign-key-constraint foreignKeyConstraint CRUD operations\n full-text-search fullTextSearch CRUD operations\n function function CRUD operations\n http-route httpRoute CRUD operations\n index index CRUD operations\n managed-domain managedDomain CRUD operations\n node-type-registry nodeTypeRegistry CRUD operations\n partition partition CRUD operations\n policy policy CRUD operations\n primary-key-constraint primaryKeyConstraint CRUD operations\n pubkey-setting pubkeySetting CRUD operations\n rls-setting rlsSetting CRUD operations\n schema schema CRUD operations\n schema-grant schemaGrant CRUD operations\n site site CRUD operations\n site-metadatum siteMetadatum CRUD operations\n site-module siteModule CRUD operations\n site-theme siteTheme CRUD operations\n spatial-relation spatialRelation CRUD operations\n sql-action sqlAction CRUD operations\n table table CRUD operations\n table-grant tableGrant CRUD operations\n trigger trigger CRUD operations\n trigger-function triggerFunction CRUD operations\n unique-constraint uniqueConstraint CRUD operations\n view view CRUD operations\n view-grant viewGrant CRUD operations\n view-rule viewRule CRUD operations\n view-table viewTable CRUD operations\n webauthn-setting webauthnSetting CRUD operations\n apply-registry-defaults applyRegistryDefaults\n resolve-http-route resolveHttpRoute\n accept-database-transfer acceptDatabaseTransfer\n apply-rls applyRls\n cancel-database-transfer cancelDatabaseTransfer\n provision-bucket Provision an S3 bucket for a logical bucket in the database.\nReads the bucket config via RLS, then creates and configures\nthe S3 bucket with the appropriate privacy policies, CORS rules,\nand lifecycle settings.\n reject-database-transfer rejectDatabaseTransfer\n request-database Requests a database and returns a ticket (database_provision_module row) to poll.\n\nPass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at.\n\nExample usage:\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full');\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', modules := '[\"users_module\", \"emails_module\"]'::jsonb);\n set-field-order setFieldOrder\n\n --help, -h Show this help message\n --version, -v Show version\n"; + "\ncsdk \n\nCommands:\n context Manage API contexts\n auth Manage authentication\n api api CRUD operations\n api-module apiModule CRUD operations\n api-schema apiSchema CRUD operations\n api-setting apiSetting CRUD operations\n app app CRUD operations\n ast-migration astMigration CRUD operations\n check-constraint checkConstraint CRUD operations\n composite-type compositeType CRUD operations\n cors-setting corsSetting CRUD operations\n database database CRUD operations\n database-setting databaseSetting CRUD operations\n database-transfer databaseTransfer CRUD operations\n default-privilege defaultPrivilege CRUD operations\n domain domain CRUD operations\n domain-event domainEvent CRUD operations\n domain-verification domainVerification CRUD operations\n embedding-chunk embeddingChunk CRUD operations\n enum enum CRUD operations\n field field CRUD operations\n foreign-key-constraint foreignKeyConstraint CRUD operations\n full-text-search fullTextSearch CRUD operations\n function function CRUD operations\n http-route httpRoute CRUD operations\n index index CRUD operations\n managed-domain managedDomain CRUD operations\n node-type-registry nodeTypeRegistry CRUD operations\n partition partition CRUD operations\n policy policy CRUD operations\n primary-key-constraint primaryKeyConstraint CRUD operations\n pubkey-setting pubkeySetting CRUD operations\n rls-setting rlsSetting CRUD operations\n schema schema CRUD operations\n schema-grant schemaGrant CRUD operations\n site site CRUD operations\n site-metadatum siteMetadatum CRUD operations\n site-module siteModule CRUD operations\n site-theme siteTheme CRUD operations\n spatial-relation spatialRelation CRUD operations\n sql-action sqlAction CRUD operations\n table table CRUD operations\n table-grant tableGrant CRUD operations\n trigger trigger CRUD operations\n trigger-function triggerFunction CRUD operations\n unique-constraint uniqueConstraint CRUD operations\n view view CRUD operations\n view-grant viewGrant CRUD operations\n view-rule viewRule CRUD operations\n view-table viewTable CRUD operations\n webauthn-setting webauthnSetting CRUD operations\n apply-registry-defaults applyRegistryDefaults\n resolve-http-route resolveHttpRoute\n accept-database-transfer acceptDatabaseTransfer\n apply-rls applyRls\n cancel-database-transfer cancelDatabaseTransfer\n provision-bucket Provision an S3 bucket for a logical bucket in the database.\nReads the bucket config via RLS, then creates and configures\nthe S3 bucket with the appropriate privacy policies, CORS rules,\nand lifecycle settings.\n reject-database-transfer rejectDatabaseTransfer\n request-database Requests a database and returns a ticket (database_provision_module row) to poll.\n\nPass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at.\n\nExample usage:\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full');\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', modules := '[\"users_module\", \"emails_module\"]'::jsonb);\n set-field-order setFieldOrder\n\n --help, -h Show this help message\n --version, -v Show version\n"; export const commands = async ( argv: Partial>, prompter: Inquirerer, diff --git a/sdk/constructive-cli/src/api/cli/commands/domain-event.ts b/sdk/constructive-cli/src/api/cli/commands/domain-event.ts new file mode 100644 index 000000000..7a5c8ef0c --- /dev/null +++ b/sdk/constructive-cli/src/api/cli/commands/domain-event.ts @@ -0,0 +1,385 @@ +/** + * CLI commands for DomainEvent + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateDomainEventInput, + DomainEventPatch, + DomainEventSelect, + DomainEventFilter, + DomainEventOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + actorId: 'uuid', + createdAt: 'string', + domainVerificationId: 'uuid', + eventType: 'string', + id: 'uuid', + managedDomainId: 'uuid', + message: 'string', + metadata: 'json', + ownerId: 'uuid', +}; +const usage = + '\ndomain-event \n\nCommands:\n list List domainEvent records\n find-first Find first matching domainEvent record\n get Get a domainEvent by ID\n create Create a new domainEvent\n update Update an existing domainEvent\n delete Delete a domainEvent\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + actorId: true, + createdAt: true, + domainVerificationId: true, + eventType: true, + id: true, + managedDomainId: true, + message: true, + metadata: true, + ownerId: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs & { + select: DomainEventSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.domainEvent.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + actorId: true, + createdAt: true, + domainVerificationId: true, + eventType: true, + id: true, + managedDomainId: true, + message: true, + metadata: true, + ownerId: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs & { + select: DomainEventSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.domainEvent.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.domainEvent + .findOne({ + id: answers.id as string, + select: { + actorId: true, + createdAt: true, + domainVerificationId: true, + eventType: true, + id: true, + managedDomainId: true, + message: true, + metadata: true, + ownerId: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'actorId', + message: 'actorId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainVerificationId', + message: 'domainVerificationId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'eventType', + message: 'eventType', + required: true, + }, + { + type: 'text', + name: 'managedDomainId', + message: 'managedDomainId', + required: true, + }, + { + type: 'text', + name: 'message', + message: 'message', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'metadata', + message: 'metadata', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'ownerId', + message: 'ownerId', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateDomainEventInput['domainEvent']; + const client = getClient(); + const result = await client.domainEvent + .create({ + data: { + actorId: cleanedData.actorId, + domainVerificationId: cleanedData.domainVerificationId, + eventType: cleanedData.eventType, + managedDomainId: cleanedData.managedDomainId, + message: cleanedData.message, + metadata: cleanedData.metadata, + ownerId: cleanedData.ownerId, + }, + select: { + actorId: true, + createdAt: true, + domainVerificationId: true, + eventType: true, + id: true, + managedDomainId: true, + message: true, + metadata: true, + ownerId: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'actorId', + message: 'actorId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainVerificationId', + message: 'domainVerificationId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'eventType', + message: 'eventType', + required: false, + }, + { + type: 'text', + name: 'managedDomainId', + message: 'managedDomainId', + required: false, + }, + { + type: 'text', + name: 'message', + message: 'message', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'metadata', + message: 'metadata', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'ownerId', + message: 'ownerId', + required: false, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as DomainEventPatch; + const client = getClient(); + const result = await client.domainEvent + .update({ + where: { + id: answers.id as string, + }, + data: { + actorId: cleanedData.actorId, + domainVerificationId: cleanedData.domainVerificationId, + eventType: cleanedData.eventType, + managedDomainId: cleanedData.managedDomainId, + message: cleanedData.message, + metadata: cleanedData.metadata, + ownerId: cleanedData.ownerId, + }, + select: { + actorId: true, + createdAt: true, + domainVerificationId: true, + eventType: true, + id: true, + managedDomainId: true, + message: true, + metadata: true, + ownerId: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.domainEvent + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/api/cli/commands/domain-verification.ts b/sdk/constructive-cli/src/api/cli/commands/domain-verification.ts new file mode 100644 index 000000000..4690b4849 --- /dev/null +++ b/sdk/constructive-cli/src/api/cli/commands/domain-verification.ts @@ -0,0 +1,511 @@ +/** + * CLI commands for DomainVerification + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateDomainVerificationInput, + DomainVerificationPatch, + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + attempts: 'int', + createdAt: 'string', + error: 'string', + expiresAt: 'string', + id: 'uuid', + lastCheckedAt: 'string', + managedDomainId: 'uuid', + method: 'string', + ownerId: 'uuid', + recordName: 'string', + recordType: 'string', + recordValue: 'string', + status: 'string', + updatedAt: 'string', + verifiedAt: 'string', +}; +const usage = + '\ndomain-verification \n\nCommands:\n list List domainVerification records\n find-first Find first matching domainVerification record\n get Get a domainVerification by ID\n create Create a new domainVerification\n update Update an existing domainVerification\n delete Delete a domainVerification\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + attempts: true, + createdAt: true, + error: true, + expiresAt: true, + id: true, + lastCheckedAt: true, + managedDomainId: true, + method: true, + ownerId: true, + recordName: true, + recordType: true, + recordValue: true, + status: true, + updatedAt: true, + verifiedAt: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + > & { + select: DomainVerificationSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.domainVerification.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + attempts: true, + createdAt: true, + error: true, + expiresAt: true, + id: true, + lastCheckedAt: true, + managedDomainId: true, + method: true, + ownerId: true, + recordName: true, + recordType: true, + recordValue: true, + status: true, + updatedAt: true, + verifiedAt: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + > & { + select: DomainVerificationSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.domainVerification.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.domainVerification + .findOne({ + id: answers.id as string, + select: { + attempts: true, + createdAt: true, + error: true, + expiresAt: true, + id: true, + lastCheckedAt: true, + managedDomainId: true, + method: true, + ownerId: true, + recordName: true, + recordType: true, + recordValue: true, + status: true, + updatedAt: true, + verifiedAt: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'attempts', + message: 'attempts', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'error', + message: 'error', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'expiresAt', + message: 'expiresAt', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'lastCheckedAt', + message: 'lastCheckedAt', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'managedDomainId', + message: 'managedDomainId', + required: true, + }, + { + type: 'text', + name: 'method', + message: 'method', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'ownerId', + message: 'ownerId', + required: true, + }, + { + type: 'text', + name: 'recordName', + message: 'recordName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'recordType', + message: 'recordType', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'recordValue', + message: 'recordValue', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'status', + message: 'status', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'verifiedAt', + message: 'verifiedAt', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateDomainVerificationInput['domainVerification']; + const client = getClient(); + const result = await client.domainVerification + .create({ + data: { + attempts: cleanedData.attempts, + error: cleanedData.error, + expiresAt: cleanedData.expiresAt, + lastCheckedAt: cleanedData.lastCheckedAt, + managedDomainId: cleanedData.managedDomainId, + method: cleanedData.method, + ownerId: cleanedData.ownerId, + recordName: cleanedData.recordName, + recordType: cleanedData.recordType, + recordValue: cleanedData.recordValue, + status: cleanedData.status, + verifiedAt: cleanedData.verifiedAt, + }, + select: { + attempts: true, + createdAt: true, + error: true, + expiresAt: true, + id: true, + lastCheckedAt: true, + managedDomainId: true, + method: true, + ownerId: true, + recordName: true, + recordType: true, + recordValue: true, + status: true, + updatedAt: true, + verifiedAt: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'attempts', + message: 'attempts', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'error', + message: 'error', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'expiresAt', + message: 'expiresAt', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'lastCheckedAt', + message: 'lastCheckedAt', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'managedDomainId', + message: 'managedDomainId', + required: false, + }, + { + type: 'text', + name: 'method', + message: 'method', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'ownerId', + message: 'ownerId', + required: false, + }, + { + type: 'text', + name: 'recordName', + message: 'recordName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'recordType', + message: 'recordType', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'recordValue', + message: 'recordValue', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'status', + message: 'status', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'verifiedAt', + message: 'verifiedAt', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as DomainVerificationPatch; + const client = getClient(); + const result = await client.domainVerification + .update({ + where: { + id: answers.id as string, + }, + data: { + attempts: cleanedData.attempts, + error: cleanedData.error, + expiresAt: cleanedData.expiresAt, + lastCheckedAt: cleanedData.lastCheckedAt, + managedDomainId: cleanedData.managedDomainId, + method: cleanedData.method, + ownerId: cleanedData.ownerId, + recordName: cleanedData.recordName, + recordType: cleanedData.recordType, + recordValue: cleanedData.recordValue, + status: cleanedData.status, + verifiedAt: cleanedData.verifiedAt, + }, + select: { + attempts: true, + createdAt: true, + error: true, + expiresAt: true, + id: true, + lastCheckedAt: true, + managedDomainId: true, + method: true, + ownerId: true, + recordName: true, + recordType: true, + recordValue: true, + status: true, + updatedAt: true, + verifiedAt: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.domainVerification + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/api/cli/commands/managed-domain.ts b/sdk/constructive-cli/src/api/cli/commands/managed-domain.ts index 80ded9281..df053429f 100644 --- a/sdk/constructive-cli/src/api/cli/commands/managed-domain.ts +++ b/sdk/constructive-cli/src/api/cli/commands/managed-domain.ts @@ -16,7 +16,9 @@ import type { } from '../../orm/input-types'; import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { + allowPublicUsage: 'boolean', annotations: 'json', + certStatus: 'string', databaseId: 'uuid', domain: 'string', id: 'uuid', @@ -77,7 +79,9 @@ async function handleTableSubcommand( async function handleList(argv: Partial>, _prompter: Inquirerer) { try { const defaultSelect = { + allowPublicUsage: true, annotations: true, + certStatus: true, databaseId: true, domain: true, id: true, @@ -106,7 +110,9 @@ async function handleList(argv: Partial>, _prompter: Inq async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { try { const defaultSelect = { + allowPublicUsage: true, annotations: true, + certStatus: true, databaseId: true, domain: true, id: true, @@ -147,7 +153,9 @@ async function handleGet(argv: Partial>, prompter: Inqui .findOne({ id: answers.id as string, select: { + allowPublicUsage: true, annotations: true, + certStatus: true, databaseId: true, domain: true, id: true, @@ -171,6 +179,13 @@ async function handleGet(argv: Partial>, prompter: Inqui async function handleCreate(argv: Partial>, prompter: Inquirerer) { try { const rawAnswers = await prompter.prompt(argv, [ + { + type: 'boolean', + name: 'allowPublicUsage', + message: 'allowPublicUsage', + required: false, + skipPrompt: true, + }, { type: 'json', name: 'annotations', @@ -178,6 +193,13 @@ async function handleCreate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'text', + name: 'certStatus', + message: 'certStatus', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'databaseId', @@ -235,7 +257,9 @@ async function handleCreate(argv: Partial>, prompter: In const result = await client.managedDomain .create({ data: { + allowPublicUsage: cleanedData.allowPublicUsage, annotations: cleanedData.annotations, + certStatus: cleanedData.certStatus, databaseId: cleanedData.databaseId, domain: cleanedData.domain, isWildcard: cleanedData.isWildcard, @@ -245,7 +269,9 @@ async function handleCreate(argv: Partial>, prompter: In verifiedAt: cleanedData.verifiedAt, }, select: { + allowPublicUsage: true, annotations: true, + certStatus: true, databaseId: true, domain: true, id: true, @@ -275,6 +301,13 @@ async function handleUpdate(argv: Partial>, prompter: In message: 'id', required: true, }, + { + type: 'boolean', + name: 'allowPublicUsage', + message: 'allowPublicUsage', + required: false, + skipPrompt: true, + }, { type: 'json', name: 'annotations', @@ -282,6 +315,13 @@ async function handleUpdate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'text', + name: 'certStatus', + message: 'certStatus', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'databaseId', @@ -339,7 +379,9 @@ async function handleUpdate(argv: Partial>, prompter: In id: answers.id as string, }, data: { + allowPublicUsage: cleanedData.allowPublicUsage, annotations: cleanedData.annotations, + certStatus: cleanedData.certStatus, databaseId: cleanedData.databaseId, domain: cleanedData.domain, isWildcard: cleanedData.isWildcard, @@ -349,7 +391,9 @@ async function handleUpdate(argv: Partial>, prompter: In verifiedAt: cleanedData.verifiedAt, }, select: { + allowPublicUsage: true, annotations: true, + certStatus: true, databaseId: true, domain: true, id: true, diff --git a/sdk/constructive-cli/src/api/cli/commands/request-database.ts b/sdk/constructive-cli/src/api/cli/commands/request-database.ts index f81331a02..00e2f1489 100644 --- a/sdk/constructive-cli/src/api/cli/commands/request-database.ts +++ b/sdk/constructive-cli/src/api/cli/commands/request-database.ts @@ -16,7 +16,7 @@ export default async ( try { if (argv.help || argv.h) { console.log( - "request-database - Requests a database and returns a ticket (database_provision_module row) to poll.\n\nPass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at.\n\nExample usage:\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full');\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', modules := '[\"users_module\", \"emails_module\"]'::jsonb);\n\nUsage: request-database [OPTIONS]\n" + "request-database - Requests a database and returns a ticket (database_provision_module row) to poll.\n\nPass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at.\n\nExample usage:\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full');\n SELECT * FROM metaschema_public.request_database('my_app', 'example.com', modules := '[\"users_module\", \"emails_module\"]'::jsonb);\n\nUsage: request-database [OPTIONS]\n" ); process.exit(0); } diff --git a/sdk/constructive-cli/src/api/cli/commands/resolve-http-route.ts b/sdk/constructive-cli/src/api/cli/commands/resolve-http-route.ts index 598a305d2..3ca126584 100644 --- a/sdk/constructive-cli/src/api/cli/commands/resolve-http-route.ts +++ b/sdk/constructive-cli/src/api/cli/commands/resolve-http-route.ts @@ -21,18 +21,18 @@ export default async ( const answers = await prompter.prompt(argv, [ { type: 'text', - name: 'pHost', - message: 'pHost', + name: 'requestHost', + message: 'requestHost', }, { type: 'text', - name: 'pMethod', - message: 'pMethod', + name: 'requestMethod', + message: 'requestMethod', }, { type: 'text', - name: 'pPath', - message: 'pPath', + name: 'requestPath', + message: 'requestPath', }, ]); const client = getClient(); diff --git a/sdk/constructive-cli/src/api/orm/README.md b/sdk/constructive-cli/src/api/orm/README.md index eaebbb607..05e83f6ea 100644 --- a/sdk/constructive-cli/src/api/orm/README.md +++ b/sdk/constructive-cli/src/api/orm/README.md @@ -35,6 +35,8 @@ const db = createClient({ | `databaseTransfer` | findMany, findOne, create, update, delete | | `defaultPrivilege` | findMany, findOne, create, update, delete | | `domain` | findMany, findOne, create, update, delete | +| `domainEvent` | findMany, findOne, create, update, delete | +| `domainVerification` | findMany, findOne, create, update, delete | | `embeddingChunk` | findMany, findOne, create, update, delete | | `enum` | findMany, findOne, create, update, delete | | `field` | findMany, findOne, create, update, delete | @@ -601,6 +603,86 @@ const updated = await db.domain.update({ where: { id: '' }, data: { annota const deleted = await db.domain.delete({ where: { id: '' } }).execute(); ``` +### `db.domainEvent` + +CRUD operations for DomainEvent records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `createdAt` | Datetime | No | +| `domainVerificationId` | UUID | Yes | +| `eventType` | String | Yes | +| `id` | UUID | No | +| `managedDomainId` | UUID | Yes | +| `message` | String | Yes | +| `metadata` | JSON | Yes | +| `ownerId` | UUID | Yes | + +**Operations:** + +```typescript +// List all domainEvent records +const items = await db.domainEvent.findMany({ select: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }).execute(); + +// Get one by id +const item = await db.domainEvent.findOne({ id: '', select: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }).execute(); + +// Create +const created = await db.domainEvent.create({ data: { actorId: '', domainVerificationId: '', eventType: '', managedDomainId: '', message: '', metadata: '', ownerId: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainEvent.delete({ where: { id: '' } }).execute(); +``` + +### `db.domainVerification` + +CRUD operations for DomainVerification records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `attempts` | Int | Yes | +| `createdAt` | Datetime | No | +| `error` | String | Yes | +| `expiresAt` | Datetime | Yes | +| `id` | UUID | No | +| `lastCheckedAt` | Datetime | Yes | +| `managedDomainId` | UUID | Yes | +| `method` | String | Yes | +| `ownerId` | UUID | Yes | +| `recordName` | String | Yes | +| `recordType` | String | Yes | +| `recordValue` | String | Yes | +| `status` | String | Yes | +| `updatedAt` | Datetime | No | +| `verifiedAt` | Datetime | Yes | + +**Operations:** + +```typescript +// List all domainVerification records +const items = await db.domainVerification.findMany({ select: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }).execute(); + +// Get one by id +const item = await db.domainVerification.findOne({ id: '', select: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }).execute(); + +// Create +const created = await db.domainVerification.create({ data: { attempts: '', error: '', expiresAt: '', lastCheckedAt: '', managedDomainId: '', method: '', ownerId: '', recordName: '', recordType: '', recordValue: '', status: '', verifiedAt: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainVerification.update({ where: { id: '' }, data: { attempts: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainVerification.delete({ where: { id: '' } }).execute(); +``` + ### `db.embeddingChunk` CRUD operations for EmbeddingChunk records. @@ -947,7 +1029,9 @@ CRUD operations for ManagedDomain records. | Field | Type | Editable | |-------|------|----------| +| `allowPublicUsage` | Boolean | Yes | | `annotations` | JSON | Yes | +| `certStatus` | String | Yes | | `databaseId` | UUID | Yes | | `domain` | ConstructiveInternalTypeHostname | Yes | | `id` | UUID | No | @@ -961,16 +1045,16 @@ CRUD operations for ManagedDomain records. ```typescript // List all managedDomain records -const items = await db.managedDomain.findMany({ select: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); +const items = await db.managedDomain.findMany({ select: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); // Get one by id -const item = await db.managedDomain.findOne({ id: '', select: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); +const item = await db.managedDomain.findOne({ id: '', select: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); // Create -const created = await db.managedDomain.create({ data: { annotations: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute(); +const created = await db.managedDomain.create({ data: { allowPublicUsage: '', annotations: '', certStatus: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute(); // Update -const updated = await db.managedDomain.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); +const updated = await db.managedDomain.update({ where: { id: '' }, data: { allowPublicUsage: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.managedDomain.delete({ where: { id: '' } }).execute(); @@ -1922,12 +2006,12 @@ resolveHttpRoute | Argument | Type | |----------|------| - | `pHost` | String | - | `pMethod` | String | - | `pPath` | String | + | `requestHost` | String | + | `requestMethod` | String | + | `requestPath` | String | ```typescript -const result = await db.query.resolveHttpRoute({ pHost: '', pMethod: '', pPath: '' }).execute(); +const result = await db.query.resolveHttpRoute({ requestHost: '', requestMethod: '', requestPath: '' }).execute(); ``` ### `db.mutation.acceptDatabaseTransfer` @@ -2012,7 +2096,7 @@ const result = await db.mutation.rejectDatabaseTransfer({ input: { transferId: ' Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-cli/src/api/orm/index.ts b/sdk/constructive-cli/src/api/orm/index.ts index bc2913d21..4d3130d87 100644 --- a/sdk/constructive-cli/src/api/orm/index.ts +++ b/sdk/constructive-cli/src/api/orm/index.ts @@ -19,6 +19,8 @@ import { DatabaseSettingModel } from './models/databaseSetting'; import { DatabaseTransferModel } from './models/databaseTransfer'; import { DefaultPrivilegeModel } from './models/defaultPrivilege'; import { DomainModel } from './models/domain'; +import { DomainEventModel } from './models/domainEvent'; +import { DomainVerificationModel } from './models/domainVerification'; import { EmbeddingChunkModel } from './models/embeddingChunk'; import { EnumModel } from './models/enum'; import { FieldModel } from './models/field'; @@ -101,6 +103,8 @@ export function createClient(config: OrmClientConfig) { databaseTransfer: new DatabaseTransferModel(client), defaultPrivilege: new DefaultPrivilegeModel(client), domain: new DomainModel(client), + domainEvent: new DomainEventModel(client), + domainVerification: new DomainVerificationModel(client), embeddingChunk: new EmbeddingChunkModel(client), enum: new EnumModel(client), field: new FieldModel(client), diff --git a/sdk/constructive-cli/src/api/orm/input-types.ts b/sdk/constructive-cli/src/api/orm/input-types.ts index b4c236a86..1180c3e08 100644 --- a/sdk/constructive-cli/src/api/orm/input-types.ts +++ b/sdk/constructive-cli/src/api/orm/input-types.ts @@ -486,6 +486,60 @@ export interface Domain { /** Subdomain portion of the hostname */ subdomain?: ConstructiveInternalTypeHostname | null; } +/** Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. */ +export interface DomainEvent { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string | null; + /** Event timestamp */ + createdAt?: string | null; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string | null; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType?: string | null; + /** Unique event identifier */ + id: string; + /** The managed_domain this event belongs to */ + managedDomainId?: string | null; + /** Human-readable description of the event */ + message?: string | null; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: Record | null; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId?: string | null; +} +/** One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. */ +export interface DomainVerification { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number | null; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string | null; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string | null; + /** When this challenge expires and must be reissued */ + expiresAt?: string | null; + /** Unique identifier for this verification challenge */ + id: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string | null; + /** The managed_domain this challenge proves ownership of */ + managedDomainId?: string | null; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string | null; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId?: string | null; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string | null; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string | null; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string | null; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string | null; + /** When this row was last updated */ + updatedAt?: string | null; + /** When status last became verified */ + verifiedAt?: string | null; +} export interface EmbeddingChunk { chunkOverlap?: number | null; chunkSize?: number | null; @@ -627,8 +681,12 @@ export interface Index { } /** One row per cert-bearing host or wildcard; tracks domain verification and TLS provisioning independently of services_public.domains. Reconcilers match a route's root domain to a row here by string (no FK/coupling in v1) */ export interface ManagedDomain { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean | null; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: Record | null; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string | null; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId?: string | null; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -639,9 +697,9 @@ export interface ManagedDomain { isWildcard?: boolean | null; /** When tls_status last became active */ tlsReadyAt?: string | null; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string | null; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string | null; /** When verification_status last became verified */ verifiedAt?: string | null; @@ -1128,6 +1186,14 @@ export interface DomainRelations { site?: Site | null; httpRoutes?: ConnectionResult; } +export interface DomainEventRelations { + domainVerification?: DomainVerification | null; + managedDomain?: ManagedDomain | null; +} +export interface DomainVerificationRelations { + managedDomain?: ManagedDomain | null; + domainEvents?: ConnectionResult; +} export interface EmbeddingChunkRelations { chunksTable?: Table | null; database?: Database | null; @@ -1167,6 +1233,8 @@ export interface IndexRelations { } export interface ManagedDomainRelations { database?: Database | null; + domainEvents?: ConnectionResult; + domainVerifications?: ConnectionResult; } export interface NodeTypeRegistryRelations {} export interface PartitionRelations { @@ -1329,6 +1397,8 @@ export type DatabaseSettingWithRelations = DatabaseSetting & DatabaseSettingRela export type DatabaseTransferWithRelations = DatabaseTransfer & DatabaseTransferRelations; export type DefaultPrivilegeWithRelations = DefaultPrivilege & DefaultPrivilegeRelations; export type DomainWithRelations = Domain & DomainRelations; +export type DomainEventWithRelations = DomainEvent & DomainEventRelations; +export type DomainVerificationWithRelations = DomainVerification & DomainVerificationRelations; export type EmbeddingChunkWithRelations = EmbeddingChunk & EmbeddingChunkRelations; export type EnumWithRelations = Enum & EnumRelations; export type FieldWithRelations = Field & FieldRelations; @@ -1873,6 +1943,49 @@ export type DomainSelect = { orderBy?: HttpRouteOrderBy[]; }; }; +export type DomainEventSelect = { + actorId?: boolean; + createdAt?: boolean; + domainVerificationId?: boolean; + eventType?: boolean; + id?: boolean; + managedDomainId?: boolean; + message?: boolean; + metadata?: boolean; + ownerId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + managedDomain?: { + select: ManagedDomainSelect; + }; +}; +export type DomainVerificationSelect = { + attempts?: boolean; + createdAt?: boolean; + error?: boolean; + expiresAt?: boolean; + id?: boolean; + lastCheckedAt?: boolean; + managedDomainId?: boolean; + method?: boolean; + ownerId?: boolean; + recordName?: boolean; + recordType?: boolean; + recordValue?: boolean; + status?: boolean; + updatedAt?: boolean; + verifiedAt?: boolean; + managedDomain?: { + select: ManagedDomainSelect; + }; + domainEvents?: { + select: DomainEventSelect; + first?: number; + filter?: DomainEventFilter; + orderBy?: DomainEventOrderBy[]; + }; +}; export type EmbeddingChunkSelect = { chunkOverlap?: boolean; chunkSize?: boolean; @@ -2073,7 +2186,9 @@ export type IndexSelect = { }; }; export type ManagedDomainSelect = { + allowPublicUsage?: boolean; annotations?: boolean; + certStatus?: boolean; databaseId?: boolean; domain?: boolean; id?: boolean; @@ -2085,6 +2200,18 @@ export type ManagedDomainSelect = { database?: { select: DatabaseSelect; }; + domainEvents?: { + select: DomainEventSelect; + first?: number; + filter?: DomainEventFilter; + orderBy?: DomainEventOrderBy[]; + }; + domainVerifications?: { + select: DomainVerificationSelect; + first?: number; + filter?: DomainVerificationFilter; + orderBy?: DomainVerificationOrderBy[]; + }; }; export type NodeTypeRegistrySelect = { category?: boolean; @@ -3405,6 +3532,82 @@ export interface DomainFilter { /** Filter by the object’s `subdomain` field. */ subdomain?: ConstructiveInternalTypeHostnameFilter; } +export interface DomainEventFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: DomainEventFilter[]; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainVerification` relation. */ + domainVerification?: DomainVerificationFilter; + /** A related `domainVerification` exists. */ + domainVerificationExists?: boolean; + /** Filter by the object’s `domainVerificationId` field. */ + domainVerificationId?: UUIDFilter; + /** Filter by the object’s `eventType` field. */ + eventType?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `message` field. */ + message?: StringFilter; + /** Filter by the object’s `metadata` field. */ + metadata?: JSONFilter; + /** Negates the expression. */ + not?: DomainEventFilter; + /** Checks for any expressions in this list. */ + or?: DomainEventFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; +} +export interface DomainVerificationFilter { + /** Checks for all expressions in this list. */ + and?: DomainVerificationFilter[]; + /** Filter by the object’s `attempts` field. */ + attempts?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: DomainVerificationToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `expiresAt` field. */ + expiresAt?: DatetimeFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `lastCheckedAt` field. */ + lastCheckedAt?: DatetimeFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `method` field. */ + method?: StringFilter; + /** Negates the expression. */ + not?: DomainVerificationFilter; + /** Checks for any expressions in this list. */ + or?: DomainVerificationFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; + /** Filter by the object’s `recordName` field. */ + recordName?: StringFilter; + /** Filter by the object’s `recordType` field. */ + recordType?: StringFilter; + /** Filter by the object’s `recordValue` field. */ + recordValue?: StringFilter; + /** Filter by the object’s `status` field. */ + status?: StringFilter; + /** Filter by the object’s `updatedAt` field. */ + updatedAt?: DatetimeFilter; + /** Filter by the object’s `verifiedAt` field. */ + verifiedAt?: DatetimeFilter; +} export interface EmbeddingChunkFilter { /** Checks for all expressions in this list. */ and?: EmbeddingChunkFilter[]; @@ -3750,16 +3953,28 @@ export interface IndexFilter { whereClause?: JSONFilter; } export interface ManagedDomainFilter { + /** Filter by the object’s `allowPublicUsage` field. */ + allowPublicUsage?: BooleanFilter; /** Checks for all expressions in this list. */ and?: ManagedDomainFilter[]; /** Filter by the object’s `annotations` field. */ annotations?: JSONFilter; + /** Filter by the object’s `certStatus` field. */ + certStatus?: StringFilter; /** Filter by the object’s `database` relation. */ database?: DatabaseFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `domain` field. */ domain?: ConstructiveInternalTypeHostnameFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: ManagedDomainToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `domainVerifications` relation. */ + domainVerifications?: ManagedDomainToManyDomainVerificationFilter; + /** `domainVerifications` exist. */ + domainVerificationsExist?: boolean; /** Filter by the object’s `id` field. */ id?: UUIDFilter; /** Filter by the object’s `isWildcard` field. */ @@ -5104,6 +5319,62 @@ export type DomainOrderBy = | 'SITE_ID_DESC' | 'SUBDOMAIN_ASC' | 'SUBDOMAIN_DESC'; +export type DomainEventOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DOMAIN_VERIFICATION_ID_ASC' + | 'DOMAIN_VERIFICATION_ID_DESC' + | 'EVENT_TYPE_ASC' + | 'EVENT_TYPE_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'MESSAGE_ASC' + | 'MESSAGE_DESC' + | 'METADATA_ASC' + | 'METADATA_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC'; +export type DomainVerificationOrderBy = + | 'ATTEMPTS_ASC' + | 'ATTEMPTS_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'EXPIRES_AT_ASC' + | 'EXPIRES_AT_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'LAST_CHECKED_AT_ASC' + | 'LAST_CHECKED_AT_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'METHOD_ASC' + | 'METHOD_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'RECORD_NAME_ASC' + | 'RECORD_NAME_DESC' + | 'RECORD_TYPE_ASC' + | 'RECORD_TYPE_DESC' + | 'RECORD_VALUE_ASC' + | 'RECORD_VALUE_DESC' + | 'STATUS_ASC' + | 'STATUS_DESC' + | 'UPDATED_AT_ASC' + | 'UPDATED_AT_DESC' + | 'VERIFIED_AT_ASC' + | 'VERIFIED_AT_DESC'; export type EmbeddingChunkOrderBy = | 'CHUNKING_TASK_NAME_ASC' | 'CHUNKING_TASK_NAME_DESC' @@ -5365,8 +5636,12 @@ export type IndexOrderBy = | 'WHERE_CLAUSE_ASC' | 'WHERE_CLAUSE_DESC'; export type ManagedDomainOrderBy = + | 'ALLOW_PUBLIC_USAGE_ASC' + | 'ALLOW_PUBLIC_USAGE_DESC' | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' + | 'CERT_STATUS_ASC' + | 'CERT_STATUS_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DOMAIN_ASC' @@ -6434,6 +6709,76 @@ export interface DeleteDomainInput { clientMutationId?: string; id: string; } +export interface CreateDomainEventInput { + clientMutationId?: string; + domainEvent: { + actorId?: string; + domainVerificationId?: string; + eventType: string; + managedDomainId: string; + message?: string; + metadata?: Record; + ownerId: string; + }; +} +export interface DomainEventPatch { + actorId?: string | null; + domainVerificationId?: string | null; + eventType?: string | null; + managedDomainId?: string | null; + message?: string | null; + metadata?: Record | null; + ownerId?: string | null; +} +export interface UpdateDomainEventInput { + clientMutationId?: string; + id: string; + domainEventPatch: DomainEventPatch; +} +export interface DeleteDomainEventInput { + clientMutationId?: string; + id: string; +} +export interface CreateDomainVerificationInput { + clientMutationId?: string; + domainVerification: { + attempts?: number; + error?: string; + expiresAt?: string; + lastCheckedAt?: string; + managedDomainId: string; + method?: string; + ownerId: string; + recordName?: string; + recordType?: string; + recordValue?: string; + status?: string; + verifiedAt?: string; + }; +} +export interface DomainVerificationPatch { + attempts?: number | null; + error?: string | null; + expiresAt?: string | null; + lastCheckedAt?: string | null; + managedDomainId?: string | null; + method?: string | null; + ownerId?: string | null; + recordName?: string | null; + recordType?: string | null; + recordValue?: string | null; + status?: string | null; + verifiedAt?: string | null; +} +export interface UpdateDomainVerificationInput { + clientMutationId?: string; + id: string; + domainVerificationPatch: DomainVerificationPatch; +} +export interface DeleteDomainVerificationInput { + clientMutationId?: string; + id: string; +} export interface CreateEmbeddingChunkInput { clientMutationId?: string; embeddingChunk: { @@ -6753,7 +7098,9 @@ export interface DeleteIndexInput { export interface CreateManagedDomainInput { clientMutationId?: string; managedDomain: { + allowPublicUsage?: boolean; annotations?: Record; + certStatus?: string; databaseId: string; domain: ConstructiveInternalTypeHostname; isWildcard?: boolean; @@ -6764,7 +7111,9 @@ export interface CreateManagedDomainInput { }; } export interface ManagedDomainPatch { + allowPublicUsage?: boolean | null; annotations?: Record | null; + certStatus?: string | null; databaseId?: string | null; domain?: ConstructiveInternalTypeHostname | null; isWildcard?: boolean | null; @@ -7624,10 +7973,17 @@ export const connectionFieldsMap = { Domain: { httpRoutes: 'HttpRoute', }, + DomainVerification: { + domainEvents: 'DomainEvent', + }, Field: { spatialRelations: 'SpatialRelation', spatialRelationsByRefFieldId: 'SpatialRelation', }, + ManagedDomain: { + domainEvents: 'DomainEvent', + domainVerifications: 'DomainVerification', + }, Schema: { apiSchemas: 'ApiSchema', compositeTypes: 'CompositeType', @@ -8314,6 +8670,15 @@ export interface DomainToManyHttpRouteFilter { /** Filters to entities where at least one related entity matches. */ some?: HttpRouteFilter; } +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} /** A filter to be used against many `SpatialRelation` object types. All fields are combined with a logical ‘and.’ */ export interface FieldToManySpatialRelationFilter { /** Filters to entities where every related entity matches. */ @@ -8323,6 +8688,24 @@ export interface FieldToManySpatialRelationFilter { /** Filters to entities where at least one related entity matches. */ some?: SpatialRelationFilter; } +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} +/** A filter to be used against many `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainVerificationFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainVerificationFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainVerificationFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainVerificationFilter; +} /** A filter to be used against ApiExposureLevel fields. All fields are combined with a logical ‘and.’ */ export interface ApiExposureLevelFilter { /** Not equal to the specified value, treating null like an ordinary value. */ @@ -8923,6 +9306,60 @@ export interface DomainInput { /** Subdomain portion of the hostname */ subdomain?: ConstructiveInternalTypeHostname; } +/** An input for mutations affecting `DomainEvent` */ +export interface DomainEventInput { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string; + /** Event timestamp */ + createdAt?: string; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType: string; + /** Unique event identifier */ + id?: string; + /** The managed_domain this event belongs to */ + managedDomainId: string; + /** Human-readable description of the event */ + message?: string; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: Record; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId: string; +} +/** An input for mutations affecting `DomainVerification` */ +export interface DomainVerificationInput { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string; + /** When this challenge expires and must be reissued */ + expiresAt?: string; + /** Unique identifier for this verification challenge */ + id?: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string; + /** The managed_domain this challenge proves ownership of */ + managedDomainId: string; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId: string; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string; + /** When this row was last updated */ + updatedAt?: string; + /** When status last became verified */ + verifiedAt?: string; +} /** An input for mutations affecting `EmbeddingChunk` */ export interface EmbeddingChunkInput { chunkOverlap?: number; @@ -9071,8 +9508,12 @@ export interface IndexInput { } /** An input for mutations affecting `ManagedDomain` */ export interface ManagedDomainInput { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: Record; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId: string; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -9083,9 +9524,9 @@ export interface ManagedDomainInput { isWildcard?: boolean; /** When tls_status last became active */ tlsReadyAt?: string; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string; /** When verification_status last became verified */ verifiedAt?: string; @@ -10146,16 +10587,28 @@ export interface IndexFilter { } /** A filter to be used against `ManagedDomain` object types. All fields are combined with a logical ‘and.’ */ export interface ManagedDomainFilter { + /** Filter by the object’s `allowPublicUsage` field. */ + allowPublicUsage?: BooleanFilter; /** Checks for all expressions in this list. */ and?: ManagedDomainFilter[]; /** Filter by the object’s `annotations` field. */ annotations?: JSONFilter; + /** Filter by the object’s `certStatus` field. */ + certStatus?: StringFilter; /** Filter by the object’s `database` relation. */ database?: DatabaseFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `domain` field. */ domain?: ConstructiveInternalTypeHostnameFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: ManagedDomainToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `domainVerifications` relation. */ + domainVerifications?: ManagedDomainToManyDomainVerificationFilter; + /** `domainVerifications` exist. */ + domainVerificationsExist?: boolean; /** Filter by the object’s `id` field. */ id?: UUIDFilter; /** Filter by the object’s `isWildcard` field. */ @@ -10979,6 +11432,84 @@ export interface HttpRouteFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +/** A filter to be used against `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainEventFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: DomainEventFilter[]; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainVerification` relation. */ + domainVerification?: DomainVerificationFilter; + /** A related `domainVerification` exists. */ + domainVerificationExists?: boolean; + /** Filter by the object’s `domainVerificationId` field. */ + domainVerificationId?: UUIDFilter; + /** Filter by the object’s `eventType` field. */ + eventType?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `message` field. */ + message?: StringFilter; + /** Filter by the object’s `metadata` field. */ + metadata?: JSONFilter; + /** Negates the expression. */ + not?: DomainEventFilter; + /** Checks for any expressions in this list. */ + or?: DomainEventFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; +} +/** A filter to be used against `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationFilter { + /** Checks for all expressions in this list. */ + and?: DomainVerificationFilter[]; + /** Filter by the object’s `attempts` field. */ + attempts?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: DomainVerificationToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `expiresAt` field. */ + expiresAt?: DatetimeFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `lastCheckedAt` field. */ + lastCheckedAt?: DatetimeFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `method` field. */ + method?: StringFilter; + /** Negates the expression. */ + not?: DomainVerificationFilter; + /** Checks for any expressions in this list. */ + or?: DomainVerificationFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; + /** Filter by the object’s `recordName` field. */ + recordName?: StringFilter; + /** Filter by the object’s `recordType` field. */ + recordType?: StringFilter; + /** Filter by the object’s `recordValue` field. */ + recordValue?: StringFilter; + /** Filter by the object’s `status` field. */ + status?: StringFilter; + /** Filter by the object’s `updatedAt` field. */ + updatedAt?: DatetimeFilter; + /** Filter by the object’s `verifiedAt` field. */ + verifiedAt?: DatetimeFilter; +} /** A filter to be used against UUID fields. All fields are combined with a logical ‘and.’ */ export interface UUIDFilter { /** Not equal to the specified value, treating null like an ordinary value. */ @@ -12426,6 +12957,96 @@ export type DeleteDomainPayloadSelect = { select: DomainEdgeSelect; }; }; +export interface CreateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was created by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type CreateDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface UpdateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was updated by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type UpdateDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface DeleteDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was deleted by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type DeleteDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface CreateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was created by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type CreateDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; +export interface UpdateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was updated by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type UpdateDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; +export interface DeleteDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was deleted by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type DeleteDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; export interface CreateEmbeddingChunkPayload { clientMutationId?: string | null; /** The `EmbeddingChunk` that was created by this mutation. */ @@ -13868,6 +14489,8 @@ export type DeleteWebauthnSettingPayloadSelect = { }; /** Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. */ export interface DatabaseProvisionModule { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string | null; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -13901,6 +14524,7 @@ export interface DatabaseProvisionModule { updatedAt: string; } export type DatabaseProvisionModuleSelect = { + async?: boolean; bootstrapError?: boolean; bootstrapStatus?: boolean; bootstrapUser?: boolean; @@ -14076,6 +14700,30 @@ export type DomainEdgeSelect = { select: DomainSelect; }; }; +/** A `DomainEvent` edge in the connection. */ +export interface DomainEventEdge { + cursor?: string | null; + /** The `DomainEvent` at the end of the edge. */ + node?: DomainEvent | null; +} +export type DomainEventEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainEventSelect; + }; +}; +/** A `DomainVerification` edge in the connection. */ +export interface DomainVerificationEdge { + cursor?: string | null; + /** The `DomainVerification` at the end of the edge. */ + node?: DomainVerification | null; +} +export type DomainVerificationEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainVerificationSelect; + }; +}; /** A `EmbeddingChunk` edge in the connection. */ export interface EmbeddingChunkEdge { cursor?: string | null; diff --git a/sdk/constructive-cli/src/api/orm/models/domainEvent.ts b/sdk/constructive-cli/src/api/orm/models/domainEvent.ts new file mode 100644 index 000000000..7177a7270 --- /dev/null +++ b/sdk/constructive-cli/src/api/orm/models/domainEvent.ts @@ -0,0 +1,245 @@ +/** + * DomainEvent model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainEvent, + DomainEventWithRelations, + DomainEventSelect, + DomainEventFilter, + DomainEventOrderBy, + CreateDomainEventInput, + UpdateDomainEventInput, + DomainEventPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainEventModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvents: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvents', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvent: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvent', + document, + variables, + transform: (data: { + domainEvents?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainEvent: data.domainEvents?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvent: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvent', + document, + variables, + transform: (data: { + domainEvents?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainEvent: data.domainEvents?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainEvent', + 'createDomainEvent', + 'domainEvent', + args.select, + args.data, + 'CreateDomainEventInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'createDomainEvent', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainEventPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainEvent', + 'updateDomainEvent', + 'domainEvent', + args.select, + args.where.id, + args.data, + 'UpdateDomainEventInput', + 'id', + 'domainEventPatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'updateDomainEvent', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainEvent', + 'deleteDomainEvent', + 'domainEvent', + { + id: args.where.id, + }, + 'DeleteDomainEventInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'deleteDomainEvent', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/api/orm/models/domainVerification.ts b/sdk/constructive-cli/src/api/orm/models/domainVerification.ts new file mode 100644 index 000000000..b004e0b4d --- /dev/null +++ b/sdk/constructive-cli/src/api/orm/models/domainVerification.ts @@ -0,0 +1,245 @@ +/** + * DomainVerification model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainVerification, + DomainVerificationWithRelations, + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy, + CreateDomainVerificationInput, + UpdateDomainVerificationInput, + DomainVerificationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainVerificationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerifications: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerifications', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerification: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerification', + document, + variables, + transform: (data: { + domainVerifications?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainVerification: data.domainVerifications?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerification: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerification', + document, + variables, + transform: (data: { + domainVerifications?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainVerification: data.domainVerifications?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainVerification', + 'createDomainVerification', + 'domainVerification', + args.select, + args.data, + 'CreateDomainVerificationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'createDomainVerification', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainVerificationPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainVerification', + 'updateDomainVerification', + 'domainVerification', + args.select, + args.where.id, + args.data, + 'UpdateDomainVerificationInput', + 'id', + 'domainVerificationPatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'updateDomainVerification', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainVerification', + 'deleteDomainVerification', + 'domainVerification', + { + id: args.where.id, + }, + 'DeleteDomainVerificationInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'deleteDomainVerification', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/api/orm/models/index.ts b/sdk/constructive-cli/src/api/orm/models/index.ts index 26dab64b2..a21fca3c5 100644 --- a/sdk/constructive-cli/src/api/orm/models/index.ts +++ b/sdk/constructive-cli/src/api/orm/models/index.ts @@ -17,6 +17,8 @@ export { DatabaseSettingModel } from './databaseSetting'; export { DatabaseTransferModel } from './databaseTransfer'; export { DefaultPrivilegeModel } from './defaultPrivilege'; export { DomainModel } from './domain'; +export { DomainEventModel } from './domainEvent'; +export { DomainVerificationModel } from './domainVerification'; export { EmbeddingChunkModel } from './embeddingChunk'; export { EnumModel } from './enum'; export { FieldModel } from './field'; diff --git a/sdk/constructive-cli/src/api/orm/mutation/index.ts b/sdk/constructive-cli/src/api/orm/mutation/index.ts index 242a60b79..0192a395b 100644 --- a/sdk/constructive-cli/src/api/orm/mutation/index.ts +++ b/sdk/constructive-cli/src/api/orm/mutation/index.ts @@ -56,7 +56,7 @@ export interface RejectDatabaseTransferVariables { * Variables for requestDatabase * Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-cli/src/api/orm/query/index.ts b/sdk/constructive-cli/src/api/orm/query/index.ts index 0b7b1b1f0..1e86e6234 100644 --- a/sdk/constructive-cli/src/api/orm/query/index.ts +++ b/sdk/constructive-cli/src/api/orm/query/index.ts @@ -13,9 +13,9 @@ export interface ApplyRegistryDefaultsVariables { nodeType?: string; } export interface ResolveHttpRouteVariables { - pHost?: string; - pMethod?: string; - pPath?: string; + requestHost?: string; + requestMethod?: string; + requestPath?: string; } export function createQueryOperations(client: OrmClient) { return { @@ -73,15 +73,15 @@ export function createQueryOperations(client: OrmClient) { args, [ { - name: 'pHost', + name: 'requestHost', type: 'String', }, { - name: 'pMethod', + name: 'requestMethod', type: 'String', }, { - name: 'pPath', + name: 'requestPath', type: 'String', }, ], diff --git a/sdk/constructive-cli/src/compute/README.md b/sdk/constructive-cli/src/compute/README.md index 429076857..1506e6bfc 100644 --- a/sdk/constructive-cli/src/compute/README.md +++ b/sdk/constructive-cli/src/compute/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 65 +- **Tables:** 67 - **Custom queries:** 1 - **Custom mutations:** 28 diff --git a/sdk/constructive-cli/src/compute/cli/README.md b/sdk/constructive-cli/src/compute/cli/README.md index 41e4afcd7..774ad1200 100644 --- a/sdk/constructive-cli/src/compute/cli/README.md +++ b/sdk/constructive-cli/src/compute/cli/README.md @@ -27,7 +27,6 @@ csdk auth set-token | `auth` | Manage authentication tokens | | `config` | Manage config key-value store (per-context) | | `db-preset` | dbPreset CRUD operations | -| `declared-capacity` | declaredCapacity CRUD operations | | `function-api-binding` | functionApiBinding CRUD operations | | `function-definition` | functionDefinition CRUD operations | | `function-deployment` | functionDeployment CRUD operations | @@ -41,6 +40,7 @@ csdk auth set-token | `function-graph-object` | functionGraphObject CRUD operations | | `function-graph-ref` | functionGraphRef CRUD operations | | `function-graph-store` | functionGraphStore CRUD operations | +| `function-invocation-attempt` | functionInvocationAttempt CRUD operations | | `function-invocation` | functionInvocation CRUD operations | | `get-all-tree-nodes-record` | getAllTreeNodesRecord CRUD operations | | `infra-commit` | infraCommit CRUD operations | @@ -51,12 +51,12 @@ csdk auth set-token | `integration-provider` | integrationProvider CRUD operations | | `namespace` | namespace CRUD operations | | `namespace-event` | namespaceEvent CRUD operations | -| `platform-declared-capacity` | platformDeclaredCapacity CRUD operations | | `platform-function-api-binding` | platformFunctionApiBinding CRUD operations | | `platform-function-definition` | platformFunctionDefinition CRUD operations | | `platform-function-deployment` | platformFunctionDeployment CRUD operations | | `platform-function-deployment-event` | platformFunctionDeploymentEvent CRUD operations | | `platform-function-execution-log` | platformFunctionExecutionLog CRUD operations | +| `platform-function-invocation-attempt` | platformFunctionInvocationAttempt CRUD operations | | `platform-function-invocation` | platformFunctionInvocation CRUD operations | | `platform-infra-commit` | platformInfraCommit CRUD operations | | `platform-infra-get-all-tree-nodes-record` | platformInfraGetAllTreeNodesRecord CRUD operations | @@ -66,26 +66,28 @@ csdk auth set-token | `platform-namespace` | platformNamespace CRUD operations | | `platform-namespace-event` | platformNamespaceEvent CRUD operations | | `platform-resource` | platformResource CRUD operations | +| `platform-resource-declared-capacity` | platformResourceDeclaredCapacity CRUD operations | | `platform-resource-definition` | platformResourceDefinition CRUD operations | | `platform-resource-event` | platformResourceEvent CRUD operations | | `platform-resource-installation` | platformResourceInstallation CRUD operations | | `platform-resource-status-check` | platformResourceStatusCheck CRUD operations | | `platform-resource-usage-log` | platformResourceUsageLog CRUD operations | | `platform-resource-usage-summary` | platformResourceUsageSummary CRUD operations | -| `platform-resource-utilization-daily` | platformResourceUtilizationDaily CRUD operations | +| `platform-resource-utilization` | platformResourceUtilization CRUD operations | | `platform-resources-health` | platformResourcesHealth CRUD operations | | `platform-resources-requirements-state` | platformResourcesRequirementsState CRUD operations | | `platform-resources-resolved-requirement` | platformResourcesResolvedRequirement CRUD operations | | `platform-webhook-endpoint` | platformWebhookEndpoint CRUD operations | | `platform-webhook-event` | platformWebhookEvent CRUD operations | | `resource` | resource CRUD operations | +| `resource-declared-capacity` | resourceDeclaredCapacity CRUD operations | | `resource-definition` | resourceDefinition CRUD operations | | `resource-event` | resourceEvent CRUD operations | | `resource-installation` | resourceInstallation CRUD operations | | `resource-status-check` | resourceStatusCheck CRUD operations | | `resource-usage-log` | resourceUsageLog CRUD operations | | `resource-usage-summary` | resourceUsageSummary CRUD operations | -| `resource-utilization-daily` | resourceUtilizationDaily CRUD operations | +| `resource-utilization` | resourceUtilization CRUD operations | | `resources-health` | resourcesHealth CRUD operations | | `resources-requirements-state` | resourcesRequirementsState CRUD operations | | `resources-resolved-requirement` | resourcesResolvedRequirement CRUD operations | @@ -197,39 +199,6 @@ CRUD operations for DbPreset records. **Required create fields:** `definition`, `slug` **Optional create fields (backend defaults):** `active`, `commitId`, `description`, `label`, `modulesHash`, `storeId` -### `declared-capacity` - -CRUD operations for DeclaredCapacity records. - -| Subcommand | Description | -|------------|-------------| -| `list` | List all declaredCapacity records | -| `find-first` | Find first matching declaredCapacity record | -| `get` | Get a declaredCapacity by id | -| `create` | Create a new declaredCapacity | -| `update` | Update an existing declaredCapacity | -| `delete` | Delete a declaredCapacity | - -**Fields:** - -| Field | Type | -|-------|------| -| `cpuLimitMillicores` | BigInt | -| `cpuRequestMillicores` | BigInt | -| `installationId` | UUID | -| `isTransient` | Boolean | -| `kind` | String | -| `memoryLimitBytes` | BigInt | -| `memoryRequestBytes` | BigInt | -| `namespaceId` | UUID | -| `podCountMax` | Int | -| `podCountMin` | Int | -| `source` | String | -| `sourceId` | UUID | -| `storageSizeBytes` | BigInt | - -**Required create fields:** `cpuLimitMillicores`, `cpuRequestMillicores`, `installationId`, `isTransient`, `kind`, `memoryLimitBytes`, `memoryRequestBytes`, `namespaceId`, `podCountMax`, `podCountMin`, `source`, `sourceId`, `storageSizeBytes` - ### `function-api-binding` CRUD operations for FunctionApiBinding records. @@ -317,7 +286,7 @@ CRUD operations for FunctionDefinition records. | `updatedAt` | Datetime | | `volatile` | Boolean | -**Required create fields:** `category`, `databaseId`, `name`, `taskIdentifier` +**Required create fields:** `category`, `databaseId`, `name` **Optional create fields (backend defaults):** `accessChannels`, `concurrency`, `description`, `fnCategory`, `functionColumns`, `graphId`, `icon`, `image`, `inputs`, `integrations`, `isPublished`, `maxAttempts`, `moduleTable`, `outputs`, `payloadArgs`, `priority`, `props`, `protected`, `publishedAt`, `queueName`, `requiredBuckets`, `requiredConfigs`, `requiredModels`, `requiredSecrets`, `resources`, `runtime`, `scaleMax`, `scaleMin`, `targetFunction`, `targetSchema`, `timeoutSeconds`, `volatile` ### `function-deployment` @@ -677,6 +646,40 @@ CRUD operations for FunctionGraphStore records. **Required create fields:** `name`, `scopeId` **Optional create fields (backend defaults):** `hash` +### `function-invocation-attempt` + +CRUD operations for FunctionInvocationAttempt records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all functionInvocationAttempt records | +| `find-first` | Find first matching functionInvocationAttempt record | +| `get` | Get a functionInvocationAttempt by id | +| `create` | Create a new functionInvocationAttempt | +| `update` | Update an existing functionInvocationAttempt | +| `delete` | Delete a functionInvocationAttempt | + +**Fields:** + +| Field | Type | +|-------|------| +| `actorId` | UUID | +| `attempt` | Int | +| `createdAt` | Datetime | +| `databaseId` | UUID | +| `durationMs` | Int | +| `error` | String | +| `errorDetail` | JSON | +| `id` | UUID | +| `invocationCreatedAt` | Datetime | +| `invocationId` | UUID | +| `startedAt` | Datetime | +| `success` | Boolean | +| `taskIdentifier` | String | + +**Required create fields:** `attempt`, `databaseId`, `invocationCreatedAt`, `invocationId`, `success`, `taskIdentifier` +**Optional create fields (backend defaults):** `actorId`, `durationMs`, `error`, `errorDetail`, `startedAt` + ### `function-invocation` CRUD operations for FunctionInvocation records. @@ -967,39 +970,6 @@ CRUD operations for NamespaceEvent records. **Required create fields:** `databaseId`, `eventType`, `namespaceId` **Optional create fields (backend defaults):** `actorId`, `message`, `metadata` -### `platform-declared-capacity` - -CRUD operations for PlatformDeclaredCapacity records. - -| Subcommand | Description | -|------------|-------------| -| `list` | List all platformDeclaredCapacity records | -| `find-first` | Find first matching platformDeclaredCapacity record | -| `get` | Get a platformDeclaredCapacity by id | -| `create` | Create a new platformDeclaredCapacity | -| `update` | Update an existing platformDeclaredCapacity | -| `delete` | Delete a platformDeclaredCapacity | - -**Fields:** - -| Field | Type | -|-------|------| -| `cpuLimitMillicores` | BigInt | -| `cpuRequestMillicores` | BigInt | -| `installationId` | UUID | -| `isTransient` | Boolean | -| `kind` | String | -| `memoryLimitBytes` | BigInt | -| `memoryRequestBytes` | BigInt | -| `namespaceId` | UUID | -| `podCountMax` | Int | -| `podCountMin` | Int | -| `source` | String | -| `sourceId` | UUID | -| `storageSizeBytes` | BigInt | - -**Required create fields:** `cpuLimitMillicores`, `cpuRequestMillicores`, `installationId`, `isTransient`, `kind`, `memoryLimitBytes`, `memoryRequestBytes`, `namespaceId`, `podCountMax`, `podCountMin`, `source`, `sourceId`, `storageSizeBytes` - ### `platform-function-api-binding` CRUD operations for PlatformFunctionApiBinding records. @@ -1044,6 +1014,7 @@ CRUD operations for PlatformFunctionDefinition records. | Field | Type | |-------|------| | `accessChannels` | String | +| `billable` | Boolean | | `category` | String | | `concurrency` | Int | | `cpuLimitMillicores` | BigInt | @@ -1079,6 +1050,7 @@ CRUD operations for PlatformFunctionDefinition records. | `runtime` | String | | `scaleMax` | Int | | `scaleMin` | Int | +| `system` | Boolean | | `targetFunction` | String | | `targetSchema` | String | | `taskIdentifier` | String | @@ -1086,8 +1058,8 @@ CRUD operations for PlatformFunctionDefinition records. | `updatedAt` | Datetime | | `volatile` | Boolean | -**Required create fields:** `category`, `name`, `taskIdentifier` -**Optional create fields (backend defaults):** `accessChannels`, `concurrency`, `description`, `fnCategory`, `functionColumns`, `graphId`, `icon`, `image`, `inputs`, `integrations`, `isPublished`, `maxAttempts`, `moduleTable`, `outputs`, `payloadArgs`, `priority`, `props`, `protected`, `publishedAt`, `queueName`, `requiredBuckets`, `requiredConfigs`, `requiredModels`, `requiredSecrets`, `resources`, `runtime`, `scaleMax`, `scaleMin`, `targetFunction`, `targetSchema`, `timeoutSeconds`, `volatile` +**Required create fields:** `category`, `name` +**Optional create fields (backend defaults):** `accessChannels`, `billable`, `concurrency`, `description`, `fnCategory`, `functionColumns`, `graphId`, `icon`, `image`, `inputs`, `integrations`, `isPublished`, `maxAttempts`, `moduleTable`, `outputs`, `payloadArgs`, `priority`, `props`, `protected`, `publishedAt`, `queueName`, `requiredBuckets`, `requiredConfigs`, `requiredModels`, `requiredSecrets`, `resources`, `runtime`, `scaleMax`, `scaleMin`, `system`, `targetFunction`, `targetSchema`, `timeoutSeconds`, `volatile` ### `platform-function-deployment` @@ -1188,6 +1160,39 @@ CRUD operations for PlatformFunctionExecutionLog records. **Required create fields:** `message` **Optional create fields (backend defaults):** `actorId`, `invocationId`, `logLevel`, `metadata`, `taskIdentifier` +### `platform-function-invocation-attempt` + +CRUD operations for PlatformFunctionInvocationAttempt records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all platformFunctionInvocationAttempt records | +| `find-first` | Find first matching platformFunctionInvocationAttempt record | +| `get` | Get a platformFunctionInvocationAttempt by id | +| `create` | Create a new platformFunctionInvocationAttempt | +| `update` | Update an existing platformFunctionInvocationAttempt | +| `delete` | Delete a platformFunctionInvocationAttempt | + +**Fields:** + +| Field | Type | +|-------|------| +| `actorId` | UUID | +| `attempt` | Int | +| `createdAt` | Datetime | +| `durationMs` | Int | +| `error` | String | +| `errorDetail` | JSON | +| `id` | UUID | +| `invocationCreatedAt` | Datetime | +| `invocationId` | UUID | +| `startedAt` | Datetime | +| `success` | Boolean | +| `taskIdentifier` | String | + +**Required create fields:** `attempt`, `invocationCreatedAt`, `invocationId`, `success`, `taskIdentifier` +**Optional create fields (backend defaults):** `actorId`, `durationMs`, `error`, `errorDetail`, `startedAt` + ### `platform-function-invocation` CRUD operations for PlatformFunctionInvocation records. @@ -1470,6 +1475,39 @@ CRUD operations for PlatformResource records. **Required create fields:** `kind`, `name`, `namespaceId`, `slug` **Optional create fields (backend defaults):** `annotations`, `createdBy`, `errorCount`, `installationId`, `integrations`, `labels`, `lastError`, `lastHeartbeatAt`, `requiredConfigs`, `requiredSecrets`, `resourceDefinitionId`, `spec`, `status`, `statusObserved`, `updatedBy` +### `platform-resource-declared-capacity` + +CRUD operations for PlatformResourceDeclaredCapacity records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all platformResourceDeclaredCapacity records | +| `find-first` | Find first matching platformResourceDeclaredCapacity record | +| `get` | Get a platformResourceDeclaredCapacity by id | +| `create` | Create a new platformResourceDeclaredCapacity | +| `update` | Update an existing platformResourceDeclaredCapacity | +| `delete` | Delete a platformResourceDeclaredCapacity | + +**Fields:** + +| Field | Type | +|-------|------| +| `cpuLimitMillicores` | BigInt | +| `cpuRequestMillicores` | BigInt | +| `installationId` | UUID | +| `isTransient` | Boolean | +| `kind` | String | +| `memoryLimitBytes` | BigInt | +| `memoryRequestBytes` | BigInt | +| `namespaceId` | UUID | +| `podCountMax` | Int | +| `podCountMin` | Int | +| `source` | String | +| `sourceId` | UUID | +| `storageSizeBytes` | BigInt | + +**Required create fields:** `cpuLimitMillicores`, `cpuRequestMillicores`, `installationId`, `isTransient`, `kind`, `memoryLimitBytes`, `memoryRequestBytes`, `namespaceId`, `podCountMax`, `podCountMin`, `source`, `sourceId`, `storageSizeBytes` + ### `platform-resource-definition` CRUD operations for PlatformResourceDefinition records. @@ -1658,18 +1696,18 @@ CRUD operations for PlatformResourceUsageSummary records. **Required create fields:** `date`, `namespaceId` **Optional create fields (backend defaults):** `gbSeconds`, `maxCpuMillicores`, `maxMemoryBytes`, `resourceId`, `runtimeSeconds`, `sampleCount` -### `platform-resource-utilization-daily` +### `platform-resource-utilization` -CRUD operations for PlatformResourceUtilizationDaily records. +CRUD operations for PlatformResourceUtilization records. | Subcommand | Description | |------------|-------------| -| `list` | List all platformResourceUtilizationDaily records | -| `find-first` | Find first matching platformResourceUtilizationDaily record | -| `get` | Get a platformResourceUtilizationDaily by id | -| `create` | Create a new platformResourceUtilizationDaily | -| `update` | Update an existing platformResourceUtilizationDaily | -| `delete` | Delete a platformResourceUtilizationDaily | +| `list` | List all platformResourceUtilization records | +| `find-first` | Find first matching platformResourceUtilization record | +| `get` | Get a platformResourceUtilization by id | +| `create` | Create a new platformResourceUtilization | +| `update` | Update an existing platformResourceUtilization | +| `delete` | Delete a platformResourceUtilization | **Fields:** @@ -1922,6 +1960,39 @@ CRUD operations for Resource records. **Required create fields:** `databaseId`, `kind`, `name`, `namespaceId`, `slug` **Optional create fields (backend defaults):** `annotations`, `createdBy`, `errorCount`, `installationId`, `integrations`, `labels`, `lastError`, `lastHeartbeatAt`, `requiredConfigs`, `requiredSecrets`, `resourceDefinitionId`, `spec`, `status`, `statusObserved`, `updatedBy` +### `resource-declared-capacity` + +CRUD operations for ResourceDeclaredCapacity records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all resourceDeclaredCapacity records | +| `find-first` | Find first matching resourceDeclaredCapacity record | +| `get` | Get a resourceDeclaredCapacity by id | +| `create` | Create a new resourceDeclaredCapacity | +| `update` | Update an existing resourceDeclaredCapacity | +| `delete` | Delete a resourceDeclaredCapacity | + +**Fields:** + +| Field | Type | +|-------|------| +| `cpuLimitMillicores` | BigInt | +| `cpuRequestMillicores` | BigInt | +| `installationId` | UUID | +| `isTransient` | Boolean | +| `kind` | String | +| `memoryLimitBytes` | BigInt | +| `memoryRequestBytes` | BigInt | +| `namespaceId` | UUID | +| `podCountMax` | Int | +| `podCountMin` | Int | +| `source` | String | +| `sourceId` | UUID | +| `storageSizeBytes` | BigInt | + +**Required create fields:** `cpuLimitMillicores`, `cpuRequestMillicores`, `installationId`, `isTransient`, `kind`, `memoryLimitBytes`, `memoryRequestBytes`, `namespaceId`, `podCountMax`, `podCountMin`, `source`, `sourceId`, `storageSizeBytes` + ### `resource-definition` CRUD operations for ResourceDefinition records. @@ -2116,18 +2187,18 @@ CRUD operations for ResourceUsageSummary records. **Required create fields:** `databaseId`, `date`, `namespaceId` **Optional create fields (backend defaults):** `gbSeconds`, `maxCpuMillicores`, `maxMemoryBytes`, `resourceId`, `runtimeSeconds`, `sampleCount` -### `resource-utilization-daily` +### `resource-utilization` -CRUD operations for ResourceUtilizationDaily records. +CRUD operations for ResourceUtilization records. | Subcommand | Description | |------------|-------------| -| `list` | List all resourceUtilizationDaily records | -| `find-first` | Find first matching resourceUtilizationDaily record | -| `get` | Get a resourceUtilizationDaily by id | -| `create` | Create a new resourceUtilizationDaily | -| `update` | Update an existing resourceUtilizationDaily | -| `delete` | Delete a resourceUtilizationDaily | +| `list` | List all resourceUtilization records | +| `find-first` | Find first matching resourceUtilization record | +| `get` | Get a resourceUtilization by id | +| `create` | Create a new resourceUtilization | +| `update` | Update an existing resourceUtilization | +| `delete` | Delete a resourceUtilization | **Fields:** @@ -2594,10 +2665,10 @@ platformResourceInstallationsInstall | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pName` | String | - | `--input.pNamespaceId` | UUID | - | `--input.pParams` | JSON | - | `--input.pSlug` | String | + | `--input.name` | String | + | `--input.namespaceId` | UUID | + | `--input.newParams` | JSON | + | `--input.slug` | String | ### `platform-resource-installations-rollback` @@ -2609,8 +2680,8 @@ platformResourceInstallationsRollback | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pCommitId` | UUID | - | `--input.pInstallationId` | UUID | + | `--input.commitId` | UUID | + | `--input.targetInstallationId` | UUID | ### `platform-resource-installations-uninstall` @@ -2622,7 +2693,7 @@ platformResourceInstallationsUninstall | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pInstallationId` | UUID | + | `--input.targetInstallationId` | UUID | ### `platform-resource-installations-upgrade` @@ -2634,8 +2705,8 @@ platformResourceInstallationsUpgrade | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pInstallationId` | UUID | - | `--input.pParams` | JSON | + | `--input.newParams` | JSON | + | `--input.targetInstallationId` | UUID | ### `provision-bucket` @@ -2662,10 +2733,10 @@ resourceInstallationsInstall | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pName` | String | - | `--input.pNamespaceId` | UUID | - | `--input.pParams` | JSON | - | `--input.pSlug` | String | + | `--input.name` | String | + | `--input.namespaceId` | UUID | + | `--input.newParams` | JSON | + | `--input.slug` | String | ### `resource-installations-rollback` @@ -2677,8 +2748,8 @@ resourceInstallationsRollback | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pCommitId` | UUID | - | `--input.pInstallationId` | UUID | + | `--input.commitId` | UUID | + | `--input.targetInstallationId` | UUID | ### `resource-installations-uninstall` @@ -2690,7 +2761,7 @@ resourceInstallationsUninstall | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pInstallationId` | UUID | + | `--input.targetInstallationId` | UUID | ### `resource-installations-upgrade` @@ -2702,8 +2773,8 @@ resourceInstallationsUpgrade | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pInstallationId` | UUID | - | `--input.pParams` | JSON | + | `--input.newParams` | JSON | + | `--input.targetInstallationId` | UUID | ### `save-graph` diff --git a/sdk/constructive-cli/src/compute/cli/commands.ts b/sdk/constructive-cli/src/compute/cli/commands.ts index 45fffdfe2..4839d1a18 100644 --- a/sdk/constructive-cli/src/compute/cli/commands.ts +++ b/sdk/constructive-cli/src/compute/cli/commands.ts @@ -7,7 +7,6 @@ import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; import contextCmd from './commands/context'; import authCmd from './commands/auth'; import dbPresetCmd from './commands/db-preset'; -import declaredCapacityCmd from './commands/declared-capacity'; import functionApiBindingCmd from './commands/function-api-binding'; import functionDefinitionCmd from './commands/function-definition'; import functionDeploymentCmd from './commands/function-deployment'; @@ -21,6 +20,7 @@ import functionGraphExecutionOutputCmd from './commands/function-graph-execution import functionGraphObjectCmd from './commands/function-graph-object'; import functionGraphRefCmd from './commands/function-graph-ref'; import functionGraphStoreCmd from './commands/function-graph-store'; +import functionInvocationAttemptCmd from './commands/function-invocation-attempt'; import functionInvocationCmd from './commands/function-invocation'; import getAllTreeNodesRecordCmd from './commands/get-all-tree-nodes-record'; import infraCommitCmd from './commands/infra-commit'; @@ -31,12 +31,12 @@ import infraStoreCmd from './commands/infra-store'; import integrationProviderCmd from './commands/integration-provider'; import namespaceCmd from './commands/namespace'; import namespaceEventCmd from './commands/namespace-event'; -import platformDeclaredCapacityCmd from './commands/platform-declared-capacity'; import platformFunctionApiBindingCmd from './commands/platform-function-api-binding'; import platformFunctionDefinitionCmd from './commands/platform-function-definition'; import platformFunctionDeploymentCmd from './commands/platform-function-deployment'; import platformFunctionDeploymentEventCmd from './commands/platform-function-deployment-event'; import platformFunctionExecutionLogCmd from './commands/platform-function-execution-log'; +import platformFunctionInvocationAttemptCmd from './commands/platform-function-invocation-attempt'; import platformFunctionInvocationCmd from './commands/platform-function-invocation'; import platformInfraCommitCmd from './commands/platform-infra-commit'; import platformInfraGetAllTreeNodesRecordCmd from './commands/platform-infra-get-all-tree-nodes-record'; @@ -46,26 +46,28 @@ import platformInfraStoreCmd from './commands/platform-infra-store'; import platformNamespaceCmd from './commands/platform-namespace'; import platformNamespaceEventCmd from './commands/platform-namespace-event'; import platformResourceCmd from './commands/platform-resource'; +import platformResourceDeclaredCapacityCmd from './commands/platform-resource-declared-capacity'; import platformResourceDefinitionCmd from './commands/platform-resource-definition'; import platformResourceEventCmd from './commands/platform-resource-event'; import platformResourceInstallationCmd from './commands/platform-resource-installation'; import platformResourceStatusCheckCmd from './commands/platform-resource-status-check'; import platformResourceUsageLogCmd from './commands/platform-resource-usage-log'; import platformResourceUsageSummaryCmd from './commands/platform-resource-usage-summary'; -import platformResourceUtilizationDailyCmd from './commands/platform-resource-utilization-daily'; +import platformResourceUtilizationCmd from './commands/platform-resource-utilization'; import platformResourcesHealthCmd from './commands/platform-resources-health'; import platformResourcesRequirementsStateCmd from './commands/platform-resources-requirements-state'; import platformResourcesResolvedRequirementCmd from './commands/platform-resources-resolved-requirement'; import platformWebhookEndpointCmd from './commands/platform-webhook-endpoint'; import platformWebhookEventCmd from './commands/platform-webhook-event'; import resourceCmd from './commands/resource'; +import resourceDeclaredCapacityCmd from './commands/resource-declared-capacity'; import resourceDefinitionCmd from './commands/resource-definition'; import resourceEventCmd from './commands/resource-event'; import resourceInstallationCmd from './commands/resource-installation'; import resourceStatusCheckCmd from './commands/resource-status-check'; import resourceUsageLogCmd from './commands/resource-usage-log'; import resourceUsageSummaryCmd from './commands/resource-usage-summary'; -import resourceUtilizationDailyCmd from './commands/resource-utilization-daily'; +import resourceUtilizationCmd from './commands/resource-utilization'; import resourcesHealthCmd from './commands/resources-health'; import resourcesRequirementsStateCmd from './commands/resources-requirements-state'; import resourcesResolvedRequirementCmd from './commands/resources-resolved-requirement'; @@ -111,7 +113,6 @@ const createCommandMap: () => Record< context: contextCmd, auth: authCmd, 'db-preset': dbPresetCmd, - 'declared-capacity': declaredCapacityCmd, 'function-api-binding': functionApiBindingCmd, 'function-definition': functionDefinitionCmd, 'function-deployment': functionDeploymentCmd, @@ -125,6 +126,7 @@ const createCommandMap: () => Record< 'function-graph-object': functionGraphObjectCmd, 'function-graph-ref': functionGraphRefCmd, 'function-graph-store': functionGraphStoreCmd, + 'function-invocation-attempt': functionInvocationAttemptCmd, 'function-invocation': functionInvocationCmd, 'get-all-tree-nodes-record': getAllTreeNodesRecordCmd, 'infra-commit': infraCommitCmd, @@ -135,12 +137,12 @@ const createCommandMap: () => Record< 'integration-provider': integrationProviderCmd, namespace: namespaceCmd, 'namespace-event': namespaceEventCmd, - 'platform-declared-capacity': platformDeclaredCapacityCmd, 'platform-function-api-binding': platformFunctionApiBindingCmd, 'platform-function-definition': platformFunctionDefinitionCmd, 'platform-function-deployment': platformFunctionDeploymentCmd, 'platform-function-deployment-event': platformFunctionDeploymentEventCmd, 'platform-function-execution-log': platformFunctionExecutionLogCmd, + 'platform-function-invocation-attempt': platformFunctionInvocationAttemptCmd, 'platform-function-invocation': platformFunctionInvocationCmd, 'platform-infra-commit': platformInfraCommitCmd, 'platform-infra-get-all-tree-nodes-record': platformInfraGetAllTreeNodesRecordCmd, @@ -150,26 +152,28 @@ const createCommandMap: () => Record< 'platform-namespace': platformNamespaceCmd, 'platform-namespace-event': platformNamespaceEventCmd, 'platform-resource': platformResourceCmd, + 'platform-resource-declared-capacity': platformResourceDeclaredCapacityCmd, 'platform-resource-definition': platformResourceDefinitionCmd, 'platform-resource-event': platformResourceEventCmd, 'platform-resource-installation': platformResourceInstallationCmd, 'platform-resource-status-check': platformResourceStatusCheckCmd, 'platform-resource-usage-log': platformResourceUsageLogCmd, 'platform-resource-usage-summary': platformResourceUsageSummaryCmd, - 'platform-resource-utilization-daily': platformResourceUtilizationDailyCmd, + 'platform-resource-utilization': platformResourceUtilizationCmd, 'platform-resources-health': platformResourcesHealthCmd, 'platform-resources-requirements-state': platformResourcesRequirementsStateCmd, 'platform-resources-resolved-requirement': platformResourcesResolvedRequirementCmd, 'platform-webhook-endpoint': platformWebhookEndpointCmd, 'platform-webhook-event': platformWebhookEventCmd, resource: resourceCmd, + 'resource-declared-capacity': resourceDeclaredCapacityCmd, 'resource-definition': resourceDefinitionCmd, 'resource-event': resourceEventCmd, 'resource-installation': resourceInstallationCmd, 'resource-status-check': resourceStatusCheckCmd, 'resource-usage-log': resourceUsageLogCmd, 'resource-usage-summary': resourceUsageSummaryCmd, - 'resource-utilization-daily': resourceUtilizationDailyCmd, + 'resource-utilization': resourceUtilizationCmd, 'resources-health': resourcesHealthCmd, 'resources-requirements-state': resourcesRequirementsStateCmd, 'resources-resolved-requirement': resourcesResolvedRequirementCmd, @@ -206,7 +210,7 @@ const createCommandMap: () => Record< 'validate-function-graph': validateFunctionGraphCmd, }); const usage = - '\ncsdk \n\nCommands:\n context Manage API contexts\n auth Manage authentication\n db-preset dbPreset CRUD operations\n declared-capacity declaredCapacity CRUD operations\n function-api-binding functionApiBinding CRUD operations\n function-definition functionDefinition CRUD operations\n function-deployment functionDeployment CRUD operations\n function-deployment-event functionDeploymentEvent CRUD operations\n function-execution-log functionExecutionLog CRUD operations\n function-graph-commit functionGraphCommit CRUD operations\n function-graph functionGraph CRUD operations\n function-graph-execution functionGraphExecution CRUD operations\n function-graph-execution-node-state functionGraphExecutionNodeState CRUD operations\n function-graph-execution-output functionGraphExecutionOutput CRUD operations\n function-graph-object functionGraphObject CRUD operations\n function-graph-ref functionGraphRef CRUD operations\n function-graph-store functionGraphStore CRUD operations\n function-invocation functionInvocation CRUD operations\n get-all-tree-nodes-record getAllTreeNodesRecord CRUD operations\n infra-commit infraCommit CRUD operations\n infra-get-all-tree-nodes-record infraGetAllTreeNodesRecord CRUD operations\n infra-object infraObject CRUD operations\n infra-ref infraRef CRUD operations\n infra-store infraStore CRUD operations\n integration-provider integrationProvider CRUD operations\n namespace namespace CRUD operations\n namespace-event namespaceEvent CRUD operations\n platform-declared-capacity platformDeclaredCapacity CRUD operations\n platform-function-api-binding platformFunctionApiBinding CRUD operations\n platform-function-definition platformFunctionDefinition CRUD operations\n platform-function-deployment platformFunctionDeployment CRUD operations\n platform-function-deployment-event platformFunctionDeploymentEvent CRUD operations\n platform-function-execution-log platformFunctionExecutionLog CRUD operations\n platform-function-invocation platformFunctionInvocation CRUD operations\n platform-infra-commit platformInfraCommit CRUD operations\n platform-infra-get-all-tree-nodes-record platformInfraGetAllTreeNodesRecord CRUD operations\n platform-infra-object platformInfraObject CRUD operations\n platform-infra-ref platformInfraRef CRUD operations\n platform-infra-store platformInfraStore CRUD operations\n platform-namespace platformNamespace CRUD operations\n platform-namespace-event platformNamespaceEvent CRUD operations\n platform-resource platformResource CRUD operations\n platform-resource-definition platformResourceDefinition CRUD operations\n platform-resource-event platformResourceEvent CRUD operations\n platform-resource-installation platformResourceInstallation CRUD operations\n platform-resource-status-check platformResourceStatusCheck CRUD operations\n platform-resource-usage-log platformResourceUsageLog CRUD operations\n platform-resource-usage-summary platformResourceUsageSummary CRUD operations\n platform-resource-utilization-daily platformResourceUtilizationDaily CRUD operations\n platform-resources-health platformResourcesHealth CRUD operations\n platform-resources-requirements-state platformResourcesRequirementsState CRUD operations\n platform-resources-resolved-requirement platformResourcesResolvedRequirement CRUD operations\n platform-webhook-endpoint platformWebhookEndpoint CRUD operations\n platform-webhook-event platformWebhookEvent CRUD operations\n resource resource CRUD operations\n resource-definition resourceDefinition CRUD operations\n resource-event resourceEvent CRUD operations\n resource-installation resourceInstallation CRUD operations\n resource-status-check resourceStatusCheck CRUD operations\n resource-usage-log resourceUsageLog CRUD operations\n resource-usage-summary resourceUsageSummary CRUD operations\n resource-utilization-daily resourceUtilizationDaily CRUD operations\n resources-health resourcesHealth CRUD operations\n resources-requirements-state resourcesRequirementsState CRUD operations\n resources-resolved-requirement resourcesResolvedRequirement CRUD operations\n webhook-endpoint webhookEndpoint CRUD operations\n webhook-event webhookEvent CRUD operations\n read-function-graph readFunctionGraph\n add-edge addEdge\n add-edge-and-save addEdgeAndSave\n add-node addNode\n add-node-and-save addNodeAndSave\n copy-graph copyGraph\n import-definitions importDefinitions\n import-graph-json importGraphJson\n infra-init-empty-repo infraInitEmptyRepo\n infra-insert-node-at-path infraInsertNodeAtPath\n infra-set-data-at-path infraSetDataAtPath\n init-empty-repo initEmptyRepo\n insert-node-at-path insertNodeAtPath\n platform-infra-init-empty-repo platformInfraInitEmptyRepo\n platform-infra-insert-node-at-path platformInfraInsertNodeAtPath\n platform-infra-set-data-at-path platformInfraSetDataAtPath\n platform-resource-installations-install platformResourceInstallationsInstall\n platform-resource-installations-rollback platformResourceInstallationsRollback\n platform-resource-installations-uninstall platformResourceInstallationsUninstall\n platform-resource-installations-upgrade platformResourceInstallationsUpgrade\n provision-bucket Provision an S3 bucket for a logical bucket in the database.\nReads the bucket config via RLS, then creates and configures\nthe S3 bucket with the appropriate privacy policies, CORS rules,\nand lifecycle settings.\n resource-installations-install resourceInstallationsInstall\n resource-installations-rollback resourceInstallationsRollback\n resource-installations-uninstall resourceInstallationsUninstall\n resource-installations-upgrade resourceInstallationsUpgrade\n save-graph saveGraph\n set-data-at-path setDataAtPath\n start-execution startExecution\n validate-function-graph validateFunctionGraph\n\n --help, -h Show this help message\n --version, -v Show version\n'; + '\ncsdk \n\nCommands:\n context Manage API contexts\n auth Manage authentication\n db-preset dbPreset CRUD operations\n function-api-binding functionApiBinding CRUD operations\n function-definition functionDefinition CRUD operations\n function-deployment functionDeployment CRUD operations\n function-deployment-event functionDeploymentEvent CRUD operations\n function-execution-log functionExecutionLog CRUD operations\n function-graph-commit functionGraphCommit CRUD operations\n function-graph functionGraph CRUD operations\n function-graph-execution functionGraphExecution CRUD operations\n function-graph-execution-node-state functionGraphExecutionNodeState CRUD operations\n function-graph-execution-output functionGraphExecutionOutput CRUD operations\n function-graph-object functionGraphObject CRUD operations\n function-graph-ref functionGraphRef CRUD operations\n function-graph-store functionGraphStore CRUD operations\n function-invocation-attempt functionInvocationAttempt CRUD operations\n function-invocation functionInvocation CRUD operations\n get-all-tree-nodes-record getAllTreeNodesRecord CRUD operations\n infra-commit infraCommit CRUD operations\n infra-get-all-tree-nodes-record infraGetAllTreeNodesRecord CRUD operations\n infra-object infraObject CRUD operations\n infra-ref infraRef CRUD operations\n infra-store infraStore CRUD operations\n integration-provider integrationProvider CRUD operations\n namespace namespace CRUD operations\n namespace-event namespaceEvent CRUD operations\n platform-function-api-binding platformFunctionApiBinding CRUD operations\n platform-function-definition platformFunctionDefinition CRUD operations\n platform-function-deployment platformFunctionDeployment CRUD operations\n platform-function-deployment-event platformFunctionDeploymentEvent CRUD operations\n platform-function-execution-log platformFunctionExecutionLog CRUD operations\n platform-function-invocation-attempt platformFunctionInvocationAttempt CRUD operations\n platform-function-invocation platformFunctionInvocation CRUD operations\n platform-infra-commit platformInfraCommit CRUD operations\n platform-infra-get-all-tree-nodes-record platformInfraGetAllTreeNodesRecord CRUD operations\n platform-infra-object platformInfraObject CRUD operations\n platform-infra-ref platformInfraRef CRUD operations\n platform-infra-store platformInfraStore CRUD operations\n platform-namespace platformNamespace CRUD operations\n platform-namespace-event platformNamespaceEvent CRUD operations\n platform-resource platformResource CRUD operations\n platform-resource-declared-capacity platformResourceDeclaredCapacity CRUD operations\n platform-resource-definition platformResourceDefinition CRUD operations\n platform-resource-event platformResourceEvent CRUD operations\n platform-resource-installation platformResourceInstallation CRUD operations\n platform-resource-status-check platformResourceStatusCheck CRUD operations\n platform-resource-usage-log platformResourceUsageLog CRUD operations\n platform-resource-usage-summary platformResourceUsageSummary CRUD operations\n platform-resource-utilization platformResourceUtilization CRUD operations\n platform-resources-health platformResourcesHealth CRUD operations\n platform-resources-requirements-state platformResourcesRequirementsState CRUD operations\n platform-resources-resolved-requirement platformResourcesResolvedRequirement CRUD operations\n platform-webhook-endpoint platformWebhookEndpoint CRUD operations\n platform-webhook-event platformWebhookEvent CRUD operations\n resource resource CRUD operations\n resource-declared-capacity resourceDeclaredCapacity CRUD operations\n resource-definition resourceDefinition CRUD operations\n resource-event resourceEvent CRUD operations\n resource-installation resourceInstallation CRUD operations\n resource-status-check resourceStatusCheck CRUD operations\n resource-usage-log resourceUsageLog CRUD operations\n resource-usage-summary resourceUsageSummary CRUD operations\n resource-utilization resourceUtilization CRUD operations\n resources-health resourcesHealth CRUD operations\n resources-requirements-state resourcesRequirementsState CRUD operations\n resources-resolved-requirement resourcesResolvedRequirement CRUD operations\n webhook-endpoint webhookEndpoint CRUD operations\n webhook-event webhookEvent CRUD operations\n read-function-graph readFunctionGraph\n add-edge addEdge\n add-edge-and-save addEdgeAndSave\n add-node addNode\n add-node-and-save addNodeAndSave\n copy-graph copyGraph\n import-definitions importDefinitions\n import-graph-json importGraphJson\n infra-init-empty-repo infraInitEmptyRepo\n infra-insert-node-at-path infraInsertNodeAtPath\n infra-set-data-at-path infraSetDataAtPath\n init-empty-repo initEmptyRepo\n insert-node-at-path insertNodeAtPath\n platform-infra-init-empty-repo platformInfraInitEmptyRepo\n platform-infra-insert-node-at-path platformInfraInsertNodeAtPath\n platform-infra-set-data-at-path platformInfraSetDataAtPath\n platform-resource-installations-install platformResourceInstallationsInstall\n platform-resource-installations-rollback platformResourceInstallationsRollback\n platform-resource-installations-uninstall platformResourceInstallationsUninstall\n platform-resource-installations-upgrade platformResourceInstallationsUpgrade\n provision-bucket Provision an S3 bucket for a logical bucket in the database.\nReads the bucket config via RLS, then creates and configures\nthe S3 bucket with the appropriate privacy policies, CORS rules,\nand lifecycle settings.\n resource-installations-install resourceInstallationsInstall\n resource-installations-rollback resourceInstallationsRollback\n resource-installations-uninstall resourceInstallationsUninstall\n resource-installations-upgrade resourceInstallationsUpgrade\n save-graph saveGraph\n set-data-at-path setDataAtPath\n start-execution startExecution\n validate-function-graph validateFunctionGraph\n\n --help, -h Show this help message\n --version, -v Show version\n'; export const commands = async ( argv: Partial>, prompter: Inquirerer, diff --git a/sdk/constructive-cli/src/compute/cli/commands/function-definition.ts b/sdk/constructive-cli/src/compute/cli/commands/function-definition.ts index 64c65546c..4f44ce5af 100644 --- a/sdk/constructive-cli/src/compute/cli/commands/function-definition.ts +++ b/sdk/constructive-cli/src/compute/cli/commands/function-definition.ts @@ -146,7 +146,6 @@ async function handleList(argv: Partial>, _prompter: Inq scaleMin: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -209,7 +208,6 @@ async function handleFindFirst(argv: Partial>, _prompter scaleMin: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -284,7 +282,6 @@ async function handleGet(argv: Partial>, prompter: Inqui scaleMin: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -531,12 +528,6 @@ async function handleCreate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, - { - type: 'text', - name: 'taskIdentifier', - message: 'taskIdentifier', - required: true, - }, { type: 'text', name: 'timeoutSeconds', @@ -594,7 +585,6 @@ async function handleCreate(argv: Partial>, prompter: In scaleMin: cleanedData.scaleMin, targetFunction: cleanedData.targetFunction, targetSchema: cleanedData.targetSchema, - taskIdentifier: cleanedData.taskIdentifier, timeoutSeconds: cleanedData.timeoutSeconds, volatile: cleanedData.volatile, }, @@ -634,7 +624,6 @@ async function handleCreate(argv: Partial>, prompter: In scaleMin: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -887,12 +876,6 @@ async function handleUpdate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, - { - type: 'text', - name: 'taskIdentifier', - message: 'taskIdentifier', - required: false, - }, { type: 'text', name: 'timeoutSeconds', @@ -950,7 +933,6 @@ async function handleUpdate(argv: Partial>, prompter: In scaleMin: cleanedData.scaleMin, targetFunction: cleanedData.targetFunction, targetSchema: cleanedData.targetSchema, - taskIdentifier: cleanedData.taskIdentifier, timeoutSeconds: cleanedData.timeoutSeconds, volatile: cleanedData.volatile, }, @@ -990,7 +972,6 @@ async function handleUpdate(argv: Partial>, prompter: In scaleMin: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, diff --git a/sdk/constructive-cli/src/compute/cli/commands/function-invocation-attempt.ts b/sdk/constructive-cli/src/compute/cli/commands/function-invocation-attempt.ts new file mode 100644 index 000000000..528c2362a --- /dev/null +++ b/sdk/constructive-cli/src/compute/cli/commands/function-invocation-attempt.ts @@ -0,0 +1,489 @@ +/** + * CLI commands for FunctionInvocationAttempt + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateFunctionInvocationAttemptInput, + FunctionInvocationAttemptPatch, + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + actorId: 'uuid', + attempt: 'int', + createdAt: 'string', + databaseId: 'uuid', + durationMs: 'int', + error: 'string', + errorDetail: 'json', + id: 'uuid', + invocationCreatedAt: 'string', + invocationId: 'uuid', + startedAt: 'string', + success: 'boolean', + taskIdentifier: 'string', +}; +const usage = + '\nfunction-invocation-attempt \n\nCommands:\n list List functionInvocationAttempt records\n find-first Find first matching functionInvocationAttempt record\n get Get a functionInvocationAttempt by ID\n create Create a new functionInvocationAttempt\n update Update an existing functionInvocationAttempt\n delete Delete a functionInvocationAttempt\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + actorId: true, + attempt: true, + createdAt: true, + databaseId: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + > & { + select: FunctionInvocationAttemptSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.functionInvocationAttempt.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + actorId: true, + attempt: true, + createdAt: true, + databaseId: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + > & { + select: FunctionInvocationAttemptSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.functionInvocationAttempt.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.functionInvocationAttempt + .findOne({ + id: answers.id as string, + select: { + actorId: true, + attempt: true, + createdAt: true, + databaseId: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'actorId', + message: 'actorId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'attempt', + message: 'attempt', + required: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: true, + }, + { + type: 'text', + name: 'durationMs', + message: 'durationMs', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'error', + message: 'error', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'errorDetail', + message: 'errorDetail', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'invocationCreatedAt', + message: 'invocationCreatedAt', + required: true, + }, + { + type: 'text', + name: 'invocationId', + message: 'invocationId', + required: true, + }, + { + type: 'text', + name: 'startedAt', + message: 'startedAt', + required: false, + skipPrompt: true, + }, + { + type: 'boolean', + name: 'success', + message: 'success', + required: true, + }, + { + type: 'text', + name: 'taskIdentifier', + message: 'taskIdentifier', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateFunctionInvocationAttemptInput['functionInvocationAttempt']; + const client = getClient(); + const result = await client.functionInvocationAttempt + .create({ + data: { + actorId: cleanedData.actorId, + attempt: cleanedData.attempt, + databaseId: cleanedData.databaseId, + durationMs: cleanedData.durationMs, + error: cleanedData.error, + errorDetail: cleanedData.errorDetail, + invocationCreatedAt: cleanedData.invocationCreatedAt, + invocationId: cleanedData.invocationId, + startedAt: cleanedData.startedAt, + success: cleanedData.success, + taskIdentifier: cleanedData.taskIdentifier, + }, + select: { + actorId: true, + attempt: true, + createdAt: true, + databaseId: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'createdAt', + message: 'createdAt', + required: true, + }, + { + type: 'text', + name: 'actorId', + message: 'actorId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'attempt', + message: 'attempt', + required: false, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: false, + }, + { + type: 'text', + name: 'durationMs', + message: 'durationMs', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'error', + message: 'error', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'errorDetail', + message: 'errorDetail', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'invocationCreatedAt', + message: 'invocationCreatedAt', + required: false, + }, + { + type: 'text', + name: 'invocationId', + message: 'invocationId', + required: false, + }, + { + type: 'text', + name: 'startedAt', + message: 'startedAt', + required: false, + skipPrompt: true, + }, + { + type: 'boolean', + name: 'success', + message: 'success', + required: false, + }, + { + type: 'text', + name: 'taskIdentifier', + message: 'taskIdentifier', + required: false, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as FunctionInvocationAttemptPatch; + const client = getClient(); + const result = await client.functionInvocationAttempt + .update({ + where: { + id: answers.id as string, + createdAt: answers.createdAt as string, + }, + data: { + actorId: cleanedData.actorId, + attempt: cleanedData.attempt, + databaseId: cleanedData.databaseId, + durationMs: cleanedData.durationMs, + error: cleanedData.error, + errorDetail: cleanedData.errorDetail, + invocationCreatedAt: cleanedData.invocationCreatedAt, + invocationId: cleanedData.invocationId, + startedAt: cleanedData.startedAt, + success: cleanedData.success, + taskIdentifier: cleanedData.taskIdentifier, + }, + select: { + actorId: true, + attempt: true, + createdAt: true, + databaseId: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'createdAt', + message: 'createdAt', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.functionInvocationAttempt + .delete({ + where: { + id: answers.id as string, + createdAt: answers.createdAt as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/compute/cli/commands/platform-function-definition.ts b/sdk/constructive-cli/src/compute/cli/commands/platform-function-definition.ts index 351756bab..66df7440e 100644 --- a/sdk/constructive-cli/src/compute/cli/commands/platform-function-definition.ts +++ b/sdk/constructive-cli/src/compute/cli/commands/platform-function-definition.ts @@ -17,6 +17,7 @@ import type { import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { accessChannels: 'string', + billable: 'boolean', category: 'string', concurrency: 'int', cpuLimitMillicores: 'int', @@ -52,6 +53,7 @@ const fieldSchema: FieldSchema = { runtime: 'string', scaleMax: 'int', scaleMin: 'int', + system: 'boolean', targetFunction: 'string', targetSchema: 'string', taskIdentifier: 'string', @@ -111,6 +113,7 @@ async function handleList(argv: Partial>, _prompter: Inq try { const defaultSelect = { accessChannels: true, + billable: true, category: true, concurrency: true, createdAt: true, @@ -142,9 +145,9 @@ async function handleList(argv: Partial>, _prompter: Inq runtime: true, scaleMax: true, scaleMin: true, + system: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -173,6 +176,7 @@ async function handleFindFirst(argv: Partial>, _prompter try { const defaultSelect = { accessChannels: true, + billable: true, category: true, concurrency: true, createdAt: true, @@ -204,9 +208,9 @@ async function handleFindFirst(argv: Partial>, _prompter runtime: true, scaleMax: true, scaleMin: true, + system: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -247,6 +251,7 @@ async function handleGet(argv: Partial>, prompter: Inqui id: answers.id as string, select: { accessChannels: true, + billable: true, category: true, concurrency: true, createdAt: true, @@ -278,9 +283,9 @@ async function handleGet(argv: Partial>, prompter: Inqui runtime: true, scaleMax: true, scaleMin: true, + system: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -306,6 +311,13 @@ async function handleCreate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'boolean', + name: 'billable', + message: 'billable', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'category', @@ -507,6 +519,13 @@ async function handleCreate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'boolean', + name: 'system', + message: 'system', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'targetFunction', @@ -521,12 +540,6 @@ async function handleCreate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, - { - type: 'text', - name: 'taskIdentifier', - message: 'taskIdentifier', - required: true, - }, { type: 'text', name: 'timeoutSeconds', @@ -552,6 +565,7 @@ async function handleCreate(argv: Partial>, prompter: In .create({ data: { accessChannels: cleanedData.accessChannels, + billable: cleanedData.billable, category: cleanedData.category, concurrency: cleanedData.concurrency, description: cleanedData.description, @@ -581,14 +595,15 @@ async function handleCreate(argv: Partial>, prompter: In runtime: cleanedData.runtime, scaleMax: cleanedData.scaleMax, scaleMin: cleanedData.scaleMin, + system: cleanedData.system, targetFunction: cleanedData.targetFunction, targetSchema: cleanedData.targetSchema, - taskIdentifier: cleanedData.taskIdentifier, timeoutSeconds: cleanedData.timeoutSeconds, volatile: cleanedData.volatile, }, select: { accessChannels: true, + billable: true, category: true, concurrency: true, createdAt: true, @@ -620,9 +635,9 @@ async function handleCreate(argv: Partial>, prompter: In runtime: true, scaleMax: true, scaleMin: true, + system: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, @@ -654,6 +669,13 @@ async function handleUpdate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'boolean', + name: 'billable', + message: 'billable', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'category', @@ -855,6 +877,13 @@ async function handleUpdate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'boolean', + name: 'system', + message: 'system', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'targetFunction', @@ -869,12 +898,6 @@ async function handleUpdate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, - { - type: 'text', - name: 'taskIdentifier', - message: 'taskIdentifier', - required: false, - }, { type: 'text', name: 'timeoutSeconds', @@ -900,6 +923,7 @@ async function handleUpdate(argv: Partial>, prompter: In }, data: { accessChannels: cleanedData.accessChannels, + billable: cleanedData.billable, category: cleanedData.category, concurrency: cleanedData.concurrency, description: cleanedData.description, @@ -929,14 +953,15 @@ async function handleUpdate(argv: Partial>, prompter: In runtime: cleanedData.runtime, scaleMax: cleanedData.scaleMax, scaleMin: cleanedData.scaleMin, + system: cleanedData.system, targetFunction: cleanedData.targetFunction, targetSchema: cleanedData.targetSchema, - taskIdentifier: cleanedData.taskIdentifier, timeoutSeconds: cleanedData.timeoutSeconds, volatile: cleanedData.volatile, }, select: { accessChannels: true, + billable: true, category: true, concurrency: true, createdAt: true, @@ -968,9 +993,9 @@ async function handleUpdate(argv: Partial>, prompter: In runtime: true, scaleMax: true, scaleMin: true, + system: true, targetFunction: true, targetSchema: true, - taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true, diff --git a/sdk/constructive-cli/src/compute/cli/commands/platform-function-invocation-attempt.ts b/sdk/constructive-cli/src/compute/cli/commands/platform-function-invocation-attempt.ts new file mode 100644 index 000000000..23f583f56 --- /dev/null +++ b/sdk/constructive-cli/src/compute/cli/commands/platform-function-invocation-attempt.ts @@ -0,0 +1,474 @@ +/** + * CLI commands for PlatformFunctionInvocationAttempt + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreatePlatformFunctionInvocationAttemptInput, + PlatformFunctionInvocationAttemptPatch, + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + actorId: 'uuid', + attempt: 'int', + createdAt: 'string', + durationMs: 'int', + error: 'string', + errorDetail: 'json', + id: 'uuid', + invocationCreatedAt: 'string', + invocationId: 'uuid', + startedAt: 'string', + success: 'boolean', + taskIdentifier: 'string', +}; +const usage = + '\nplatform-function-invocation-attempt \n\nCommands:\n list List platformFunctionInvocationAttempt records\n find-first Find first matching platformFunctionInvocationAttempt record\n get Get a platformFunctionInvocationAttempt by ID\n create Create a new platformFunctionInvocationAttempt\n update Update an existing platformFunctionInvocationAttempt\n delete Delete a platformFunctionInvocationAttempt\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + actorId: true, + attempt: true, + createdAt: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: PlatformFunctionInvocationAttemptSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.platformFunctionInvocationAttempt.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + actorId: true, + attempt: true, + createdAt: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: PlatformFunctionInvocationAttemptSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.platformFunctionInvocationAttempt + .findFirst(findFirstArgs) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.platformFunctionInvocationAttempt + .findOne({ + id: answers.id as string, + select: { + actorId: true, + attempt: true, + createdAt: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'actorId', + message: 'actorId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'attempt', + message: 'attempt', + required: true, + }, + { + type: 'text', + name: 'durationMs', + message: 'durationMs', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'error', + message: 'error', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'errorDetail', + message: 'errorDetail', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'invocationCreatedAt', + message: 'invocationCreatedAt', + required: true, + }, + { + type: 'text', + name: 'invocationId', + message: 'invocationId', + required: true, + }, + { + type: 'text', + name: 'startedAt', + message: 'startedAt', + required: false, + skipPrompt: true, + }, + { + type: 'boolean', + name: 'success', + message: 'success', + required: true, + }, + { + type: 'text', + name: 'taskIdentifier', + message: 'taskIdentifier', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt']; + const client = getClient(); + const result = await client.platformFunctionInvocationAttempt + .create({ + data: { + actorId: cleanedData.actorId, + attempt: cleanedData.attempt, + durationMs: cleanedData.durationMs, + error: cleanedData.error, + errorDetail: cleanedData.errorDetail, + invocationCreatedAt: cleanedData.invocationCreatedAt, + invocationId: cleanedData.invocationId, + startedAt: cleanedData.startedAt, + success: cleanedData.success, + taskIdentifier: cleanedData.taskIdentifier, + }, + select: { + actorId: true, + attempt: true, + createdAt: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'createdAt', + message: 'createdAt', + required: true, + }, + { + type: 'text', + name: 'actorId', + message: 'actorId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'attempt', + message: 'attempt', + required: false, + }, + { + type: 'text', + name: 'durationMs', + message: 'durationMs', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'error', + message: 'error', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'errorDetail', + message: 'errorDetail', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'invocationCreatedAt', + message: 'invocationCreatedAt', + required: false, + }, + { + type: 'text', + name: 'invocationId', + message: 'invocationId', + required: false, + }, + { + type: 'text', + name: 'startedAt', + message: 'startedAt', + required: false, + skipPrompt: true, + }, + { + type: 'boolean', + name: 'success', + message: 'success', + required: false, + }, + { + type: 'text', + name: 'taskIdentifier', + message: 'taskIdentifier', + required: false, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as PlatformFunctionInvocationAttemptPatch; + const client = getClient(); + const result = await client.platformFunctionInvocationAttempt + .update({ + where: { + id: answers.id as string, + createdAt: answers.createdAt as string, + }, + data: { + actorId: cleanedData.actorId, + attempt: cleanedData.attempt, + durationMs: cleanedData.durationMs, + error: cleanedData.error, + errorDetail: cleanedData.errorDetail, + invocationCreatedAt: cleanedData.invocationCreatedAt, + invocationId: cleanedData.invocationId, + startedAt: cleanedData.startedAt, + success: cleanedData.success, + taskIdentifier: cleanedData.taskIdentifier, + }, + select: { + actorId: true, + attempt: true, + createdAt: true, + durationMs: true, + error: true, + errorDetail: true, + id: true, + invocationCreatedAt: true, + invocationId: true, + startedAt: true, + success: true, + taskIdentifier: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'createdAt', + message: 'createdAt', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.platformFunctionInvocationAttempt + .delete({ + where: { + id: answers.id as string, + createdAt: answers.createdAt as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/compute/cli/commands/declared-capacity.ts b/sdk/constructive-cli/src/compute/cli/commands/platform-resource-declared-capacity.ts similarity index 75% rename from sdk/constructive-cli/src/compute/cli/commands/declared-capacity.ts rename to sdk/constructive-cli/src/compute/cli/commands/platform-resource-declared-capacity.ts index 14c7eecd7..47b79a0b9 100644 --- a/sdk/constructive-cli/src/compute/cli/commands/declared-capacity.ts +++ b/sdk/constructive-cli/src/compute/cli/commands/platform-resource-declared-capacity.ts @@ -1,5 +1,5 @@ /** - * CLI commands for DeclaredCapacity + * CLI commands for PlatformResourceDeclaredCapacity * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -8,11 +8,11 @@ import { getClient } from '../executor'; import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; import type { FieldSchema } from '../utils'; import type { - CreateDeclaredCapacityInput, - DeclaredCapacityPatch, - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy, + CreatePlatformResourceDeclaredCapacityInput, + PlatformResourceDeclaredCapacityPatch, + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy, } from '../../orm/input-types'; import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { @@ -31,7 +31,7 @@ const fieldSchema: FieldSchema = { storageSizeBytes: 'int', }; const usage = - '\ndeclared-capacity \n\nCommands:\n list List declaredCapacity records\n find-first Find first matching declaredCapacity record\n create Create a new declaredCapacity\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; + '\nplatform-resource-declared-capacity \n\nCommands:\n list List platformResourceDeclaredCapacity records\n find-first Find first matching platformResourceDeclaredCapacity record\n create Create a new platformResourceDeclaredCapacity\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; export default async ( argv: Partial>, prompter: Inquirerer, @@ -90,12 +90,16 @@ async function handleList(argv: Partial>, _prompter: Inq storageSizeBytes: true, }; const findManyArgs = parseFindManyArgs< - FindManyArgs & { - select: DeclaredCapacitySelect; + FindManyArgs< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: PlatformResourceDeclaredCapacitySelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.declaredCapacity.findMany(findManyArgs).execute(); + const result = await client.platformResourceDeclaredCapacity.findMany(findManyArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to list records.'); @@ -123,12 +127,16 @@ async function handleFindFirst(argv: Partial>, _prompter storageSizeBytes: true, }; const findFirstArgs = parseFindFirstArgs< - FindFirstArgs & { - select: DeclaredCapacitySelect; + FindFirstArgs< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: PlatformResourceDeclaredCapacitySelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.declaredCapacity.findFirst(findFirstArgs).execute(); + const result = await client.platformResourceDeclaredCapacity.findFirst(findFirstArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to find record.'); @@ -224,9 +232,9 @@ async function handleCreate(argv: Partial>, prompter: In const cleanedData = stripUndefined( answers, fieldSchema - ) as CreateDeclaredCapacityInput['declaredCapacity']; + ) as CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity']; const client = getClient(); - const result = await client.declaredCapacity + const result = await client.platformResourceDeclaredCapacity .create({ data: { cpuLimitMillicores: cleanedData.cpuLimitMillicores, diff --git a/sdk/constructive-cli/src/compute/cli/commands/platform-resource-utilization-daily.ts b/sdk/constructive-cli/src/compute/cli/commands/platform-resource-utilization.ts similarity index 79% rename from sdk/constructive-cli/src/compute/cli/commands/platform-resource-utilization-daily.ts rename to sdk/constructive-cli/src/compute/cli/commands/platform-resource-utilization.ts index 1854488d9..9581ffc9f 100644 --- a/sdk/constructive-cli/src/compute/cli/commands/platform-resource-utilization-daily.ts +++ b/sdk/constructive-cli/src/compute/cli/commands/platform-resource-utilization.ts @@ -1,5 +1,5 @@ /** - * CLI commands for PlatformResourceUtilizationDaily + * CLI commands for PlatformResourceUtilization * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -8,11 +8,11 @@ import { getClient } from '../executor'; import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; import type { FieldSchema } from '../utils'; import type { - CreatePlatformResourceUtilizationDailyInput, - PlatformResourceUtilizationDailyPatch, - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy, + CreatePlatformResourceUtilizationInput, + PlatformResourceUtilizationPatch, + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy, } from '../../orm/input-types'; import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { @@ -37,7 +37,7 @@ const fieldSchema: FieldSchema = { sampleCount: 'int', }; const usage = - '\nplatform-resource-utilization-daily \n\nCommands:\n list List platformResourceUtilizationDaily records\n find-first Find first matching platformResourceUtilizationDaily record\n create Create a new platformResourceUtilizationDaily\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; + '\nplatform-resource-utilization \n\nCommands:\n list List platformResourceUtilization records\n find-first Find first matching platformResourceUtilization record\n create Create a new platformResourceUtilization\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; export default async ( argv: Partial>, prompter: Inquirerer, @@ -103,15 +103,15 @@ async function handleList(argv: Partial>, _prompter: Inq }; const findManyArgs = parseFindManyArgs< FindManyArgs< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy > & { - select: PlatformResourceUtilizationDailySelect; + select: PlatformResourceUtilizationSelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.platformResourceUtilizationDaily.findMany(findManyArgs).execute(); + const result = await client.platformResourceUtilization.findMany(findManyArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to list records.'); @@ -146,15 +146,15 @@ async function handleFindFirst(argv: Partial>, _prompter }; const findFirstArgs = parseFindFirstArgs< FindFirstArgs< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy > & { - select: PlatformResourceUtilizationDailySelect; + select: PlatformResourceUtilizationSelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.platformResourceUtilizationDaily.findFirst(findFirstArgs).execute(); + const result = await client.platformResourceUtilization.findFirst(findFirstArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to find record.'); @@ -286,9 +286,9 @@ async function handleCreate(argv: Partial>, prompter: In const cleanedData = stripUndefined( answers, fieldSchema - ) as CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily']; + ) as CreatePlatformResourceUtilizationInput['platformResourceUtilization']; const client = getClient(); - const result = await client.platformResourceUtilizationDaily + const result = await client.platformResourceUtilization .create({ data: { avgMemoryBytes: cleanedData.avgMemoryBytes, diff --git a/sdk/constructive-cli/src/compute/cli/commands/platform-declared-capacity.ts b/sdk/constructive-cli/src/compute/cli/commands/resource-declared-capacity.ts similarity index 88% rename from sdk/constructive-cli/src/compute/cli/commands/platform-declared-capacity.ts rename to sdk/constructive-cli/src/compute/cli/commands/resource-declared-capacity.ts index a9513e783..90de479b7 100644 --- a/sdk/constructive-cli/src/compute/cli/commands/platform-declared-capacity.ts +++ b/sdk/constructive-cli/src/compute/cli/commands/resource-declared-capacity.ts @@ -1,5 +1,5 @@ /** - * CLI commands for PlatformDeclaredCapacity + * CLI commands for ResourceDeclaredCapacity * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -8,11 +8,11 @@ import { getClient } from '../executor'; import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; import type { FieldSchema } from '../utils'; import type { - CreatePlatformDeclaredCapacityInput, - PlatformDeclaredCapacityPatch, - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy, + CreateResourceDeclaredCapacityInput, + ResourceDeclaredCapacityPatch, + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy, } from '../../orm/input-types'; import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { @@ -31,7 +31,7 @@ const fieldSchema: FieldSchema = { storageSizeBytes: 'int', }; const usage = - '\nplatform-declared-capacity \n\nCommands:\n list List platformDeclaredCapacity records\n find-first Find first matching platformDeclaredCapacity record\n create Create a new platformDeclaredCapacity\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; + '\nresource-declared-capacity \n\nCommands:\n list List resourceDeclaredCapacity records\n find-first Find first matching resourceDeclaredCapacity record\n create Create a new resourceDeclaredCapacity\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; export default async ( argv: Partial>, prompter: Inquirerer, @@ -91,15 +91,15 @@ async function handleList(argv: Partial>, _prompter: Inq }; const findManyArgs = parseFindManyArgs< FindManyArgs< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy > & { - select: PlatformDeclaredCapacitySelect; + select: ResourceDeclaredCapacitySelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.platformDeclaredCapacity.findMany(findManyArgs).execute(); + const result = await client.resourceDeclaredCapacity.findMany(findManyArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to list records.'); @@ -128,15 +128,15 @@ async function handleFindFirst(argv: Partial>, _prompter }; const findFirstArgs = parseFindFirstArgs< FindFirstArgs< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy > & { - select: PlatformDeclaredCapacitySelect; + select: ResourceDeclaredCapacitySelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.platformDeclaredCapacity.findFirst(findFirstArgs).execute(); + const result = await client.resourceDeclaredCapacity.findFirst(findFirstArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to find record.'); @@ -232,9 +232,9 @@ async function handleCreate(argv: Partial>, prompter: In const cleanedData = stripUndefined( answers, fieldSchema - ) as CreatePlatformDeclaredCapacityInput['platformDeclaredCapacity']; + ) as CreateResourceDeclaredCapacityInput['resourceDeclaredCapacity']; const client = getClient(); - const result = await client.platformDeclaredCapacity + const result = await client.resourceDeclaredCapacity .create({ data: { cpuLimitMillicores: cleanedData.cpuLimitMillicores, diff --git a/sdk/constructive-cli/src/compute/cli/commands/resource-utilization-daily.ts b/sdk/constructive-cli/src/compute/cli/commands/resource-utilization.ts similarity index 80% rename from sdk/constructive-cli/src/compute/cli/commands/resource-utilization-daily.ts rename to sdk/constructive-cli/src/compute/cli/commands/resource-utilization.ts index ba08a8675..bf9774472 100644 --- a/sdk/constructive-cli/src/compute/cli/commands/resource-utilization-daily.ts +++ b/sdk/constructive-cli/src/compute/cli/commands/resource-utilization.ts @@ -1,5 +1,5 @@ /** - * CLI commands for ResourceUtilizationDaily + * CLI commands for ResourceUtilization * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -8,11 +8,11 @@ import { getClient } from '../executor'; import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; import type { FieldSchema } from '../utils'; import type { - CreateResourceUtilizationDailyInput, - ResourceUtilizationDailyPatch, - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy, + CreateResourceUtilizationInput, + ResourceUtilizationPatch, + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy, } from '../../orm/input-types'; import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { @@ -37,7 +37,7 @@ const fieldSchema: FieldSchema = { sampleCount: 'int', }; const usage = - '\nresource-utilization-daily \n\nCommands:\n list List resourceUtilizationDaily records\n find-first Find first matching resourceUtilizationDaily record\n create Create a new resourceUtilizationDaily\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; + '\nresource-utilization \n\nCommands:\n list List resourceUtilization records\n find-first Find first matching resourceUtilization record\n create Create a new resourceUtilization\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; export default async ( argv: Partial>, prompter: Inquirerer, @@ -103,15 +103,15 @@ async function handleList(argv: Partial>, _prompter: Inq }; const findManyArgs = parseFindManyArgs< FindManyArgs< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy > & { - select: ResourceUtilizationDailySelect; + select: ResourceUtilizationSelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.resourceUtilizationDaily.findMany(findManyArgs).execute(); + const result = await client.resourceUtilization.findMany(findManyArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to list records.'); @@ -146,15 +146,15 @@ async function handleFindFirst(argv: Partial>, _prompter }; const findFirstArgs = parseFindFirstArgs< FindFirstArgs< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy > & { - select: ResourceUtilizationDailySelect; + select: ResourceUtilizationSelect; } >(argv, defaultSelect); const client = getClient(); - const result = await client.resourceUtilizationDaily.findFirst(findFirstArgs).execute(); + const result = await client.resourceUtilization.findFirst(findFirstArgs).execute(); console.log(JSON.stringify(result, null, 2)); } catch (error) { console.error('Failed to find record.'); @@ -286,9 +286,9 @@ async function handleCreate(argv: Partial>, prompter: In const cleanedData = stripUndefined( answers, fieldSchema - ) as CreateResourceUtilizationDailyInput['resourceUtilizationDaily']; + ) as CreateResourceUtilizationInput['resourceUtilization']; const client = getClient(); - const result = await client.resourceUtilizationDaily + const result = await client.resourceUtilization .create({ data: { avgMemoryBytes: cleanedData.avgMemoryBytes, diff --git a/sdk/constructive-cli/src/compute/orm/README.md b/sdk/constructive-cli/src/compute/orm/README.md index 1da2b6a29..c8d23ccd1 100644 --- a/sdk/constructive-cli/src/compute/orm/README.md +++ b/sdk/constructive-cli/src/compute/orm/README.md @@ -22,7 +22,6 @@ const db = createClient({ | Model | Operations | |-------|------------| | `dbPreset` | findMany, findOne, create, update, delete | -| `declaredCapacity` | findMany, findOne, create, update, delete | | `functionApiBinding` | findMany, findOne, create, update, delete | | `functionDefinition` | findMany, findOne, create, update, delete | | `functionDeployment` | findMany, findOne, create, update, delete | @@ -36,6 +35,7 @@ const db = createClient({ | `functionGraphObject` | findMany, findOne, create, update, delete | | `functionGraphRef` | findMany, findOne, create, update, delete | | `functionGraphStore` | findMany, findOne, create, update, delete | +| `functionInvocationAttempt` | findMany, findOne, create, update, delete | | `functionInvocation` | findMany, findOne, create, update, delete | | `getAllTreeNodesRecord` | findMany, findOne, create, update, delete | | `infraCommit` | findMany, findOne, create, update, delete | @@ -46,12 +46,12 @@ const db = createClient({ | `integrationProvider` | findMany, findOne, create, update, delete | | `namespace` | findMany, findOne, create, update, delete | | `namespaceEvent` | findMany, findOne, create, update, delete | -| `platformDeclaredCapacity` | findMany, findOne, create, update, delete | | `platformFunctionApiBinding` | findMany, findOne, create, update, delete | | `platformFunctionDefinition` | findMany, findOne, create, update, delete | | `platformFunctionDeployment` | findMany, findOne, create, update, delete | | `platformFunctionDeploymentEvent` | findMany, findOne, create, update, delete | | `platformFunctionExecutionLog` | findMany, findOne, create, update, delete | +| `platformFunctionInvocationAttempt` | findMany, findOne, create, update, delete | | `platformFunctionInvocation` | findMany, findOne, create, update, delete | | `platformInfraCommit` | findMany, findOne, create, update, delete | | `platformInfraGetAllTreeNodesRecord` | findMany, findOne, create, update, delete | @@ -61,26 +61,28 @@ const db = createClient({ | `platformNamespace` | findMany, findOne, create, update, delete | | `platformNamespaceEvent` | findMany, findOne, create, update, delete | | `platformResource` | findMany, findOne, create, update, delete | +| `platformResourceDeclaredCapacity` | findMany, findOne, create, update, delete | | `platformResourceDefinition` | findMany, findOne, create, update, delete | | `platformResourceEvent` | findMany, findOne, create, update, delete | | `platformResourceInstallation` | findMany, findOne, create, update, delete | | `platformResourceStatusCheck` | findMany, findOne, create, update, delete | | `platformResourceUsageLog` | findMany, findOne, create, update, delete | | `platformResourceUsageSummary` | findMany, findOne, create, update, delete | -| `platformResourceUtilizationDaily` | findMany, findOne, create, update, delete | +| `platformResourceUtilization` | findMany, findOne, create, update, delete | | `platformResourcesHealth` | findMany, findOne, create, update, delete | | `platformResourcesRequirementsState` | findMany, findOne, create, update, delete | | `platformResourcesResolvedRequirement` | findMany, findOne, create, update, delete | | `platformWebhookEndpoint` | findMany, findOne, create, update, delete | | `platformWebhookEvent` | findMany, findOne, create, update, delete | | `resource` | findMany, findOne, create, update, delete | +| `resourceDeclaredCapacity` | findMany, findOne, create, update, delete | | `resourceDefinition` | findMany, findOne, create, update, delete | | `resourceEvent` | findMany, findOne, create, update, delete | | `resourceInstallation` | findMany, findOne, create, update, delete | | `resourceStatusCheck` | findMany, findOne, create, update, delete | | `resourceUsageLog` | findMany, findOne, create, update, delete | | `resourceUsageSummary` | findMany, findOne, create, update, delete | -| `resourceUtilizationDaily` | findMany, findOne, create, update, delete | +| `resourceUtilization` | findMany, findOne, create, update, delete | | `resourcesHealth` | findMany, findOne, create, update, delete | | `resourcesRequirementsState` | findMany, findOne, create, update, delete | | `resourcesResolvedRequirement` | findMany, findOne, create, update, delete | @@ -128,47 +130,6 @@ const updated = await db.dbPreset.update({ where: { id: '' }, data: { acti const deleted = await db.dbPreset.delete({ where: { id: '' } }).execute(); ``` -### `db.declaredCapacity` - -CRUD operations for DeclaredCapacity records. - -**Fields:** - -| Field | Type | Editable | -|-------|------|----------| -| `cpuLimitMillicores` | BigInt | Yes | -| `cpuRequestMillicores` | BigInt | Yes | -| `installationId` | UUID | Yes | -| `isTransient` | Boolean | Yes | -| `kind` | String | Yes | -| `memoryLimitBytes` | BigInt | Yes | -| `memoryRequestBytes` | BigInt | Yes | -| `namespaceId` | UUID | Yes | -| `podCountMax` | Int | Yes | -| `podCountMin` | Int | Yes | -| `source` | String | Yes | -| `sourceId` | UUID | Yes | -| `storageSizeBytes` | BigInt | Yes | - -**Operations:** - -```typescript -// List all declaredCapacity records -const items = await db.declaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Get one by id -const item = await db.declaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Create -const created = await db.declaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); - -// Update -const updated = await db.declaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); - -// Delete -const deleted = await db.declaredCapacity.delete({ where: { id: '' } }).execute(); -``` - ### `db.functionApiBinding` CRUD operations for FunctionApiBinding records. @@ -709,6 +670,47 @@ const updated = await db.functionGraphStore.update({ where: { id: '' }, da const deleted = await db.functionGraphStore.delete({ where: { id: '' } }).execute(); ``` +### `db.functionInvocationAttempt` + +CRUD operations for FunctionInvocationAttempt records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `attempt` | Int | Yes | +| `createdAt` | Datetime | No | +| `databaseId` | UUID | Yes | +| `durationMs` | Int | Yes | +| `error` | String | Yes | +| `errorDetail` | JSON | Yes | +| `id` | UUID | No | +| `invocationCreatedAt` | Datetime | Yes | +| `invocationId` | UUID | Yes | +| `startedAt` | Datetime | Yes | +| `success` | Boolean | Yes | +| `taskIdentifier` | String | Yes | + +**Operations:** + +```typescript +// List all functionInvocationAttempt records +const items = await db.functionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Get one by id +const item = await db.functionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Create +const created = await db.functionInvocationAttempt.create({ data: { actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.functionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.functionInvocationAttempt.delete({ where: { id: '' } }).execute(); +``` + ### `db.functionInvocation` CRUD operations for FunctionInvocation records. @@ -1071,47 +1073,6 @@ const updated = await db.namespaceEvent.update({ where: { id: '' }, data: const deleted = await db.namespaceEvent.delete({ where: { id: '' } }).execute(); ``` -### `db.platformDeclaredCapacity` - -CRUD operations for PlatformDeclaredCapacity records. - -**Fields:** - -| Field | Type | Editable | -|-------|------|----------| -| `cpuLimitMillicores` | BigInt | Yes | -| `cpuRequestMillicores` | BigInt | Yes | -| `installationId` | UUID | Yes | -| `isTransient` | Boolean | Yes | -| `kind` | String | Yes | -| `memoryLimitBytes` | BigInt | Yes | -| `memoryRequestBytes` | BigInt | Yes | -| `namespaceId` | UUID | Yes | -| `podCountMax` | Int | Yes | -| `podCountMin` | Int | Yes | -| `source` | String | Yes | -| `sourceId` | UUID | Yes | -| `storageSizeBytes` | BigInt | Yes | - -**Operations:** - -```typescript -// List all platformDeclaredCapacity records -const items = await db.platformDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Get one by id -const item = await db.platformDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Create -const created = await db.platformDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); - -// Update -const updated = await db.platformDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); - -// Delete -const deleted = await db.platformDeclaredCapacity.delete({ where: { id: '' } }).execute(); -``` - ### `db.platformFunctionApiBinding` CRUD operations for PlatformFunctionApiBinding records. @@ -1154,6 +1115,7 @@ CRUD operations for PlatformFunctionDefinition records. | Field | Type | Editable | |-------|------|----------| | `accessChannels` | String | Yes | +| `billable` | Boolean | Yes | | `category` | String | Yes | | `concurrency` | Int | Yes | | `cpuLimitMillicores` | BigInt | Yes | @@ -1189,6 +1151,7 @@ CRUD operations for PlatformFunctionDefinition records. | `runtime` | String | Yes | | `scaleMax` | Int | Yes | | `scaleMin` | Int | Yes | +| `system` | Boolean | Yes | | `targetFunction` | String | Yes | | `targetSchema` | String | Yes | | `taskIdentifier` | String | Yes | @@ -1200,13 +1163,13 @@ CRUD operations for PlatformFunctionDefinition records. ```typescript // List all platformFunctionDefinition records -const items = await db.platformFunctionDefinition.findMany({ select: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); +const items = await db.platformFunctionDefinition.findMany({ select: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); // Get one by id -const item = await db.platformFunctionDefinition.findOne({ id: '', select: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); +const item = await db.platformFunctionDefinition.findOne({ id: '', select: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); // Create -const created = await db.platformFunctionDefinition.create({ data: { accessChannels: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute(); +const created = await db.platformFunctionDefinition.create({ data: { accessChannels: '', billable: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionDefinition.update({ where: { id: '' }, data: { accessChannels: '' }, select: { id: true } }).execute(); @@ -1335,6 +1298,46 @@ const updated = await db.platformFunctionExecutionLog.update({ where: { id: '' } }).execute(); ``` +### `db.platformFunctionInvocationAttempt` + +CRUD operations for PlatformFunctionInvocationAttempt records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `attempt` | Int | Yes | +| `createdAt` | Datetime | No | +| `durationMs` | Int | Yes | +| `error` | String | Yes | +| `errorDetail` | JSON | Yes | +| `id` | UUID | No | +| `invocationCreatedAt` | Datetime | Yes | +| `invocationId` | UUID | Yes | +| `startedAt` | Datetime | Yes | +| `success` | Boolean | Yes | +| `taskIdentifier` | String | Yes | + +**Operations:** + +```typescript +// List all platformFunctionInvocationAttempt records +const items = await db.platformFunctionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Get one by id +const item = await db.platformFunctionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Create +const created = await db.platformFunctionInvocationAttempt.create({ data: { actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.platformFunctionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.platformFunctionInvocationAttempt.delete({ where: { id: '' } }).execute(); +``` + ### `db.platformFunctionInvocation` CRUD operations for PlatformFunctionInvocation records. @@ -1681,6 +1684,47 @@ const updated = await db.platformResource.update({ where: { id: '' }, data const deleted = await db.platformResource.delete({ where: { id: '' } }).execute(); ``` +### `db.platformResourceDeclaredCapacity` + +CRUD operations for PlatformResourceDeclaredCapacity records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `cpuLimitMillicores` | BigInt | Yes | +| `cpuRequestMillicores` | BigInt | Yes | +| `installationId` | UUID | Yes | +| `isTransient` | Boolean | Yes | +| `kind` | String | Yes | +| `memoryLimitBytes` | BigInt | Yes | +| `memoryRequestBytes` | BigInt | Yes | +| `namespaceId` | UUID | Yes | +| `podCountMax` | Int | Yes | +| `podCountMin` | Int | Yes | +| `source` | String | Yes | +| `sourceId` | UUID | Yes | +| `storageSizeBytes` | BigInt | Yes | + +**Operations:** + +```typescript +// List all platformResourceDeclaredCapacity records +const items = await db.platformResourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Get one by id +const item = await db.platformResourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Create +const created = await db.platformResourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.platformResourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.platformResourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); +``` + ### `db.platformResourceDefinition` CRUD operations for PlatformResourceDefinition records. @@ -1911,9 +1955,9 @@ const updated = await db.platformResourceUsageSummary.update({ where: { id: '' } }).execute(); ``` -### `db.platformResourceUtilizationDaily` +### `db.platformResourceUtilization` -CRUD operations for PlatformResourceUtilizationDaily records. +CRUD operations for PlatformResourceUtilization records. **Fields:** @@ -1942,20 +1986,20 @@ CRUD operations for PlatformResourceUtilizationDaily records. **Operations:** ```typescript -// List all platformResourceUtilizationDaily records -const items = await db.platformResourceUtilizationDaily.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +// List all platformResourceUtilization records +const items = await db.platformResourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id -const item = await db.platformResourceUtilizationDaily.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +const item = await db.platformResourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create -const created = await db.platformResourceUtilizationDaily.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); +const created = await db.platformResourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update -const updated = await db.platformResourceUtilizationDaily.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); +const updated = await db.platformResourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete -const deleted = await db.platformResourceUtilizationDaily.delete({ where: { id: '' } }).execute(); +const deleted = await db.platformResourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourcesHealth` @@ -2228,6 +2272,47 @@ const updated = await db.resource.update({ where: { id: '' }, data: { anno const deleted = await db.resource.delete({ where: { id: '' } }).execute(); ``` +### `db.resourceDeclaredCapacity` + +CRUD operations for ResourceDeclaredCapacity records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `cpuLimitMillicores` | BigInt | Yes | +| `cpuRequestMillicores` | BigInt | Yes | +| `installationId` | UUID | Yes | +| `isTransient` | Boolean | Yes | +| `kind` | String | Yes | +| `memoryLimitBytes` | BigInt | Yes | +| `memoryRequestBytes` | BigInt | Yes | +| `namespaceId` | UUID | Yes | +| `podCountMax` | Int | Yes | +| `podCountMin` | Int | Yes | +| `source` | String | Yes | +| `sourceId` | UUID | Yes | +| `storageSizeBytes` | BigInt | Yes | + +**Operations:** + +```typescript +// List all resourceDeclaredCapacity records +const items = await db.resourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Get one by id +const item = await db.resourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Create +const created = await db.resourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.resourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.resourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); +``` + ### `db.resourceDefinition` CRUD operations for ResourceDefinition records. @@ -2464,9 +2549,9 @@ const updated = await db.resourceUsageSummary.update({ where: { id: '' }, const deleted = await db.resourceUsageSummary.delete({ where: { id: '' } }).execute(); ``` -### `db.resourceUtilizationDaily` +### `db.resourceUtilization` -CRUD operations for ResourceUtilizationDaily records. +CRUD operations for ResourceUtilization records. **Fields:** @@ -2495,20 +2580,20 @@ CRUD operations for ResourceUtilizationDaily records. **Operations:** ```typescript -// List all resourceUtilizationDaily records -const items = await db.resourceUtilizationDaily.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +// List all resourceUtilization records +const items = await db.resourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id -const item = await db.resourceUtilizationDaily.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +const item = await db.resourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create -const created = await db.resourceUtilizationDaily.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); +const created = await db.resourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update -const updated = await db.resourceUtilizationDaily.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); +const updated = await db.resourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete -const deleted = await db.resourceUtilizationDaily.delete({ where: { id: '' } }).execute(); +const deleted = await db.resourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.resourcesHealth` @@ -2980,7 +3065,7 @@ platformResourceInstallationsInstall | `input` | PlatformResourceInstallationsInstallInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsRollback` @@ -2995,7 +3080,7 @@ platformResourceInstallationsRollback | `input` | PlatformResourceInstallationsRollbackInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUninstall` @@ -3010,7 +3095,7 @@ platformResourceInstallationsUninstall | `input` | PlatformResourceInstallationsUninstallInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUpgrade` @@ -3025,7 +3110,7 @@ platformResourceInstallationsUpgrade | `input` | PlatformResourceInstallationsUpgradeInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.provisionBucket` @@ -3058,7 +3143,7 @@ resourceInstallationsInstall | `input` | ResourceInstallationsInstallInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.resourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsRollback` @@ -3073,7 +3158,7 @@ resourceInstallationsRollback | `input` | ResourceInstallationsRollbackInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUninstall` @@ -3088,7 +3173,7 @@ resourceInstallationsUninstall | `input` | ResourceInstallationsUninstallInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUpgrade` @@ -3103,7 +3188,7 @@ resourceInstallationsUpgrade | `input` | ResourceInstallationsUpgradeInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.saveGraph` diff --git a/sdk/constructive-cli/src/compute/orm/index.ts b/sdk/constructive-cli/src/compute/orm/index.ts index 979783107..933b08ed3 100644 --- a/sdk/constructive-cli/src/compute/orm/index.ts +++ b/sdk/constructive-cli/src/compute/orm/index.ts @@ -6,7 +6,6 @@ import { OrmClient } from './client'; import type { OrmClientConfig } from './client'; import { DbPresetModel } from './models/dbPreset'; -import { DeclaredCapacityModel } from './models/declaredCapacity'; import { FunctionApiBindingModel } from './models/functionApiBinding'; import { FunctionDefinitionModel } from './models/functionDefinition'; import { FunctionDeploymentModel } from './models/functionDeployment'; @@ -20,6 +19,7 @@ import { FunctionGraphExecutionOutputModel } from './models/functionGraphExecuti import { FunctionGraphObjectModel } from './models/functionGraphObject'; import { FunctionGraphRefModel } from './models/functionGraphRef'; import { FunctionGraphStoreModel } from './models/functionGraphStore'; +import { FunctionInvocationAttemptModel } from './models/functionInvocationAttempt'; import { FunctionInvocationModel } from './models/functionInvocation'; import { GetAllTreeNodesRecordModel } from './models/getAllTreeNodesRecord'; import { InfraCommitModel } from './models/infraCommit'; @@ -30,12 +30,12 @@ import { InfraStoreModel } from './models/infraStore'; import { IntegrationProviderModel } from './models/integrationProvider'; import { NamespaceModel } from './models/namespace'; import { NamespaceEventModel } from './models/namespaceEvent'; -import { PlatformDeclaredCapacityModel } from './models/platformDeclaredCapacity'; import { PlatformFunctionApiBindingModel } from './models/platformFunctionApiBinding'; import { PlatformFunctionDefinitionModel } from './models/platformFunctionDefinition'; import { PlatformFunctionDeploymentModel } from './models/platformFunctionDeployment'; import { PlatformFunctionDeploymentEventModel } from './models/platformFunctionDeploymentEvent'; import { PlatformFunctionExecutionLogModel } from './models/platformFunctionExecutionLog'; +import { PlatformFunctionInvocationAttemptModel } from './models/platformFunctionInvocationAttempt'; import { PlatformFunctionInvocationModel } from './models/platformFunctionInvocation'; import { PlatformInfraCommitModel } from './models/platformInfraCommit'; import { PlatformInfraGetAllTreeNodesRecordModel } from './models/platformInfraGetAllTreeNodesRecord'; @@ -45,26 +45,28 @@ import { PlatformInfraStoreModel } from './models/platformInfraStore'; import { PlatformNamespaceModel } from './models/platformNamespace'; import { PlatformNamespaceEventModel } from './models/platformNamespaceEvent'; import { PlatformResourceModel } from './models/platformResource'; +import { PlatformResourceDeclaredCapacityModel } from './models/platformResourceDeclaredCapacity'; import { PlatformResourceDefinitionModel } from './models/platformResourceDefinition'; import { PlatformResourceEventModel } from './models/platformResourceEvent'; import { PlatformResourceInstallationModel } from './models/platformResourceInstallation'; import { PlatformResourceStatusCheckModel } from './models/platformResourceStatusCheck'; import { PlatformResourceUsageLogModel } from './models/platformResourceUsageLog'; import { PlatformResourceUsageSummaryModel } from './models/platformResourceUsageSummary'; -import { PlatformResourceUtilizationDailyModel } from './models/platformResourceUtilizationDaily'; +import { PlatformResourceUtilizationModel } from './models/platformResourceUtilization'; import { PlatformResourcesHealthModel } from './models/platformResourcesHealth'; import { PlatformResourcesRequirementsStateModel } from './models/platformResourcesRequirementsState'; import { PlatformResourcesResolvedRequirementModel } from './models/platformResourcesResolvedRequirement'; import { PlatformWebhookEndpointModel } from './models/platformWebhookEndpoint'; import { PlatformWebhookEventModel } from './models/platformWebhookEvent'; import { ResourceModel } from './models/resource'; +import { ResourceDeclaredCapacityModel } from './models/resourceDeclaredCapacity'; import { ResourceDefinitionModel } from './models/resourceDefinition'; import { ResourceEventModel } from './models/resourceEvent'; import { ResourceInstallationModel } from './models/resourceInstallation'; import { ResourceStatusCheckModel } from './models/resourceStatusCheck'; import { ResourceUsageLogModel } from './models/resourceUsageLog'; import { ResourceUsageSummaryModel } from './models/resourceUsageSummary'; -import { ResourceUtilizationDailyModel } from './models/resourceUtilizationDaily'; +import { ResourceUtilizationModel } from './models/resourceUtilization'; import { ResourcesHealthModel } from './models/resourcesHealth'; import { ResourcesRequirementsStateModel } from './models/resourcesRequirementsState'; import { ResourcesResolvedRequirementModel } from './models/resourcesResolvedRequirement'; @@ -106,7 +108,6 @@ export function createClient(config: OrmClientConfig) { const client = new OrmClient(config); return { dbPreset: new DbPresetModel(client), - declaredCapacity: new DeclaredCapacityModel(client), functionApiBinding: new FunctionApiBindingModel(client), functionDefinition: new FunctionDefinitionModel(client), functionDeployment: new FunctionDeploymentModel(client), @@ -120,6 +121,7 @@ export function createClient(config: OrmClientConfig) { functionGraphObject: new FunctionGraphObjectModel(client), functionGraphRef: new FunctionGraphRefModel(client), functionGraphStore: new FunctionGraphStoreModel(client), + functionInvocationAttempt: new FunctionInvocationAttemptModel(client), functionInvocation: new FunctionInvocationModel(client), getAllTreeNodesRecord: new GetAllTreeNodesRecordModel(client), infraCommit: new InfraCommitModel(client), @@ -130,12 +132,12 @@ export function createClient(config: OrmClientConfig) { integrationProvider: new IntegrationProviderModel(client), namespace: new NamespaceModel(client), namespaceEvent: new NamespaceEventModel(client), - platformDeclaredCapacity: new PlatformDeclaredCapacityModel(client), platformFunctionApiBinding: new PlatformFunctionApiBindingModel(client), platformFunctionDefinition: new PlatformFunctionDefinitionModel(client), platformFunctionDeployment: new PlatformFunctionDeploymentModel(client), platformFunctionDeploymentEvent: new PlatformFunctionDeploymentEventModel(client), platformFunctionExecutionLog: new PlatformFunctionExecutionLogModel(client), + platformFunctionInvocationAttempt: new PlatformFunctionInvocationAttemptModel(client), platformFunctionInvocation: new PlatformFunctionInvocationModel(client), platformInfraCommit: new PlatformInfraCommitModel(client), platformInfraGetAllTreeNodesRecord: new PlatformInfraGetAllTreeNodesRecordModel(client), @@ -145,26 +147,28 @@ export function createClient(config: OrmClientConfig) { platformNamespace: new PlatformNamespaceModel(client), platformNamespaceEvent: new PlatformNamespaceEventModel(client), platformResource: new PlatformResourceModel(client), + platformResourceDeclaredCapacity: new PlatformResourceDeclaredCapacityModel(client), platformResourceDefinition: new PlatformResourceDefinitionModel(client), platformResourceEvent: new PlatformResourceEventModel(client), platformResourceInstallation: new PlatformResourceInstallationModel(client), platformResourceStatusCheck: new PlatformResourceStatusCheckModel(client), platformResourceUsageLog: new PlatformResourceUsageLogModel(client), platformResourceUsageSummary: new PlatformResourceUsageSummaryModel(client), - platformResourceUtilizationDaily: new PlatformResourceUtilizationDailyModel(client), + platformResourceUtilization: new PlatformResourceUtilizationModel(client), platformResourcesHealth: new PlatformResourcesHealthModel(client), platformResourcesRequirementsState: new PlatformResourcesRequirementsStateModel(client), platformResourcesResolvedRequirement: new PlatformResourcesResolvedRequirementModel(client), platformWebhookEndpoint: new PlatformWebhookEndpointModel(client), platformWebhookEvent: new PlatformWebhookEventModel(client), resource: new ResourceModel(client), + resourceDeclaredCapacity: new ResourceDeclaredCapacityModel(client), resourceDefinition: new ResourceDefinitionModel(client), resourceEvent: new ResourceEventModel(client), resourceInstallation: new ResourceInstallationModel(client), resourceStatusCheck: new ResourceStatusCheckModel(client), resourceUsageLog: new ResourceUsageLogModel(client), resourceUsageSummary: new ResourceUsageSummaryModel(client), - resourceUtilizationDaily: new ResourceUtilizationDailyModel(client), + resourceUtilization: new ResourceUtilizationModel(client), resourcesHealth: new ResourcesHealthModel(client), resourcesRequirementsState: new ResourcesRequirementsStateModel(client), resourcesResolvedRequirement: new ResourcesResolvedRequirementModel(client), diff --git a/sdk/constructive-cli/src/compute/orm/input-types.ts b/sdk/constructive-cli/src/compute/orm/input-types.ts index 676843824..6ff018412 100644 --- a/sdk/constructive-cli/src/compute/orm/input-types.ts +++ b/sdk/constructive-cli/src/compute/orm/input-types.ts @@ -260,21 +260,6 @@ export interface DbPreset { /** Timestamp of last modification */ updatedAt?: string | null; } -export interface DeclaredCapacity { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} /** Join table binding function definitions to API endpoints with per-binding alias and config */ export interface FunctionApiBinding { /** Binding alias (e.g. default, staging, production) */ @@ -365,7 +350,7 @@ export interface FunctionDefinition { targetFunction?: string | null; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string | null; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ + /** Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) */ taskIdentifier?: string | null; /** Knative request timeout in seconds */ timeoutSeconds?: number | null; @@ -659,6 +644,35 @@ export interface FunctionGraphStore { /** Opaque store partition key for the global tier */ scopeId?: string | null; } +/** Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail */ +export interface FunctionInvocationAttempt { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string | null; + /** 1-based attempt number for this invocation */ + attempt?: number | null; + /** When the attempt result was recorded (partition key) */ + createdAt?: string | null; + /** Database that owns this resource (database-scoped isolation) */ + databaseId?: string | null; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number | null; + /** Error message when the attempt failed */ + error?: string | null; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record | null; + /** Unique attempt identifier */ + id: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string | null; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string | null; + /** When the attempt began executing */ + startedAt?: string | null; + /** Whether this attempt completed successfully */ + success?: boolean | null; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string | null; +} /** Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. */ export interface FunctionInvocation { /** Who triggered the invocation (NULL for system/cron) */ @@ -677,7 +691,7 @@ export interface FunctionInvocation { definitionScope?: string | null; /** Wall-clock execution time in milliseconds */ durationMs?: number | null; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string | null; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string | null; @@ -697,7 +711,7 @@ export interface FunctionInvocation { result?: Record | null; /** When execution started */ startedAt?: string | null; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string | null; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string | null; @@ -841,21 +855,6 @@ export interface NamespaceEvent { /** Namespace this event belongs to */ namespaceId?: string | null; } -export interface PlatformDeclaredCapacity { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} /** Join table binding function definitions to API endpoints with per-binding alias and config */ export interface PlatformFunctionApiBinding { /** Binding alias (e.g. default, staging, production) */ @@ -872,6 +871,8 @@ export interface PlatformFunctionApiBinding { export interface PlatformFunctionDefinition { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[] | null; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean | null; /** Function task category (e.g. email, embed, chunk, custom) */ category?: string | null; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -940,11 +941,13 @@ export interface PlatformFunctionDefinition { scaleMax?: number | null; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number | null; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean | null; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string | null; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string | null; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ + /** Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) */ taskIdentifier?: string | null; /** Knative request timeout in seconds */ timeoutSeconds?: number | null; @@ -1030,6 +1033,33 @@ export interface PlatformFunctionExecutionLog { /** Function routing key (NULL for generic job logs) */ taskIdentifier?: string | null; } +/** Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail */ +export interface PlatformFunctionInvocationAttempt { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string | null; + /** 1-based attempt number for this invocation */ + attempt?: number | null; + /** When the attempt result was recorded (partition key) */ + createdAt?: string | null; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number | null; + /** Error message when the attempt failed */ + error?: string | null; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record | null; + /** Unique attempt identifier */ + id: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string | null; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string | null; + /** When the attempt began executing */ + startedAt?: string | null; + /** Whether this attempt completed successfully */ + success?: boolean | null; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string | null; +} /** Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. */ export interface PlatformFunctionInvocation { /** Who triggered the invocation (NULL for system/cron) */ @@ -1046,7 +1076,7 @@ export interface PlatformFunctionInvocation { definitionScope?: string | null; /** Wall-clock execution time in milliseconds */ durationMs?: number | null; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string | null; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string | null; @@ -1066,7 +1096,7 @@ export interface PlatformFunctionInvocation { result?: Record | null; /** When execution started */ startedAt?: string | null; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string | null; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string | null; @@ -1195,7 +1225,7 @@ export interface PlatformResource { installationId?: string | null; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string | null; /** Key/value pairs for selecting and filtering resources */ labels?: Record | null; @@ -1234,6 +1264,21 @@ export interface PlatformResource { updatedAt?: string | null; updatedBy?: string | null; } +export interface PlatformResourceDeclaredCapacity { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} /** Resource definitions — templates for resource kinds declaring default spec and secret/config requirements */ export interface PlatformResourceDefinition { /** Freeform metadata for tooling and operational notes */ @@ -1247,7 +1292,7 @@ export interface PlatformResourceDefinition { id: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string | null; /** Key/value pairs for selecting and filtering definitions */ labels?: Record | null; @@ -1324,7 +1369,7 @@ export interface PlatformResourceStatusCheck { /** Check lifecycle: pending, running, completed, failed */ status?: string | null; } -/** Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) */ +/** Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) */ export interface PlatformResourceUsageLog { /** CPU gauge in millicores at sample time (NULL when unknown) */ cpuMillicores?: string | null; @@ -1342,7 +1387,7 @@ export interface PlatformResourceUsageLog { resourceId?: string | null; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string | null; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string | null; } /** Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals */ @@ -1366,7 +1411,7 @@ export interface PlatformResourceUsageSummary { /** Number of raw samples aggregated into this summary */ sampleCount?: number | null; } -export interface PlatformResourceUtilizationDaily { +export interface PlatformResourceUtilization { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -1507,7 +1552,7 @@ export interface Resource { installationId?: string | null; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string | null; /** Key/value pairs for selecting and filtering resources */ labels?: Record | null; @@ -1546,6 +1591,21 @@ export interface Resource { updatedAt?: string | null; updatedBy?: string | null; } +export interface ResourceDeclaredCapacity { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} /** Resource definitions — templates for resource kinds declaring default spec and secret/config requirements */ export interface ResourceDefinition { /** Freeform metadata for tooling and operational notes */ @@ -1561,7 +1621,7 @@ export interface ResourceDefinition { id: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string | null; /** Key/value pairs for selecting and filtering definitions */ labels?: Record | null; @@ -1644,7 +1704,7 @@ export interface ResourceStatusCheck { /** Check lifecycle: pending, running, completed, failed */ status?: string | null; } -/** Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) */ +/** Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) */ export interface ResourceUsageLog { /** CPU gauge in millicores at sample time (NULL when unknown) */ cpuMillicores?: string | null; @@ -1664,7 +1724,7 @@ export interface ResourceUsageLog { resourceId?: string | null; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string | null; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string | null; } /** Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals */ @@ -1690,7 +1750,7 @@ export interface ResourceUsageSummary { /** Number of raw samples aggregated into this summary */ sampleCount?: number | null; } -export interface ResourceUtilizationDaily { +export interface ResourceUtilization { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -1831,7 +1891,6 @@ export interface PageInfo { } // ============ Entity Relation Types ============ export interface DbPresetRelations {} -export interface DeclaredCapacityRelations {} export interface FunctionApiBindingRelations { functionDefinition?: FunctionDefinition | null; functionInvocationsByApiBindingId?: ConnectionResult; @@ -1858,6 +1917,7 @@ export interface FunctionGraphExecutionOutputRelations {} export interface FunctionGraphObjectRelations {} export interface FunctionGraphRefRelations {} export interface FunctionGraphStoreRelations {} +export interface FunctionInvocationAttemptRelations {} export interface FunctionInvocationRelations { apiBinding?: FunctionApiBinding | null; } @@ -1876,7 +1936,6 @@ export interface NamespaceRelations { webhookEndpoints?: ConnectionResult; } export interface NamespaceEventRelations {} -export interface PlatformDeclaredCapacityRelations {} export interface PlatformFunctionApiBindingRelations { functionDefinition?: PlatformFunctionDefinition | null; platformFunctionInvocationsByApiBindingId?: ConnectionResult; @@ -1891,6 +1950,7 @@ export interface PlatformFunctionDeploymentRelations { } export interface PlatformFunctionDeploymentEventRelations {} export interface PlatformFunctionExecutionLogRelations {} +export interface PlatformFunctionInvocationAttemptRelations {} export interface PlatformFunctionInvocationRelations { apiBinding?: PlatformFunctionApiBinding | null; } @@ -1913,6 +1973,7 @@ export interface PlatformResourceRelations { resourceDefinition?: PlatformResourceDefinition | null; platformResourceStatusChecksByResourceId?: ConnectionResult; } +export interface PlatformResourceDeclaredCapacityRelations {} export interface PlatformResourceDefinitionRelations { namespace?: PlatformNamespace | null; platformResourcesByResourceDefinitionId?: ConnectionResult; @@ -1927,7 +1988,7 @@ export interface PlatformResourceStatusCheckRelations { } export interface PlatformResourceUsageLogRelations {} export interface PlatformResourceUsageSummaryRelations {} -export interface PlatformResourceUtilizationDailyRelations {} +export interface PlatformResourceUtilizationRelations {} export interface PlatformResourcesHealthRelations {} export interface PlatformResourcesRequirementsStateRelations {} export interface PlatformResourcesResolvedRequirementRelations {} @@ -1945,6 +2006,7 @@ export interface ResourceRelations { resourceDefinition?: ResourceDefinition | null; resourceStatusChecks?: ConnectionResult; } +export interface ResourceDeclaredCapacityRelations {} export interface ResourceDefinitionRelations { namespace?: Namespace | null; resources?: ConnectionResult; @@ -1959,7 +2021,7 @@ export interface ResourceStatusCheckRelations { } export interface ResourceUsageLogRelations {} export interface ResourceUsageSummaryRelations {} -export interface ResourceUtilizationDailyRelations {} +export interface ResourceUtilizationRelations {} export interface ResourcesHealthRelations {} export interface ResourcesRequirementsStateRelations {} export interface ResourcesResolvedRequirementRelations {} @@ -1973,7 +2035,6 @@ export interface WebhookEventRelations { } // ============ Entity Types With Relations ============ export type DbPresetWithRelations = DbPreset & DbPresetRelations; -export type DeclaredCapacityWithRelations = DeclaredCapacity & DeclaredCapacityRelations; export type FunctionApiBindingWithRelations = FunctionApiBinding & FunctionApiBindingRelations; export type FunctionDefinitionWithRelations = FunctionDefinition & FunctionDefinitionRelations; export type FunctionDeploymentWithRelations = FunctionDeployment & FunctionDeploymentRelations; @@ -1992,6 +2053,8 @@ export type FunctionGraphExecutionOutputWithRelations = FunctionGraphExecutionOu export type FunctionGraphObjectWithRelations = FunctionGraphObject & FunctionGraphObjectRelations; export type FunctionGraphRefWithRelations = FunctionGraphRef & FunctionGraphRefRelations; export type FunctionGraphStoreWithRelations = FunctionGraphStore & FunctionGraphStoreRelations; +export type FunctionInvocationAttemptWithRelations = FunctionInvocationAttempt & + FunctionInvocationAttemptRelations; export type FunctionInvocationWithRelations = FunctionInvocation & FunctionInvocationRelations; export type GetAllTreeNodesRecordWithRelations = GetAllTreeNodesRecord & GetAllTreeNodesRecordRelations; @@ -2004,8 +2067,6 @@ export type InfraStoreWithRelations = InfraStore & InfraStoreRelations; export type IntegrationProviderWithRelations = IntegrationProvider & IntegrationProviderRelations; export type NamespaceWithRelations = Namespace & NamespaceRelations; export type NamespaceEventWithRelations = NamespaceEvent & NamespaceEventRelations; -export type PlatformDeclaredCapacityWithRelations = PlatformDeclaredCapacity & - PlatformDeclaredCapacityRelations; export type PlatformFunctionApiBindingWithRelations = PlatformFunctionApiBinding & PlatformFunctionApiBindingRelations; export type PlatformFunctionDefinitionWithRelations = PlatformFunctionDefinition & @@ -2016,6 +2077,8 @@ export type PlatformFunctionDeploymentEventWithRelations = PlatformFunctionDeplo PlatformFunctionDeploymentEventRelations; export type PlatformFunctionExecutionLogWithRelations = PlatformFunctionExecutionLog & PlatformFunctionExecutionLogRelations; +export type PlatformFunctionInvocationAttemptWithRelations = PlatformFunctionInvocationAttempt & + PlatformFunctionInvocationAttemptRelations; export type PlatformFunctionInvocationWithRelations = PlatformFunctionInvocation & PlatformFunctionInvocationRelations; export type PlatformInfraCommitWithRelations = PlatformInfraCommit & PlatformInfraCommitRelations; @@ -2028,6 +2091,8 @@ export type PlatformNamespaceWithRelations = PlatformNamespace & PlatformNamespa export type PlatformNamespaceEventWithRelations = PlatformNamespaceEvent & PlatformNamespaceEventRelations; export type PlatformResourceWithRelations = PlatformResource & PlatformResourceRelations; +export type PlatformResourceDeclaredCapacityWithRelations = PlatformResourceDeclaredCapacity & + PlatformResourceDeclaredCapacityRelations; export type PlatformResourceDefinitionWithRelations = PlatformResourceDefinition & PlatformResourceDefinitionRelations; export type PlatformResourceEventWithRelations = PlatformResourceEvent & @@ -2040,8 +2105,8 @@ export type PlatformResourceUsageLogWithRelations = PlatformResourceUsageLog & PlatformResourceUsageLogRelations; export type PlatformResourceUsageSummaryWithRelations = PlatformResourceUsageSummary & PlatformResourceUsageSummaryRelations; -export type PlatformResourceUtilizationDailyWithRelations = PlatformResourceUtilizationDaily & - PlatformResourceUtilizationDailyRelations; +export type PlatformResourceUtilizationWithRelations = PlatformResourceUtilization & + PlatformResourceUtilizationRelations; export type PlatformResourcesHealthWithRelations = PlatformResourcesHealth & PlatformResourcesHealthRelations; export type PlatformResourcesRequirementsStateWithRelations = PlatformResourcesRequirementsState & @@ -2053,6 +2118,8 @@ export type PlatformWebhookEndpointWithRelations = PlatformWebhookEndpoint & export type PlatformWebhookEventWithRelations = PlatformWebhookEvent & PlatformWebhookEventRelations; export type ResourceWithRelations = Resource & ResourceRelations; +export type ResourceDeclaredCapacityWithRelations = ResourceDeclaredCapacity & + ResourceDeclaredCapacityRelations; export type ResourceDefinitionWithRelations = ResourceDefinition & ResourceDefinitionRelations; export type ResourceEventWithRelations = ResourceEvent & ResourceEventRelations; export type ResourceInstallationWithRelations = ResourceInstallation & @@ -2061,8 +2128,7 @@ export type ResourceStatusCheckWithRelations = ResourceStatusCheck & ResourceSta export type ResourceUsageLogWithRelations = ResourceUsageLog & ResourceUsageLogRelations; export type ResourceUsageSummaryWithRelations = ResourceUsageSummary & ResourceUsageSummaryRelations; -export type ResourceUtilizationDailyWithRelations = ResourceUtilizationDaily & - ResourceUtilizationDailyRelations; +export type ResourceUtilizationWithRelations = ResourceUtilization & ResourceUtilizationRelations; export type ResourcesHealthWithRelations = ResourcesHealth & ResourcesHealthRelations; export type ResourcesRequirementsStateWithRelations = ResourcesRequirementsState & ResourcesRequirementsStateRelations; @@ -2084,21 +2150,6 @@ export type DbPresetSelect = { storeId?: boolean; updatedAt?: boolean; }; -export type DeclaredCapacitySelect = { - cpuLimitMillicores?: boolean; - cpuRequestMillicores?: boolean; - installationId?: boolean; - isTransient?: boolean; - kind?: boolean; - memoryLimitBytes?: boolean; - memoryRequestBytes?: boolean; - namespaceId?: boolean; - podCountMax?: boolean; - podCountMin?: boolean; - source?: boolean; - sourceId?: boolean; - storageSizeBytes?: boolean; -}; export type FunctionApiBindingSelect = { alias?: boolean; apiId?: boolean; @@ -2340,6 +2391,21 @@ export type FunctionGraphStoreSelect = { name?: boolean; scopeId?: boolean; }; +export type FunctionInvocationAttemptSelect = { + actorId?: boolean; + attempt?: boolean; + createdAt?: boolean; + databaseId?: boolean; + durationMs?: boolean; + error?: boolean; + errorDetail?: boolean; + id?: boolean; + invocationCreatedAt?: boolean; + invocationId?: boolean; + startedAt?: boolean; + success?: boolean; + taskIdentifier?: boolean; +}; export type FunctionInvocationSelect = { actorId?: boolean; apiBindingId?: boolean; @@ -2475,21 +2541,6 @@ export type NamespaceEventSelect = { metadata?: boolean; namespaceId?: boolean; }; -export type PlatformDeclaredCapacitySelect = { - cpuLimitMillicores?: boolean; - cpuRequestMillicores?: boolean; - installationId?: boolean; - isTransient?: boolean; - kind?: boolean; - memoryLimitBytes?: boolean; - memoryRequestBytes?: boolean; - namespaceId?: boolean; - podCountMax?: boolean; - podCountMin?: boolean; - source?: boolean; - sourceId?: boolean; - storageSizeBytes?: boolean; -}; export type PlatformFunctionApiBindingSelect = { alias?: boolean; apiId?: boolean; @@ -2508,6 +2559,7 @@ export type PlatformFunctionApiBindingSelect = { }; export type PlatformFunctionDefinitionSelect = { accessChannels?: boolean; + billable?: boolean; category?: boolean; concurrency?: boolean; cpuLimitMillicores?: boolean; @@ -2543,6 +2595,7 @@ export type PlatformFunctionDefinitionSelect = { runtime?: boolean; scaleMax?: boolean; scaleMin?: boolean; + system?: boolean; targetFunction?: boolean; targetSchema?: boolean; taskIdentifier?: boolean; @@ -2610,6 +2663,20 @@ export type PlatformFunctionExecutionLogSelect = { metadata?: boolean; taskIdentifier?: boolean; }; +export type PlatformFunctionInvocationAttemptSelect = { + actorId?: boolean; + attempt?: boolean; + createdAt?: boolean; + durationMs?: boolean; + error?: boolean; + errorDetail?: boolean; + id?: boolean; + invocationCreatedAt?: boolean; + invocationId?: boolean; + startedAt?: boolean; + success?: boolean; + taskIdentifier?: boolean; +}; export type PlatformFunctionInvocationSelect = { actorId?: boolean; apiBindingId?: boolean; @@ -2770,6 +2837,21 @@ export type PlatformResourceSelect = { orderBy?: PlatformResourceStatusCheckOrderBy[]; }; }; +export type PlatformResourceDeclaredCapacitySelect = { + cpuLimitMillicores?: boolean; + cpuRequestMillicores?: boolean; + installationId?: boolean; + isTransient?: boolean; + kind?: boolean; + memoryLimitBytes?: boolean; + memoryRequestBytes?: boolean; + namespaceId?: boolean; + podCountMax?: boolean; + podCountMin?: boolean; + source?: boolean; + sourceId?: boolean; + storageSizeBytes?: boolean; +}; export type PlatformResourceDefinitionSelect = { annotations?: boolean; createdAt?: boolean; @@ -2865,7 +2947,7 @@ export type PlatformResourceUsageSummarySelect = { runtimeSeconds?: boolean; sampleCount?: boolean; }; -export type PlatformResourceUtilizationDailySelect = { +export type PlatformResourceUtilizationSelect = { avgMemoryBytes?: boolean; cpuLimitMillicores?: boolean; cpuPeakUtilization?: boolean; @@ -3030,6 +3112,21 @@ export type ResourceSelect = { orderBy?: ResourceStatusCheckOrderBy[]; }; }; +export type ResourceDeclaredCapacitySelect = { + cpuLimitMillicores?: boolean; + cpuRequestMillicores?: boolean; + installationId?: boolean; + isTransient?: boolean; + kind?: boolean; + memoryLimitBytes?: boolean; + memoryRequestBytes?: boolean; + namespaceId?: boolean; + podCountMax?: boolean; + podCountMin?: boolean; + source?: boolean; + sourceId?: boolean; + storageSizeBytes?: boolean; +}; export type ResourceDefinitionSelect = { annotations?: boolean; createdAt?: boolean; @@ -3131,7 +3228,7 @@ export type ResourceUsageSummarySelect = { runtimeSeconds?: boolean; sampleCount?: boolean; }; -export type ResourceUtilizationDailySelect = { +export type ResourceUtilizationSelect = { avgMemoryBytes?: boolean; cpuLimitMillicores?: boolean; cpuPeakUtilization?: boolean; @@ -3283,40 +3380,6 @@ export interface DbPresetFilter { /** Filter by the object’s `updatedAt` field. */ updatedAt?: DatetimeFilter; } -export interface DeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: DeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: DeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: DeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} export interface FunctionApiBindingFilter { /** Filter by the object’s `alias` field. */ alias?: StringFilter; @@ -3795,6 +3858,40 @@ export interface FunctionGraphStoreFilter { /** Filter by the object’s `scopeId` field. */ scopeId?: UUIDFilter; } +export interface FunctionInvocationAttemptFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: FunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} export interface FunctionInvocationFilter { /** Filter by the object’s `actorId` field. */ actorId?: UUIDFilter; @@ -4049,40 +4146,6 @@ export interface NamespaceEventFilter { /** Checks for any expressions in this list. */ or?: NamespaceEventFilter[]; } -export interface PlatformDeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: PlatformDeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} export interface PlatformFunctionApiBindingFilter { /** Filter by the object’s `alias` field. */ alias?: StringFilter; @@ -4112,6 +4175,8 @@ export interface PlatformFunctionDefinitionFilter { accessChannels?: StringListFilter; /** Checks for all expressions in this list. */ and?: PlatformFunctionDefinitionFilter[]; + /** Filter by the object’s `billable` field. */ + billable?: BooleanFilter; /** Filter by the object’s `category` field. */ category?: StringFilter; /** Filter by the object’s `concurrency` field. */ @@ -4194,6 +4259,8 @@ export interface PlatformFunctionDefinitionFilter { scaleMax?: IntFilter; /** Filter by the object’s `scaleMin` field. */ scaleMin?: IntFilter; + /** Filter by the object’s `system` field. */ + system?: BooleanFilter; /** Filter by the object’s `targetFunction` field. */ targetFunction?: StringFilter; /** Filter by the object’s `targetSchema` field. */ @@ -4305,20 +4372,52 @@ export interface PlatformFunctionExecutionLogFilter { /** Filter by the object’s `taskIdentifier` field. */ taskIdentifier?: StringFilter; } -export interface PlatformFunctionInvocationFilter { +export interface PlatformFunctionInvocationAttemptFilter { /** Filter by the object’s `actorId` field. */ actorId?: UUIDFilter; /** Checks for all expressions in this list. */ - and?: PlatformFunctionInvocationFilter[]; - /** Filter by the object’s `apiBinding` relation. */ - apiBinding?: PlatformFunctionApiBindingFilter; - /** A related `apiBinding` exists. */ - apiBindingExists?: boolean; - /** Filter by the object’s `apiBindingId` field. */ - apiBindingId?: UUIDFilter; - /** Filter by the object’s `channel` field. */ - channel?: StringFilter; - /** Filter by the object’s `completedAt` field. */ + and?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformFunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} +export interface PlatformFunctionInvocationFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: PlatformFunctionInvocationFilter[]; + /** Filter by the object’s `apiBinding` relation. */ + apiBinding?: PlatformFunctionApiBindingFilter; + /** A related `apiBinding` exists. */ + apiBindingExists?: boolean; + /** Filter by the object’s `apiBindingId` field. */ + apiBindingId?: UUIDFilter; + /** Filter by the object’s `channel` field. */ + channel?: StringFilter; + /** Filter by the object’s `completedAt` field. */ completedAt?: DatetimeFilter; /** Filter by the object’s `createdAt` field. */ createdAt?: DatetimeFilter; @@ -4594,6 +4693,40 @@ export interface PlatformResourceFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +export interface PlatformResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} export interface PlatformResourceDefinitionFilter { /** Checks for all expressions in this list. */ and?: PlatformResourceDefinitionFilter[]; @@ -4776,9 +4909,9 @@ export interface PlatformResourceUsageSummaryFilter { /** Filter by the object’s `sampleCount` field. */ sampleCount?: IntFilter; } -export interface PlatformResourceUtilizationDailyFilter { +export interface PlatformResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: PlatformResourceUtilizationDailyFilter[]; + and?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -4810,9 +4943,9 @@ export interface PlatformResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: PlatformResourceUtilizationDailyFilter; + not?: PlatformResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: PlatformResourceUtilizationDailyFilter[]; + or?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -5090,6 +5223,40 @@ export interface ResourceFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +export interface ResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: ResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} export interface ResourceDefinitionFilter { /** Checks for all expressions in this list. */ and?: ResourceDefinitionFilter[]; @@ -5284,9 +5451,9 @@ export interface ResourceUsageSummaryFilter { /** Filter by the object’s `sampleCount` field. */ sampleCount?: IntFilter; } -export interface ResourceUtilizationDailyFilter { +export interface ResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: ResourceUtilizationDailyFilter[]; + and?: ResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -5318,9 +5485,9 @@ export interface ResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: ResourceUtilizationDailyFilter; + not?: ResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: ResourceUtilizationDailyFilter[]; + or?: ResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -5553,34 +5720,6 @@ export type DbPresetOrderBy = | 'STORE_ID_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC'; -export type DeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; export type FunctionApiBindingOrderBy = | 'ALIAS_ASC' | 'ALIAS_DESC' @@ -5985,6 +6124,36 @@ export type FunctionGraphStoreOrderBy = | 'PRIMARY_KEY_DESC' | 'SCOPE_ID_ASC' | 'SCOPE_ID_DESC'; +export type FunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; export type FunctionInvocationOrderBy = | 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' @@ -6189,34 +6358,6 @@ export type NamespaceEventOrderBy = | 'NATURAL' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC'; -export type PlatformDeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; export type PlatformFunctionApiBindingOrderBy = | 'ALIAS_ASC' | 'ALIAS_DESC' @@ -6234,6 +6375,8 @@ export type PlatformFunctionApiBindingOrderBy = export type PlatformFunctionDefinitionOrderBy = | 'ACCESS_CHANNELS_ASC' | 'ACCESS_CHANNELS_DESC' + | 'BILLABLE_ASC' + | 'BILLABLE_DESC' | 'CATEGORY_ASC' | 'CATEGORY_DESC' | 'CONCURRENCY_ASC' @@ -6307,6 +6450,8 @@ export type PlatformFunctionDefinitionOrderBy = | 'SCALE_MAX_DESC' | 'SCALE_MIN_ASC' | 'SCALE_MIN_DESC' + | 'SYSTEM_ASC' + | 'SYSTEM_DESC' | 'TARGET_FUNCTION_ASC' | 'TARGET_FUNCTION_DESC' | 'TARGET_SCHEMA_ASC' @@ -6403,6 +6548,34 @@ export type PlatformFunctionExecutionLogOrderBy = | 'PRIMARY_KEY_DESC' | 'TASK_IDENTIFIER_ASC' | 'TASK_IDENTIFIER_DESC'; +export type PlatformFunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; export type PlatformFunctionInvocationOrderBy = | 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' @@ -6627,6 +6800,34 @@ export type PlatformResourceOrderBy = | 'UPDATED_AT_DESC' | 'UPDATED_BY_ASC' | 'UPDATED_BY_DESC'; +export type PlatformResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; export type PlatformResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' @@ -6775,7 +6976,7 @@ export type PlatformResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -export type PlatformResourceUtilizationDailyOrderBy = +export type PlatformResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -7037,6 +7238,34 @@ export type ResourceOrderBy = | 'UPDATED_AT_DESC' | 'UPDATED_BY_ASC' | 'UPDATED_BY_DESC'; +export type ResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; export type ResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' @@ -7197,7 +7426,7 @@ export type ResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -export type ResourceUtilizationDailyOrderBy = +export type ResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -7407,72 +7636,30 @@ export interface CreateDbPresetInput { dbPreset: { active?: boolean; commitId?: string; - definition: Record; - description?: string; - label?: string; - modulesHash?: string; - slug: string; - storeId?: string; - }; -} -export interface DbPresetPatch { - active?: boolean | null; - commitId?: string | null; - definition?: Record | null; - description?: string | null; - label?: string | null; - modulesHash?: string | null; - slug?: string | null; - storeId?: string | null; -} -export interface UpdateDbPresetInput { - clientMutationId?: string; - id: string; - dbPresetPatch: DbPresetPatch; -} -export interface DeleteDbPresetInput { - clientMutationId?: string; - id: string; -} -export interface CreateDeclaredCapacityInput { - clientMutationId?: string; - declaredCapacity: { - cpuLimitMillicores?: string; - cpuRequestMillicores?: string; - installationId: string; - isTransient?: boolean; - kind?: string; - memoryLimitBytes?: string; - memoryRequestBytes?: string; - namespaceId: string; - podCountMax?: number; - podCountMin?: number; - source?: string; - sourceId: string; - storageSizeBytes?: string; - }; -} -export interface DeclaredCapacityPatch { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; + definition: Record; + description?: string; + label?: string; + modulesHash?: string; + slug: string; + storeId?: string; + }; +} +export interface DbPresetPatch { + active?: boolean | null; + commitId?: string | null; + definition?: Record | null; + description?: string | null; + label?: string | null; + modulesHash?: string | null; + slug?: string | null; + storeId?: string | null; } -export interface UpdateDeclaredCapacityInput { +export interface UpdateDbPresetInput { clientMutationId?: string; id: string; - declaredCapacityPatch: DeclaredCapacityPatch; + dbPresetPatch: DbPresetPatch; } -export interface DeleteDeclaredCapacityInput { +export interface DeleteDbPresetInput { clientMutationId?: string; id: string; } @@ -7536,7 +7723,6 @@ export interface CreateFunctionDefinitionInput { scaleMin?: number; targetFunction?: string; targetSchema?: string; - taskIdentifier: string; timeoutSeconds?: number; volatile?: boolean; }; @@ -7575,7 +7761,6 @@ export interface FunctionDefinitionPatch { scaleMin?: number | null; targetFunction?: string | null; targetSchema?: string | null; - taskIdentifier?: string | null; timeoutSeconds?: number | null; volatile?: boolean | null; } @@ -7978,6 +8163,44 @@ export interface DeleteFunctionGraphStoreInput { clientMutationId?: string; id: string; } +export interface CreateFunctionInvocationAttemptInput { + clientMutationId?: string; + functionInvocationAttempt: { + actorId?: string; + attempt: number; + databaseId: string; + durationMs?: number; + error?: string; + errorDetail?: Record; + invocationCreatedAt: string; + invocationId: string; + startedAt?: string; + success: boolean; + taskIdentifier: string; + }; +} +export interface FunctionInvocationAttemptPatch { + actorId?: string | null; + attempt?: number | null; + databaseId?: string | null; + durationMs?: number | null; + error?: string | null; + errorDetail?: Record | null; + invocationCreatedAt?: string | null; + invocationId?: string | null; + startedAt?: string | null; + success?: boolean | null; + taskIdentifier?: string | null; +} +export interface UpdateFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; +} +export interface DeleteFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; +} export interface CreateFunctionInvocationInput { clientMutationId?: string; functionInvocation: { @@ -8271,48 +8494,6 @@ export interface DeleteNamespaceEventInput { clientMutationId?: string; id: string; } -export interface CreatePlatformDeclaredCapacityInput { - clientMutationId?: string; - platformDeclaredCapacity: { - cpuLimitMillicores?: string; - cpuRequestMillicores?: string; - installationId: string; - isTransient?: boolean; - kind?: string; - memoryLimitBytes?: string; - memoryRequestBytes?: string; - namespaceId: string; - podCountMax?: number; - podCountMin?: number; - source?: string; - sourceId: string; - storageSizeBytes?: string; - }; -} -export interface PlatformDeclaredCapacityPatch { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} -export interface UpdatePlatformDeclaredCapacityInput { - clientMutationId?: string; - id: string; - platformDeclaredCapacityPatch: PlatformDeclaredCapacityPatch; -} -export interface DeletePlatformDeclaredCapacityInput { - clientMutationId?: string; - id: string; -} export interface CreatePlatformFunctionApiBindingInput { clientMutationId?: string; platformFunctionApiBinding: { @@ -8341,6 +8522,7 @@ export interface CreatePlatformFunctionDefinitionInput { clientMutationId?: string; platformFunctionDefinition: { accessChannels?: string[]; + billable?: boolean; category: string; concurrency?: number; description?: string; @@ -8370,15 +8552,16 @@ export interface CreatePlatformFunctionDefinitionInput { runtime?: string; scaleMax?: number; scaleMin?: number; + system?: boolean; targetFunction?: string; targetSchema?: string; - taskIdentifier: string; timeoutSeconds?: number; volatile?: boolean; }; } export interface PlatformFunctionDefinitionPatch { accessChannels?: string[] | null; + billable?: boolean | null; category?: string | null; concurrency?: number | null; description?: string | null; @@ -8408,9 +8591,9 @@ export interface PlatformFunctionDefinitionPatch { runtime?: string | null; scaleMax?: number | null; scaleMin?: number | null; + system?: boolean | null; targetFunction?: string | null; targetSchema?: string | null; - taskIdentifier?: string | null; timeoutSeconds?: number | null; volatile?: boolean | null; } @@ -8529,6 +8712,42 @@ export interface DeletePlatformFunctionExecutionLogInput { clientMutationId?: string; id: string; } +export interface CreatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + platformFunctionInvocationAttempt: { + actorId?: string; + attempt: number; + durationMs?: number; + error?: string; + errorDetail?: Record; + invocationCreatedAt: string; + invocationId: string; + startedAt?: string; + success: boolean; + taskIdentifier: string; + }; +} +export interface PlatformFunctionInvocationAttemptPatch { + actorId?: string | null; + attempt?: number | null; + durationMs?: number | null; + error?: string | null; + errorDetail?: Record | null; + invocationCreatedAt?: string | null; + invocationId?: string | null; + startedAt?: string | null; + success?: boolean | null; + taskIdentifier?: string | null; +} +export interface UpdatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; +} +export interface DeletePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; +} export interface CreatePlatformFunctionInvocationInput { clientMutationId?: string; platformFunctionInvocation: { @@ -8815,6 +9034,48 @@ export interface DeletePlatformResourceInput { clientMutationId?: string; id: string; } +export interface CreatePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + platformResourceDeclaredCapacity: { + cpuLimitMillicores?: string; + cpuRequestMillicores?: string; + installationId: string; + isTransient?: boolean; + kind?: string; + memoryLimitBytes?: string; + memoryRequestBytes?: string; + namespaceId: string; + podCountMax?: number; + podCountMin?: number; + source?: string; + sourceId: string; + storageSizeBytes?: string; + }; +} +export interface PlatformResourceDeclaredCapacityPatch { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} +export interface UpdatePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; + platformResourceDeclaredCapacityPatch: PlatformResourceDeclaredCapacityPatch; +} +export interface DeletePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; +} export interface CreatePlatformResourceDefinitionInput { clientMutationId?: string; platformResourceDefinition: { @@ -9013,9 +9274,9 @@ export interface DeletePlatformResourceUsageSummaryInput { clientMutationId?: string; id: string; } -export interface CreatePlatformResourceUtilizationDailyInput { +export interface CreatePlatformResourceUtilizationInput { clientMutationId?: string; - platformResourceUtilizationDaily: { + platformResourceUtilization: { avgMemoryBytes?: string; cpuLimitMillicores?: string; cpuPeakUtilization?: string; @@ -9037,7 +9298,7 @@ export interface CreatePlatformResourceUtilizationDailyInput { sampleCount?: number; }; } -export interface PlatformResourceUtilizationDailyPatch { +export interface PlatformResourceUtilizationPatch { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -9058,12 +9319,12 @@ export interface PlatformResourceUtilizationDailyPatch { runtimeSeconds?: string | null; sampleCount?: number | null; } -export interface UpdatePlatformResourceUtilizationDailyInput { +export interface UpdatePlatformResourceUtilizationInput { clientMutationId?: string; id: string; - platformResourceUtilizationDailyPatch: PlatformResourceUtilizationDailyPatch; + platformResourceUtilizationPatch: PlatformResourceUtilizationPatch; } -export interface DeletePlatformResourceUtilizationDailyInput { +export interface DeletePlatformResourceUtilizationInput { clientMutationId?: string; id: string; } @@ -9329,6 +9590,48 @@ export interface DeleteResourceInput { clientMutationId?: string; id: string; } +export interface CreateResourceDeclaredCapacityInput { + clientMutationId?: string; + resourceDeclaredCapacity: { + cpuLimitMillicores?: string; + cpuRequestMillicores?: string; + installationId: string; + isTransient?: boolean; + kind?: string; + memoryLimitBytes?: string; + memoryRequestBytes?: string; + namespaceId: string; + podCountMax?: number; + podCountMin?: number; + source?: string; + sourceId: string; + storageSizeBytes?: string; + }; +} +export interface ResourceDeclaredCapacityPatch { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} +export interface UpdateResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; + resourceDeclaredCapacityPatch: ResourceDeclaredCapacityPatch; +} +export interface DeleteResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; +} export interface CreateResourceDefinitionInput { clientMutationId?: string; resourceDefinition: { @@ -9539,9 +9842,9 @@ export interface DeleteResourceUsageSummaryInput { clientMutationId?: string; id: string; } -export interface CreateResourceUtilizationDailyInput { +export interface CreateResourceUtilizationInput { clientMutationId?: string; - resourceUtilizationDaily: { + resourceUtilization: { avgMemoryBytes?: string; cpuLimitMillicores?: string; cpuPeakUtilization?: string; @@ -9563,7 +9866,7 @@ export interface CreateResourceUtilizationDailyInput { sampleCount?: number; }; } -export interface ResourceUtilizationDailyPatch { +export interface ResourceUtilizationPatch { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -9584,12 +9887,12 @@ export interface ResourceUtilizationDailyPatch { runtimeSeconds?: string | null; sampleCount?: number | null; } -export interface UpdateResourceUtilizationDailyInput { +export interface UpdateResourceUtilizationInput { clientMutationId?: string; id: string; - resourceUtilizationDailyPatch: ResourceUtilizationDailyPatch; + resourceUtilizationPatch: ResourceUtilizationPatch; } -export interface DeleteResourceUtilizationDailyInput { +export interface DeleteResourceUtilizationInput { clientMutationId?: string; id: string; } @@ -9986,24 +10289,24 @@ export interface PlatformInfraSetDataAtPathInput { } export interface PlatformResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: Record; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: Record; + slug?: string; } export interface PlatformResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: Record; + newParams?: Record; + targetInstallationId?: string; } export interface ProvisionBucketInput { /** The logical bucket key (e.g., "public", "private") */ @@ -10016,24 +10319,24 @@ export interface ProvisionBucketInput { } export interface ResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: Record; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: Record; + slug?: string; } export interface ResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: Record; + newParams?: Record; + targetInstallationId?: string; } export interface SaveGraphInput { clientMutationId?: string; @@ -10483,8 +10786,6 @@ export interface FunctionDefinitionInput { targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -10756,6 +11057,35 @@ export interface FunctionGraphStoreInput { /** Opaque store partition key for the global tier */ scopeId: string; } +/** An input for mutations affecting `FunctionInvocationAttempt` */ +export interface FunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Database that owns this resource (database-scoped isolation) */ + databaseId: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} /** An input for mutations affecting `FunctionInvocation` */ export interface FunctionInvocationInput { /** Who triggered the invocation (NULL for system/cron) */ @@ -10774,7 +11104,7 @@ export interface FunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -10794,7 +11124,7 @@ export interface FunctionInvocationInput { result?: Record; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -10946,6 +11276,8 @@ export interface PlatformFunctionApiBindingInput { export interface PlatformFunctionDefinitionInput { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[]; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean; /** Function task category (e.g. email, embed, chunk, custom) */ category: string; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -11006,12 +11338,12 @@ export interface PlatformFunctionDefinitionInput { scaleMax?: number; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -11096,6 +11428,33 @@ export interface PlatformFunctionExecutionLogInput { /** Function routing key (NULL for generic job logs) */ taskIdentifier?: string; } +/** An input for mutations affecting `PlatformFunctionInvocationAttempt` */ +export interface PlatformFunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} /** An input for mutations affecting `PlatformFunctionInvocation` */ export interface PlatformFunctionInvocationInput { /** Who triggered the invocation (NULL for system/cron) */ @@ -11112,7 +11471,7 @@ export interface PlatformFunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -11132,7 +11491,7 @@ export interface PlatformFunctionInvocationInput { result?: Record; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -11253,7 +11612,7 @@ export interface PlatformResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: Record; @@ -11295,7 +11654,7 @@ export interface PlatformResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: Record; @@ -11409,7 +11768,7 @@ export interface PlatformResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** An input for mutations affecting `PlatformResourceUsageSummary` */ @@ -11496,7 +11855,7 @@ export interface ResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: Record; @@ -11540,7 +11899,7 @@ export interface ResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: Record; @@ -11643,7 +12002,7 @@ export interface ResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** An input for mutations affecting `ResourceUsageSummary` */ @@ -11925,6 +12284,8 @@ export interface PlatformFunctionDefinitionFilter { accessChannels?: StringListFilter; /** Checks for all expressions in this list. */ and?: PlatformFunctionDefinitionFilter[]; + /** Filter by the object’s `billable` field. */ + billable?: BooleanFilter; /** Filter by the object’s `category` field. */ category?: StringFilter; /** Filter by the object’s `concurrency` field. */ @@ -12007,6 +12368,8 @@ export interface PlatformFunctionDefinitionFilter { scaleMax?: IntFilter; /** Filter by the object’s `scaleMin` field. */ scaleMin?: IntFilter; + /** Filter by the object’s `system` field. */ + system?: BooleanFilter; /** Filter by the object’s `targetFunction` field. */ targetFunction?: StringFilter; /** Filter by the object’s `targetSchema` field. */ @@ -14069,6 +14432,51 @@ export type DeleteFunctionGraphStorePayloadSelect = { select: FunctionGraphStoreEdgeSelect; }; }; +export interface CreateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was created by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type CreateFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; +export interface UpdateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was updated by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type UpdateFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; +export interface DeleteFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was deleted by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type DeleteFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; export interface CreateFunctionInvocationPayload { clientMutationId?: string | null; /** The `FunctionInvocation` that was created by this mutation. */ @@ -14654,6 +15062,51 @@ export type DeletePlatformFunctionExecutionLogPayloadSelect = { select: PlatformFunctionExecutionLogEdgeSelect; }; }; +export interface CreatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was created by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type CreatePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; +export interface UpdatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was updated by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type UpdatePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; +export interface DeletePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was deleted by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type DeletePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; export interface CreatePlatformFunctionInvocationPayload { clientMutationId?: string | null; /** The `PlatformFunctionInvocation` that was created by this mutation. */ @@ -15947,6 +16400,18 @@ export type FunctionGraphStoreEdgeSelect = { select: FunctionGraphStoreSelect; }; }; +/** A `FunctionInvocationAttempt` edge in the connection. */ +export interface FunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `FunctionInvocationAttempt` at the end of the edge. */ + node?: FunctionInvocationAttempt | null; +} +export type FunctionInvocationAttemptEdgeSelect = { + cursor?: boolean; + node?: { + select: FunctionInvocationAttemptSelect; + }; +}; /** A `FunctionInvocation` edge in the connection. */ export interface FunctionInvocationEdge { cursor?: string | null; @@ -16103,6 +16568,18 @@ export type PlatformFunctionExecutionLogEdgeSelect = { select: PlatformFunctionExecutionLogSelect; }; }; +/** A `PlatformFunctionInvocationAttempt` edge in the connection. */ +export interface PlatformFunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `PlatformFunctionInvocationAttempt` at the end of the edge. */ + node?: PlatformFunctionInvocationAttempt | null; +} +export type PlatformFunctionInvocationAttemptEdgeSelect = { + cursor?: boolean; + node?: { + select: PlatformFunctionInvocationAttemptSelect; + }; +}; /** A `PlatformFunctionInvocation` edge in the connection. */ export interface PlatformFunctionInvocationEdge { cursor?: string | null; diff --git a/sdk/constructive-cli/src/compute/orm/models/declaredCapacity.ts b/sdk/constructive-cli/src/compute/orm/models/declaredCapacity.ts deleted file mode 100644 index 69304243f..000000000 --- a/sdk/constructive-cli/src/compute/orm/models/declaredCapacity.ts +++ /dev/null @@ -1,134 +0,0 @@ -/** - * DeclaredCapacity model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - DeclaredCapacity, - DeclaredCapacityWithRelations, - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy, - CreateDeclaredCapacityInput, - UpdateDeclaredCapacityInput, - DeclaredCapacityPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class DeclaredCapacityModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - declaredCapacities: ConnectionResult>; - }> { - const { document, variables } = buildFindManyDocument( - 'DeclaredCapacity', - 'declaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'DeclaredCapacityFilter', - 'DeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'DeclaredCapacity', - fieldName: 'declaredCapacities', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - declaredCapacity: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'DeclaredCapacity', - 'declaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'DeclaredCapacityFilter', - 'DeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'DeclaredCapacity', - fieldName: 'declaredCapacity', - document, - variables, - transform: (data: { - declaredCapacities?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - declaredCapacity: data.declaredCapacities?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createDeclaredCapacity: { - declaredCapacity: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'DeclaredCapacity', - 'createDeclaredCapacity', - 'declaredCapacity', - args.select, - args.data, - 'CreateDeclaredCapacityInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'DeclaredCapacity', - fieldName: 'createDeclaredCapacity', - document, - variables, - }); - } -} diff --git a/sdk/constructive-cli/src/compute/orm/models/functionInvocationAttempt.ts b/sdk/constructive-cli/src/compute/orm/models/functionInvocationAttempt.ts new file mode 100644 index 000000000..710ddec0b --- /dev/null +++ b/sdk/constructive-cli/src/compute/orm/models/functionInvocationAttempt.ts @@ -0,0 +1,252 @@ +/** + * FunctionInvocationAttempt model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + FunctionInvocationAttempt, + FunctionInvocationAttemptWithRelations, + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy, + CreateFunctionInvocationAttemptInput, + UpdateFunctionInvocationAttemptInput, + FunctionInvocationAttemptPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class FunctionInvocationAttemptModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempts', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempt: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempt', + document, + variables, + transform: (data: { + functionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + functionInvocationAttempt: data.functionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempt: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempt', + document, + variables, + transform: (data: { + functionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + functionInvocationAttempt: data.functionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'FunctionInvocationAttempt', + 'createFunctionInvocationAttempt', + 'functionInvocationAttempt', + args.select, + args.data, + 'CreateFunctionInvocationAttemptInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'createFunctionInvocationAttempt', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + createdAt: string; + }, + FunctionInvocationAttemptPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'FunctionInvocationAttempt', + 'updateFunctionInvocationAttempt', + 'functionInvocationAttempt', + args.select, + args.where.id, + args.data, + 'UpdateFunctionInvocationAttemptInput', + 'id', + 'functionInvocationAttemptPatch', + connectionFieldsMap, + { + createdAt: args.where.createdAt, + } + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'updateFunctionInvocationAttempt', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + createdAt: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'FunctionInvocationAttempt', + 'deleteFunctionInvocationAttempt', + 'functionInvocationAttempt', + { + id: args.where.id, + createdAt: args.where.createdAt, + }, + 'DeleteFunctionInvocationAttemptInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'deleteFunctionInvocationAttempt', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/compute/orm/models/index.ts b/sdk/constructive-cli/src/compute/orm/models/index.ts index 3f21b469c..c06f5f3db 100644 --- a/sdk/constructive-cli/src/compute/orm/models/index.ts +++ b/sdk/constructive-cli/src/compute/orm/models/index.ts @@ -4,7 +4,6 @@ * DO NOT EDIT - changes will be overwritten */ export { DbPresetModel } from './dbPreset'; -export { DeclaredCapacityModel } from './declaredCapacity'; export { FunctionApiBindingModel } from './functionApiBinding'; export { FunctionDefinitionModel } from './functionDefinition'; export { FunctionDeploymentModel } from './functionDeployment'; @@ -18,6 +17,7 @@ export { FunctionGraphExecutionOutputModel } from './functionGraphExecutionOutpu export { FunctionGraphObjectModel } from './functionGraphObject'; export { FunctionGraphRefModel } from './functionGraphRef'; export { FunctionGraphStoreModel } from './functionGraphStore'; +export { FunctionInvocationAttemptModel } from './functionInvocationAttempt'; export { FunctionInvocationModel } from './functionInvocation'; export { GetAllTreeNodesRecordModel } from './getAllTreeNodesRecord'; export { InfraCommitModel } from './infraCommit'; @@ -28,12 +28,12 @@ export { InfraStoreModel } from './infraStore'; export { IntegrationProviderModel } from './integrationProvider'; export { NamespaceModel } from './namespace'; export { NamespaceEventModel } from './namespaceEvent'; -export { PlatformDeclaredCapacityModel } from './platformDeclaredCapacity'; export { PlatformFunctionApiBindingModel } from './platformFunctionApiBinding'; export { PlatformFunctionDefinitionModel } from './platformFunctionDefinition'; export { PlatformFunctionDeploymentModel } from './platformFunctionDeployment'; export { PlatformFunctionDeploymentEventModel } from './platformFunctionDeploymentEvent'; export { PlatformFunctionExecutionLogModel } from './platformFunctionExecutionLog'; +export { PlatformFunctionInvocationAttemptModel } from './platformFunctionInvocationAttempt'; export { PlatformFunctionInvocationModel } from './platformFunctionInvocation'; export { PlatformInfraCommitModel } from './platformInfraCommit'; export { PlatformInfraGetAllTreeNodesRecordModel } from './platformInfraGetAllTreeNodesRecord'; @@ -43,26 +43,28 @@ export { PlatformInfraStoreModel } from './platformInfraStore'; export { PlatformNamespaceModel } from './platformNamespace'; export { PlatformNamespaceEventModel } from './platformNamespaceEvent'; export { PlatformResourceModel } from './platformResource'; +export { PlatformResourceDeclaredCapacityModel } from './platformResourceDeclaredCapacity'; export { PlatformResourceDefinitionModel } from './platformResourceDefinition'; export { PlatformResourceEventModel } from './platformResourceEvent'; export { PlatformResourceInstallationModel } from './platformResourceInstallation'; export { PlatformResourceStatusCheckModel } from './platformResourceStatusCheck'; export { PlatformResourceUsageLogModel } from './platformResourceUsageLog'; export { PlatformResourceUsageSummaryModel } from './platformResourceUsageSummary'; -export { PlatformResourceUtilizationDailyModel } from './platformResourceUtilizationDaily'; +export { PlatformResourceUtilizationModel } from './platformResourceUtilization'; export { PlatformResourcesHealthModel } from './platformResourcesHealth'; export { PlatformResourcesRequirementsStateModel } from './platformResourcesRequirementsState'; export { PlatformResourcesResolvedRequirementModel } from './platformResourcesResolvedRequirement'; export { PlatformWebhookEndpointModel } from './platformWebhookEndpoint'; export { PlatformWebhookEventModel } from './platformWebhookEvent'; export { ResourceModel } from './resource'; +export { ResourceDeclaredCapacityModel } from './resourceDeclaredCapacity'; export { ResourceDefinitionModel } from './resourceDefinition'; export { ResourceEventModel } from './resourceEvent'; export { ResourceInstallationModel } from './resourceInstallation'; export { ResourceStatusCheckModel } from './resourceStatusCheck'; export { ResourceUsageLogModel } from './resourceUsageLog'; export { ResourceUsageSummaryModel } from './resourceUsageSummary'; -export { ResourceUtilizationDailyModel } from './resourceUtilizationDaily'; +export { ResourceUtilizationModel } from './resourceUtilization'; export { ResourcesHealthModel } from './resourcesHealth'; export { ResourcesRequirementsStateModel } from './resourcesRequirementsState'; export { ResourcesResolvedRequirementModel } from './resourcesResolvedRequirement'; diff --git a/sdk/constructive-cli/src/compute/orm/models/platformDeclaredCapacity.ts b/sdk/constructive-cli/src/compute/orm/models/platformDeclaredCapacity.ts deleted file mode 100644 index 0edf75c4d..000000000 --- a/sdk/constructive-cli/src/compute/orm/models/platformDeclaredCapacity.ts +++ /dev/null @@ -1,136 +0,0 @@ -/** - * PlatformDeclaredCapacity model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - PlatformDeclaredCapacity, - PlatformDeclaredCapacityWithRelations, - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy, - CreatePlatformDeclaredCapacityInput, - UpdatePlatformDeclaredCapacityInput, - PlatformDeclaredCapacityPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class PlatformDeclaredCapacityModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformDeclaredCapacities: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'PlatformDeclaredCapacity', - 'platformDeclaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'PlatformDeclaredCapacityFilter', - 'PlatformDeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'platformDeclaredCapacities', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformDeclaredCapacity: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'PlatformDeclaredCapacity', - 'platformDeclaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'PlatformDeclaredCapacityFilter', - 'PlatformDeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'platformDeclaredCapacity', - document, - variables, - transform: (data: { - platformDeclaredCapacities?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - platformDeclaredCapacity: data.platformDeclaredCapacities?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createPlatformDeclaredCapacity: { - platformDeclaredCapacity: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'PlatformDeclaredCapacity', - 'createPlatformDeclaredCapacity', - 'platformDeclaredCapacity', - args.select, - args.data, - 'CreatePlatformDeclaredCapacityInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'createPlatformDeclaredCapacity', - document, - variables, - }); - } -} diff --git a/sdk/constructive-cli/src/compute/orm/models/platformFunctionInvocationAttempt.ts b/sdk/constructive-cli/src/compute/orm/models/platformFunctionInvocationAttempt.ts new file mode 100644 index 000000000..a1db7bbe0 --- /dev/null +++ b/sdk/constructive-cli/src/compute/orm/models/platformFunctionInvocationAttempt.ts @@ -0,0 +1,280 @@ +/** + * PlatformFunctionInvocationAttempt model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformFunctionInvocationAttempt, + PlatformFunctionInvocationAttemptWithRelations, + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy, + CreatePlatformFunctionInvocationAttemptInput, + UpdatePlatformFunctionInvocationAttemptInput, + PlatformFunctionInvocationAttemptPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformFunctionInvocationAttemptModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempts', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempt', + document, + variables, + transform: (data: { + platformFunctionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformFunctionInvocationAttempt: + data.platformFunctionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempt', + document, + variables, + transform: (data: { + platformFunctionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformFunctionInvocationAttempt: + data.platformFunctionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs< + S, + CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt'] + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformFunctionInvocationAttempt', + 'createPlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + args.select, + args.data, + 'CreatePlatformFunctionInvocationAttemptInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'createPlatformFunctionInvocationAttempt', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + createdAt: string; + }, + PlatformFunctionInvocationAttemptPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updatePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'PlatformFunctionInvocationAttempt', + 'updatePlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + args.select, + args.where.id, + args.data, + 'UpdatePlatformFunctionInvocationAttemptInput', + 'id', + 'platformFunctionInvocationAttemptPatch', + connectionFieldsMap, + { + createdAt: args.where.createdAt, + } + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'updatePlatformFunctionInvocationAttempt', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + createdAt: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deletePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'PlatformFunctionInvocationAttempt', + 'deletePlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + { + id: args.where.id, + createdAt: args.where.createdAt, + }, + 'DeletePlatformFunctionInvocationAttemptInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'deletePlatformFunctionInvocationAttempt', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/compute/orm/models/platformResourceDeclaredCapacity.ts b/sdk/constructive-cli/src/compute/orm/models/platformResourceDeclaredCapacity.ts new file mode 100644 index 000000000..66a88f859 --- /dev/null +++ b/sdk/constructive-cli/src/compute/orm/models/platformResourceDeclaredCapacity.ts @@ -0,0 +1,154 @@ +/** + * PlatformResourceDeclaredCapacity model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformResourceDeclaredCapacity, + PlatformResourceDeclaredCapacityWithRelations, + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy, + CreatePlatformResourceDeclaredCapacityInput, + UpdatePlatformResourceDeclaredCapacityInput, + PlatformResourceDeclaredCapacityPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformResourceDeclaredCapacityModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformResourceDeclaredCapacityFilter', + 'PlatformResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'platformResourceDeclaredCapacities', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformResourceDeclaredCapacityFilter', + 'PlatformResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'platformResourceDeclaredCapacity', + document, + variables, + transform: (data: { + platformResourceDeclaredCapacities?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformResourceDeclaredCapacity: + data.platformResourceDeclaredCapacities?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs< + S, + CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity'] + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformResourceDeclaredCapacity: { + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + >; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformResourceDeclaredCapacity', + 'createPlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacity', + args.select, + args.data, + 'CreatePlatformResourceDeclaredCapacityInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'createPlatformResourceDeclaredCapacity', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/compute/orm/models/platformResourceUtilization.ts b/sdk/constructive-cli/src/compute/orm/models/platformResourceUtilization.ts new file mode 100644 index 000000000..040d38000 --- /dev/null +++ b/sdk/constructive-cli/src/compute/orm/models/platformResourceUtilization.ts @@ -0,0 +1,143 @@ +/** + * PlatformResourceUtilization model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformResourceUtilization, + PlatformResourceUtilizationWithRelations, + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy, + CreatePlatformResourceUtilizationInput, + UpdatePlatformResourceUtilizationInput, + PlatformResourceUtilizationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformResourceUtilizationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceUtilizations: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformResourceUtilization', + 'platformResourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformResourceUtilizationFilter', + 'PlatformResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceUtilization', + fieldName: 'platformResourceUtilizations', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceUtilization: InferSelectResult< + PlatformResourceUtilizationWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformResourceUtilization', + 'platformResourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformResourceUtilizationFilter', + 'PlatformResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceUtilization', + fieldName: 'platformResourceUtilization', + document, + variables, + transform: (data: { + platformResourceUtilizations?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformResourceUtilization: data.platformResourceUtilizations?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformResourceUtilization: { + platformResourceUtilization: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformResourceUtilization', + 'createPlatformResourceUtilization', + 'platformResourceUtilization', + args.select, + args.data, + 'CreatePlatformResourceUtilizationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformResourceUtilization', + fieldName: 'createPlatformResourceUtilization', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/compute/orm/models/platformResourceUtilizationDaily.ts b/sdk/constructive-cli/src/compute/orm/models/platformResourceUtilizationDaily.ts deleted file mode 100644 index e142f1f50..000000000 --- a/sdk/constructive-cli/src/compute/orm/models/platformResourceUtilizationDaily.ts +++ /dev/null @@ -1,154 +0,0 @@ -/** - * PlatformResourceUtilizationDaily model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - PlatformResourceUtilizationDaily, - PlatformResourceUtilizationDailyWithRelations, - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy, - CreatePlatformResourceUtilizationDailyInput, - UpdatePlatformResourceUtilizationDailyInput, - PlatformResourceUtilizationDailyPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class PlatformResourceUtilizationDailyModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformResourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'PlatformResourceUtilizationDaily', - 'platformResourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'PlatformResourceUtilizationDailyFilter', - 'PlatformResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'platformResourceUtilizationDailies', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - > | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'PlatformResourceUtilizationDaily', - 'platformResourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'PlatformResourceUtilizationDailyFilter', - 'PlatformResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'platformResourceUtilizationDaily', - document, - variables, - transform: (data: { - platformResourceUtilizationDailies?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - platformResourceUtilizationDaily: - data.platformResourceUtilizationDailies?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs< - S, - CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily'] - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createPlatformResourceUtilizationDaily: { - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - >; - }; - }> { - const { document, variables } = buildCreateDocument( - 'PlatformResourceUtilizationDaily', - 'createPlatformResourceUtilizationDaily', - 'platformResourceUtilizationDaily', - args.select, - args.data, - 'CreatePlatformResourceUtilizationDailyInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'createPlatformResourceUtilizationDaily', - document, - variables, - }); - } -} diff --git a/sdk/constructive-cli/src/compute/orm/models/resourceDeclaredCapacity.ts b/sdk/constructive-cli/src/compute/orm/models/resourceDeclaredCapacity.ts new file mode 100644 index 000000000..6340979a9 --- /dev/null +++ b/sdk/constructive-cli/src/compute/orm/models/resourceDeclaredCapacity.ts @@ -0,0 +1,136 @@ +/** + * ResourceDeclaredCapacity model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ResourceDeclaredCapacity, + ResourceDeclaredCapacityWithRelations, + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy, + CreateResourceDeclaredCapacityInput, + UpdateResourceDeclaredCapacityInput, + ResourceDeclaredCapacityPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ResourceDeclaredCapacityModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'ResourceDeclaredCapacity', + 'resourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ResourceDeclaredCapacityFilter', + 'ResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'resourceDeclaredCapacities', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceDeclaredCapacity: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ResourceDeclaredCapacity', + 'resourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ResourceDeclaredCapacityFilter', + 'ResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'resourceDeclaredCapacity', + document, + variables, + transform: (data: { + resourceDeclaredCapacities?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + resourceDeclaredCapacity: data.resourceDeclaredCapacities?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createResourceDeclaredCapacity: { + resourceDeclaredCapacity: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ResourceDeclaredCapacity', + 'createResourceDeclaredCapacity', + 'resourceDeclaredCapacity', + args.select, + args.data, + 'CreateResourceDeclaredCapacityInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'createResourceDeclaredCapacity', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/compute/orm/models/resourceUtilization.ts b/sdk/constructive-cli/src/compute/orm/models/resourceUtilization.ts new file mode 100644 index 000000000..362048600 --- /dev/null +++ b/sdk/constructive-cli/src/compute/orm/models/resourceUtilization.ts @@ -0,0 +1,134 @@ +/** + * ResourceUtilization model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ResourceUtilization, + ResourceUtilizationWithRelations, + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy, + CreateResourceUtilizationInput, + UpdateResourceUtilizationInput, + ResourceUtilizationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ResourceUtilizationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceUtilizations: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'ResourceUtilization', + 'resourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ResourceUtilizationFilter', + 'ResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceUtilization', + fieldName: 'resourceUtilizations', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceUtilization: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ResourceUtilization', + 'resourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ResourceUtilizationFilter', + 'ResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceUtilization', + fieldName: 'resourceUtilization', + document, + variables, + transform: (data: { + resourceUtilizations?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + resourceUtilization: data.resourceUtilizations?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createResourceUtilization: { + resourceUtilization: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ResourceUtilization', + 'createResourceUtilization', + 'resourceUtilization', + args.select, + args.data, + 'CreateResourceUtilizationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ResourceUtilization', + fieldName: 'createResourceUtilization', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/compute/orm/models/resourceUtilizationDaily.ts b/sdk/constructive-cli/src/compute/orm/models/resourceUtilizationDaily.ts deleted file mode 100644 index 8307b4adc..000000000 --- a/sdk/constructive-cli/src/compute/orm/models/resourceUtilizationDaily.ts +++ /dev/null @@ -1,136 +0,0 @@ -/** - * ResourceUtilizationDaily model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - ResourceUtilizationDaily, - ResourceUtilizationDailyWithRelations, - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy, - CreateResourceUtilizationDailyInput, - UpdateResourceUtilizationDailyInput, - ResourceUtilizationDailyPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class ResourceUtilizationDailyModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - resourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'ResourceUtilizationDaily', - 'resourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'ResourceUtilizationDailyFilter', - 'ResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'ResourceUtilizationDaily', - fieldName: 'resourceUtilizationDailies', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - resourceUtilizationDaily: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'ResourceUtilizationDaily', - 'resourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'ResourceUtilizationDailyFilter', - 'ResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'ResourceUtilizationDaily', - fieldName: 'resourceUtilizationDaily', - document, - variables, - transform: (data: { - resourceUtilizationDailies?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - resourceUtilizationDaily: data.resourceUtilizationDailies?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createResourceUtilizationDaily: { - resourceUtilizationDaily: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'ResourceUtilizationDaily', - 'createResourceUtilizationDaily', - 'resourceUtilizationDaily', - args.select, - args.data, - 'CreateResourceUtilizationDailyInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'ResourceUtilizationDaily', - fieldName: 'createResourceUtilizationDaily', - document, - variables, - }); - } -} diff --git a/sdk/constructive-cli/src/modules/README.md b/sdk/constructive-cli/src/modules/README.md index 99d73c3b6..259bc3966 100644 --- a/sdk/constructive-cli/src/modules/README.md +++ b/sdk/constructive-cli/src/modules/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 68 +- **Tables:** 74 - **Custom queries:** 2 - **Custom mutations:** 10 diff --git a/sdk/constructive-cli/src/modules/cli/README.md b/sdk/constructive-cli/src/modules/cli/README.md index 5f3ad8765..e697f455b 100644 --- a/sdk/constructive-cli/src/modules/cli/README.md +++ b/sdk/constructive-cli/src/modules/cli/README.md @@ -27,11 +27,14 @@ csdk auth set-token | `auth` | Manage authentication tokens | | `config` | Manage config key-value store (per-context) | | `agent-module` | agentModule CRUD operations | +| `api-surface-module` | apiSurfaceModule CRUD operations | +| `app-module` | appModule CRUD operations | | `billing-module` | billingModule CRUD operations | | `billing-provider-module` | billingProviderModule CRUD operations | | `blueprint` | blueprint CRUD operations | | `blueprint-construction` | blueprintConstruction CRUD operations | | `blueprint-template` | blueprintTemplate CRUD operations | +| `catalog-module` | catalogModule CRUD operations | | `compute-log-module` | computeLogModule CRUD operations | | `config-secrets-user-module` | configSecretsUserModule CRUD operations | | `connected-accounts-module` | connectedAccountsModule CRUD operations | @@ -45,6 +48,7 @@ csdk auth set-token | `default-ids-module` | defaultIdsModule CRUD operations | | `denormalized-table-field` | denormalizedTableField CRUD operations | | `devices-module` | devicesModule CRUD operations | +| `domain-module` | domainModule CRUD operations | | `emails-module` | emailsModule CRUD operations | | `entity-type-provision` | entityTypeProvision CRUD operations | | `events-module` | eventsModule CRUD operations | @@ -80,9 +84,11 @@ csdk auth set-token | `relation-provision` | relationProvision CRUD operations | | `resource-module` | resourceModule CRUD operations | | `rls-module` | rlsModule CRUD operations | +| `route-module` | routeModule CRUD operations | | `secure-table-provision` | secureTableProvision CRUD operations | | `session-secrets-module` | sessionSecretsModule CRUD operations | | `sessions-module` | sessionsModule CRUD operations | +| `site-surface-module` | siteSurfaceModule CRUD operations | | `storage-log-module` | storageLogModule CRUD operations | | `storage-module` | storageModule CRUD operations | | `transfer-log-module` | transferLogModule CRUD operations | @@ -208,6 +214,84 @@ CRUD operations for AgentModule records. **Required create fields:** `databaseId` **Optional create fields (backend defaults):** `agentTableId`, `agentTableName`, `apiName`, `defaultPermissions`, `entityField`, `entityTableId`, `hasAgents`, `hasPlans`, `hasResources`, `messageTableId`, `messageTableName`, `personaTableId`, `personaTableName`, `planTableId`, `planTableName`, `policies`, `prefix`, `privateApiName`, `privateSchemaId`, `privateSchemaName`, `promptsTableId`, `promptsTableName`, `provisions`, `publicSchemaName`, `resourceTableId`, `resourceTableName`, `resources`, `schemaId`, `scope`, `shared`, `taskTableId`, `taskTableName`, `threadTableId`, `threadTableName` +### `api-surface-module` + +CRUD operations for ApiSurfaceModule records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all apiSurfaceModule records | +| `find-first` | Find first matching apiSurfaceModule record | +| `get` | Get a apiSurfaceModule by id | +| `create` | Create a new apiSurfaceModule | +| `update` | Update an existing apiSurfaceModule | +| `delete` | Delete a apiSurfaceModule | + +**Fields:** + +| Field | Type | +|-------|------| +| `apiName` | String | +| `apisTableId` | UUID | +| `apisTableName` | String | +| `catalogModuleId` | UUID | +| `databaseId` | UUID | +| `defaultPermissions` | String | +| `entityField` | String | +| `entityTableId` | UUID | +| `id` | UUID | +| `policies` | JSON | +| `prefix` | String | +| `privateApiName` | String | +| `provisions` | JSON | +| `publicSchemaName` | String | +| `schemaId` | UUID | +| `scope` | String | + +**Required create fields:** `databaseId` +**Optional create fields (backend defaults):** `apiName`, `apisTableId`, `apisTableName`, `catalogModuleId`, `defaultPermissions`, `entityField`, `entityTableId`, `policies`, `prefix`, `privateApiName`, `provisions`, `publicSchemaName`, `schemaId`, `scope` + +### `app-module` + +CRUD operations for AppModule records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all appModule records | +| `find-first` | Find first matching appModule record | +| `get` | Get a appModule by id | +| `create` | Create a new appModule | +| `update` | Update an existing appModule | +| `delete` | Delete a appModule | + +**Fields:** + +| Field | Type | +|-------|------| +| `apiName` | String | +| `appMembersTableId` | UUID | +| `appMembersTableName` | String | +| `appsTableId` | UUID | +| `appsTableName` | String | +| `catalogModuleId` | UUID | +| `databaseId` | UUID | +| `defaultPermissions` | String | +| `entityField` | String | +| `entityTableId` | UUID | +| `id` | UUID | +| `policies` | JSON | +| `prefix` | String | +| `privateApiName` | String | +| `privateSchemaId` | UUID | +| `privateSchemaName` | String | +| `provisions` | JSON | +| `publicSchemaName` | String | +| `schemaId` | UUID | +| `scope` | String | + +**Required create fields:** `databaseId` +**Optional create fields (backend defaults):** `apiName`, `appMembersTableId`, `appMembersTableName`, `appsTableId`, `appsTableName`, `catalogModuleId`, `defaultPermissions`, `entityField`, `entityTableId`, `policies`, `prefix`, `privateApiName`, `privateSchemaId`, `privateSchemaName`, `provisions`, `publicSchemaName`, `schemaId`, `scope` + ### `billing-module` CRUD operations for BillingModule records. @@ -405,6 +489,56 @@ CRUD operations for BlueprintTemplate records. **Required create fields:** `definition`, `displayName`, `name`, `ownerId` **Optional create fields (backend defaults):** `categories`, `complexity`, `copyCount`, `definitionHash`, `definitionSchemaVersion`, `description`, `forkCount`, `forkedFromId`, `source`, `tableHashes`, `tags`, `version`, `visibility` +### `catalog-module` + +CRUD operations for CatalogModule records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all catalogModule records | +| `find-first` | Find first matching catalogModule record | +| `get` | Get a catalogModule by id | +| `create` | Create a new catalogModule | +| `update` | Update an existing catalogModule | +| `delete` | Delete a catalogModule | + +**Fields:** + +| Field | Type | +|-------|------| +| `apiName` | String | +| `apisTableId` | UUID | +| `apisTableName` | String | +| `appsTableId` | UUID | +| `appsTableName` | String | +| `databaseId` | UUID | +| `defaultPermissions` | String | +| `domainsTableId` | UUID | +| `domainsTableName` | String | +| `entityTableId` | UUID | +| `functionsTableId` | UUID | +| `functionsTableName` | String | +| `id` | UUID | +| `namespacesTableId` | UUID | +| `namespacesTableName` | String | +| `policies` | JSON | +| `privateApiName` | String | +| `provisions` | JSON | +| `publicSchemaName` | String | +| `resourceDefinitionsTableId` | UUID | +| `resourceDefinitionsTableName` | String | +| `resourceInstallationsTableId` | UUID | +| `resourceInstallationsTableName` | String | +| `resourcesTableId` | UUID | +| `resourcesTableName` | String | +| `schemaId` | UUID | +| `scope` | String | +| `sitesTableId` | UUID | +| `sitesTableName` | String | + +**Required create fields:** `databaseId` +**Optional create fields (backend defaults):** `apiName`, `apisTableId`, `apisTableName`, `appsTableId`, `appsTableName`, `defaultPermissions`, `domainsTableId`, `domainsTableName`, `entityTableId`, `functionsTableId`, `functionsTableName`, `namespacesTableId`, `namespacesTableName`, `policies`, `privateApiName`, `provisions`, `publicSchemaName`, `resourceDefinitionsTableId`, `resourceDefinitionsTableName`, `resourceInstallationsTableId`, `resourceInstallationsTableName`, `resourcesTableId`, `resourcesTableName`, `schemaId`, `scope`, `sitesTableId`, `sitesTableName` + ### `compute-log-module` CRUD operations for ComputeLogModule records. @@ -588,6 +722,7 @@ CRUD operations for DatabaseProvisionModule records. | Field | Type | |-------|------| +| `async` | Boolean | | `bootstrapError` | String | | `bootstrapStatus` | String | | `bootstrapUser` | Boolean | @@ -608,7 +743,7 @@ CRUD operations for DatabaseProvisionModule records. | `updatedAt` | Datetime | **Required create fields:** `databaseName`, `domain`, `ownerId` -**Optional create fields (backend defaults):** `bootstrapError`, `bootstrapStatus`, `bootstrapUser`, `completedAt`, `databaseId`, `errorMessage`, `fulfilledAt`, `modules`, `options`, `sourceDatabaseId`, `status`, `subdomain` +**Optional create fields (backend defaults):** `async`, `bootstrapError`, `bootstrapStatus`, `bootstrapUser`, `completedAt`, `databaseId`, `errorMessage`, `fulfilledAt`, `modules`, `options`, `sourceDatabaseId`, `status`, `subdomain` ### `db-pool-config` @@ -844,6 +979,47 @@ CRUD operations for DevicesModule records. **Required create fields:** `databaseId` **Optional create fields (backend defaults):** `deviceSettingsTableId`, `deviceSettingsTableName`, `schemaId`, `userDevicesTableId`, `userDevicesTableName` +### `domain-module` + +CRUD operations for DomainModule records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all domainModule records | +| `find-first` | Find first matching domainModule record | +| `get` | Get a domainModule by id | +| `create` | Create a new domainModule | +| `update` | Update an existing domainModule | +| `delete` | Delete a domainModule | + +**Fields:** + +| Field | Type | +|-------|------| +| `apiName` | String | +| `catalogModuleId` | UUID | +| `databaseId` | UUID | +| `defaultPermissions` | String | +| `domainEventsTableId` | UUID | +| `domainEventsTableName` | String | +| `domainVerificationsTableId` | UUID | +| `domainVerificationsTableName` | String | +| `domainsTableId` | UUID | +| `domainsTableName` | String | +| `entityField` | String | +| `entityTableId` | UUID | +| `id` | UUID | +| `policies` | JSON | +| `prefix` | String | +| `privateApiName` | String | +| `provisions` | JSON | +| `publicSchemaName` | String | +| `schemaId` | UUID | +| `scope` | String | + +**Required create fields:** `databaseId` +**Optional create fields (backend defaults):** `apiName`, `catalogModuleId`, `defaultPermissions`, `domainEventsTableId`, `domainEventsTableName`, `domainVerificationsTableId`, `domainVerificationsTableName`, `domainsTableId`, `domainsTableName`, `entityField`, `entityTableId`, `policies`, `prefix`, `privateApiName`, `provisions`, `publicSchemaName`, `schemaId`, `scope` + ### `emails-module` CRUD operations for EmailsModule records. @@ -1059,6 +1235,8 @@ CRUD operations for FunctionInvocationModule records. | Field | Type | |-------|------| | `apiName` | String | +| `attemptsTableId` | UUID | +| `attemptsTableName` | String | | `databaseId` | UUID | | `defaultPermissions` | String | | `entityField` | String | @@ -1079,7 +1257,7 @@ CRUD operations for FunctionInvocationModule records. | `scope` | String | **Required create fields:** `databaseId` -**Optional create fields (backend defaults):** `apiName`, `defaultPermissions`, `entityField`, `entityTableId`, `executionLogsTableId`, `executionLogsTableName`, `invocationsTableId`, `invocationsTableName`, `policies`, `prefix`, `privateApiName`, `privateSchemaId`, `privateSchemaName`, `provisions`, `publicSchemaName`, `schemaId`, `scope` +**Optional create fields (backend defaults):** `apiName`, `attemptsTableId`, `attemptsTableName`, `defaultPermissions`, `entityField`, `entityTableId`, `executionLogsTableId`, `executionLogsTableName`, `invocationsTableId`, `invocationsTableName`, `policies`, `prefix`, `privateApiName`, `privateSchemaId`, `privateSchemaName`, `provisions`, `publicSchemaName`, `schemaId`, `scope` ### `function-module` @@ -2292,6 +2470,51 @@ CRUD operations for RlsModule records. **Required create fields:** `databaseId` **Optional create fields (backend defaults):** `apiName`, `authenticate`, `authenticateStrict`, `currentRole`, `currentRoleId`, `privateApiName`, `privateSchemaId`, `schemaId`, `sessionCredentialsTableId`, `sessionsTableId`, `usersTableId` +### `route-module` + +CRUD operations for RouteModule records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all routeModule records | +| `find-first` | Find first matching routeModule record | +| `get` | Get a routeModule by id | +| `create` | Create a new routeModule | +| `update` | Update an existing routeModule | +| `delete` | Delete a routeModule | + +**Fields:** + +| Field | Type | +|-------|------| +| `apiName` | String | +| `catalogModuleId` | UUID | +| `databaseId` | UUID | +| `defaultPermissions` | String | +| `domainModuleId` | UUID | +| `entityField` | String | +| `entityTableId` | UUID | +| `hostnameBindingsTableId` | UUID | +| `hostnameBindingsTableName` | String | +| `id` | UUID | +| `policies` | JSON | +| `prefix` | String | +| `privateApiName` | String | +| `privateSchemaId` | UUID | +| `privateSchemaName` | String | +| `provisions` | JSON | +| `publicSchemaName` | String | +| `resolverFunctionName` | String | +| `routeBindingsTableId` | UUID | +| `routeBindingsTableName` | String | +| `routesTableId` | UUID | +| `routesTableName` | String | +| `schemaId` | UUID | +| `scope` | String | + +**Required create fields:** `databaseId` +**Optional create fields (backend defaults):** `apiName`, `catalogModuleId`, `defaultPermissions`, `domainModuleId`, `entityField`, `entityTableId`, `hostnameBindingsTableId`, `hostnameBindingsTableName`, `policies`, `prefix`, `privateApiName`, `privateSchemaId`, `privateSchemaName`, `provisions`, `publicSchemaName`, `resolverFunctionName`, `routeBindingsTableId`, `routeBindingsTableName`, `routesTableId`, `routesTableName`, `schemaId`, `scope` + ### `secure-table-provision` CRUD operations for SecureTableProvision records. @@ -2383,6 +2606,43 @@ CRUD operations for SessionsModule records. **Required create fields:** `databaseId` **Optional create fields (backend defaults):** `authSettingsTableId`, `authSettingsTableName`, `schemaId`, `sessionCredentialsTableId`, `sessionCredentialsTableName`, `sessionsDefaultExpiration`, `sessionsTableId`, `sessionsTableName`, `usersTableId` +### `site-surface-module` + +CRUD operations for SiteSurfaceModule records. + +| Subcommand | Description | +|------------|-------------| +| `list` | List all siteSurfaceModule records | +| `find-first` | Find first matching siteSurfaceModule record | +| `get` | Get a siteSurfaceModule by id | +| `create` | Create a new siteSurfaceModule | +| `update` | Update an existing siteSurfaceModule | +| `delete` | Delete a siteSurfaceModule | + +**Fields:** + +| Field | Type | +|-------|------| +| `apiName` | String | +| `catalogModuleId` | UUID | +| `databaseId` | UUID | +| `defaultPermissions` | String | +| `entityField` | String | +| `entityTableId` | UUID | +| `id` | UUID | +| `policies` | JSON | +| `prefix` | String | +| `privateApiName` | String | +| `provisions` | JSON | +| `publicSchemaName` | String | +| `schemaId` | UUID | +| `scope` | String | +| `sitesTableId` | UUID | +| `sitesTableName` | String | + +**Required create fields:** `databaseId` +**Optional create fields (backend defaults):** `apiName`, `catalogModuleId`, `defaultPermissions`, `entityField`, `entityTableId`, `policies`, `prefix`, `privateApiName`, `provisions`, `publicSchemaName`, `schemaId`, `scope`, `sitesTableId`, `sitesTableName` + ### `storage-log-module` CRUD operations for StorageLogModule records. @@ -2955,14 +3215,14 @@ Idempotent provisioner for metaschema_public.spatial_relation. Inserts a row dec | Argument | Type | |----------|------| | `--input.clientMutationId` | String | - | `--input.pDatabaseId` | UUID | - | `--input.pName` | String | - | `--input.pOperator` | String | - | `--input.pParamName` | String | - | `--input.pSourceFieldId` | UUID | - | `--input.pSourceTableId` | UUID | - | `--input.pTargetFieldId` | UUID | - | `--input.pTargetTableId` | UUID | + | `--input.databaseId` | UUID | + | `--input.name` | String | + | `--input.operator` | String | + | `--input.paramName` | String | + | `--input.sourceFieldId` | UUID | + | `--input.sourceTableId` | UUID | + | `--input.targetFieldId` | UUID | + | `--input.targetTableId` | UUID | ### `provision-table` diff --git a/sdk/constructive-cli/src/modules/cli/commands.ts b/sdk/constructive-cli/src/modules/cli/commands.ts index 7cd90f295..596439b86 100644 --- a/sdk/constructive-cli/src/modules/cli/commands.ts +++ b/sdk/constructive-cli/src/modules/cli/commands.ts @@ -7,11 +7,14 @@ import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; import contextCmd from './commands/context'; import authCmd from './commands/auth'; import agentModuleCmd from './commands/agent-module'; +import apiSurfaceModuleCmd from './commands/api-surface-module'; +import appModuleCmd from './commands/app-module'; import billingModuleCmd from './commands/billing-module'; import billingProviderModuleCmd from './commands/billing-provider-module'; import blueprintCmd from './commands/blueprint'; import blueprintConstructionCmd from './commands/blueprint-construction'; import blueprintTemplateCmd from './commands/blueprint-template'; +import catalogModuleCmd from './commands/catalog-module'; import computeLogModuleCmd from './commands/compute-log-module'; import configSecretsUserModuleCmd from './commands/config-secrets-user-module'; import connectedAccountsModuleCmd from './commands/connected-accounts-module'; @@ -25,6 +28,7 @@ import dbUsageModuleCmd from './commands/db-usage-module'; import defaultIdsModuleCmd from './commands/default-ids-module'; import denormalizedTableFieldCmd from './commands/denormalized-table-field'; import devicesModuleCmd from './commands/devices-module'; +import domainModuleCmd from './commands/domain-module'; import emailsModuleCmd from './commands/emails-module'; import entityTypeProvisionCmd from './commands/entity-type-provision'; import eventsModuleCmd from './commands/events-module'; @@ -60,9 +64,11 @@ import realtimeModuleCmd from './commands/realtime-module'; import relationProvisionCmd from './commands/relation-provision'; import resourceModuleCmd from './commands/resource-module'; import rlsModuleCmd from './commands/rls-module'; +import routeModuleCmd from './commands/route-module'; import secureTableProvisionCmd from './commands/secure-table-provision'; import sessionSecretsModuleCmd from './commands/session-secrets-module'; import sessionsModuleCmd from './commands/sessions-module'; +import siteSurfaceModuleCmd from './commands/site-surface-module'; import storageLogModuleCmd from './commands/storage-log-module'; import storageModuleCmd from './commands/storage-module'; import transferLogModuleCmd from './commands/transfer-log-module'; @@ -97,11 +103,14 @@ const createCommandMap: () => Record< context: contextCmd, auth: authCmd, 'agent-module': agentModuleCmd, + 'api-surface-module': apiSurfaceModuleCmd, + 'app-module': appModuleCmd, 'billing-module': billingModuleCmd, 'billing-provider-module': billingProviderModuleCmd, blueprint: blueprintCmd, 'blueprint-construction': blueprintConstructionCmd, 'blueprint-template': blueprintTemplateCmd, + 'catalog-module': catalogModuleCmd, 'compute-log-module': computeLogModuleCmd, 'config-secrets-user-module': configSecretsUserModuleCmd, 'connected-accounts-module': connectedAccountsModuleCmd, @@ -115,6 +124,7 @@ const createCommandMap: () => Record< 'default-ids-module': defaultIdsModuleCmd, 'denormalized-table-field': denormalizedTableFieldCmd, 'devices-module': devicesModuleCmd, + 'domain-module': domainModuleCmd, 'emails-module': emailsModuleCmd, 'entity-type-provision': entityTypeProvisionCmd, 'events-module': eventsModuleCmd, @@ -150,9 +160,11 @@ const createCommandMap: () => Record< 'relation-provision': relationProvisionCmd, 'resource-module': resourceModuleCmd, 'rls-module': rlsModuleCmd, + 'route-module': routeModuleCmd, 'secure-table-provision': secureTableProvisionCmd, 'session-secrets-module': sessionSecretsModuleCmd, 'sessions-module': sessionsModuleCmd, + 'site-surface-module': siteSurfaceModuleCmd, 'storage-log-module': storageLogModuleCmd, 'storage-module': storageModuleCmd, 'transfer-log-module': transferLogModuleCmd, @@ -178,7 +190,7 @@ const createCommandMap: () => Record< 'provision-unique-constraint': provisionUniqueConstraintCmd, }); const usage = - "\ncsdk \n\nCommands:\n context Manage API contexts\n auth Manage authentication\n agent-module agentModule CRUD operations\n billing-module billingModule CRUD operations\n billing-provider-module billingProviderModule CRUD operations\n blueprint blueprint CRUD operations\n blueprint-construction blueprintConstruction CRUD operations\n blueprint-template blueprintTemplate CRUD operations\n compute-log-module computeLogModule CRUD operations\n config-secrets-user-module configSecretsUserModule CRUD operations\n connected-accounts-module connectedAccountsModule CRUD operations\n crypto-addresses-module cryptoAddressesModule CRUD operations\n crypto-auth-module cryptoAuthModule CRUD operations\n database-provision-module databaseProvisionModule CRUD operations\n db-pool-config dbPoolConfig CRUD operations\n db-pool dbPool CRUD operations\n db-preset-module dbPresetModule CRUD operations\n db-usage-module dbUsageModule CRUD operations\n default-ids-module defaultIdsModule CRUD operations\n denormalized-table-field denormalizedTableField CRUD operations\n devices-module devicesModule CRUD operations\n emails-module emailsModule CRUD operations\n entity-type-provision entityTypeProvision CRUD operations\n events-module eventsModule CRUD operations\n function-deployment-module functionDeploymentModule CRUD operations\n function-invocation-module functionInvocationModule CRUD operations\n function-module functionModule CRUD operations\n graph-execution-module graphExecutionModule CRUD operations\n graph-module graphModule CRUD operations\n hierarchy-module hierarchyModule CRUD operations\n http-route-module httpRouteModule CRUD operations\n i-18-n-module i18NModule CRUD operations\n identity-providers-module identityProvidersModule CRUD operations\n inference-log-module inferenceLogModule CRUD operations\n infra-config-module infraConfigModule CRUD operations\n infra-secrets-module infraSecretsModule CRUD operations\n integration-providers-module integrationProvidersModule CRUD operations\n internal-secrets-module internalSecretsModule CRUD operations\n invites-module invitesModule CRUD operations\n limits-module limitsModule CRUD operations\n membership-types-module membershipTypesModule CRUD operations\n memberships-module membershipsModule CRUD operations\n merkle-store-module merkleStoreModule CRUD operations\n namespace-module namespaceModule CRUD operations\n notifications-module notificationsModule CRUD operations\n permissions-module permissionsModule CRUD operations\n phone-numbers-module phoneNumbersModule CRUD operations\n plans-module plansModule CRUD operations\n principal-auth-module principalAuthModule CRUD operations\n profiles-module profilesModule CRUD operations\n rate-limit-meters-module rateLimitMetersModule CRUD operations\n rate-limits-module rateLimitsModule CRUD operations\n realtime-module realtimeModule CRUD operations\n relation-provision relationProvision CRUD operations\n resource-module resourceModule CRUD operations\n rls-module rlsModule CRUD operations\n secure-table-provision secureTableProvision CRUD operations\n session-secrets-module sessionSecretsModule CRUD operations\n sessions-module sessionsModule CRUD operations\n storage-log-module storageLogModule CRUD operations\n storage-module storageModule CRUD operations\n transfer-log-module transferLogModule CRUD operations\n user-auth-module userAuthModule CRUD operations\n user-credentials-module userCredentialsModule CRUD operations\n user-settings-module userSettingsModule CRUD operations\n user-state-module userStateModule CRUD operations\n users-module usersModule CRUD operations\n webauthn-auth-module webauthnAuthModule CRUD operations\n webauthn-credentials-module webauthnCredentialsModule CRUD operations\n webhook-module webhookModule CRUD operations\n resolve-blueprint-field Resolves a field_name within a given table_id to a field_id. Throws if no match is found. Used by construct_blueprint to translate user-authored field names (e.g. \"location\") into field UUIDs for downstream provisioning procedures. table_id must already be resolved (via resolve_blueprint_table) before calling this.\n resolve-blueprint-table Resolves a table_name (with optional schema_name) to a table_id. Resolution order: (1) if schema_name provided, exact lookup via metaschema_public.schema.name + metaschema_public.table; (2) check local table_map (tables created in current blueprint); (3) search metaschema_public.table by name across all schemas; (4) if multiple matches, throw ambiguous error asking for schema_name; (5) if no match, throw not-found error.\n construct-blueprint Executes a blueprint definition by delegating to provision_* procedures. Creates a blueprint_construction record to track the attempt. Eight phases: (0) entity_type_provision for each membership_type entry \u2014 provisions entity tables, membership modules, and security. When a prefix already exists (e.g., 'org'), the entry extends the existing entity type instead of creating a new one; if a storage[] key is present, it provisions entity-scoped storage for that type. (0.5) scope-based storage: each storage[] entry has an optional scope ('app' or 'org' only). App-scoped storage seeds buckets at migration time. Org-scoped storage resolves the org membership type, creates org_buckets/org_files with owner_id, and seeds buckets per-entity via an AFTER INSERT trigger on the users table. When function_module is installed, a private functions bucket is auto-injected into org-scoped or entity-scoped storage entries. (1) provision_table() for each table with nodes[], fields[], policies[], and grants (table-level indexes/fts/unique_constraints/check_constraints are deferred). After provisioning, optional smart_tags (jsonb object) on the table entry are applied via metaschema.append_table_smart_tags(), and optional smart_tags on individual field entries are applied via metaschema.append_field_smart_tags(). (2) provision_relation() for each relation, (3) provision_index() for top-level + deferred indexes, (4) provision_full_text_search() for top-level + deferred FTS, (5) provision_unique_constraint() for top-level + deferred unique constraints, (6) provision_check_constraint() for top-level + deferred check constraints, (7) seed achievements from definition.achievements[] \u2014 resolves events_module by entity_prefix and creates INSERT actions for levels, level_requirements, and achievement_rewards tables. Phase 0 entity tables are added to the table_map so subsequent phases can reference them by name. Table-level entries are deferred to phases 3-6 so they can reference columns created by relations in phase 2. Returns the construction record ID on success, NULL on failure.\n copy-template-to-blueprint Creates a new blueprint by copying a template definition. Checks visibility: owners can always copy their own templates, others require public visibility. Increments the template copy_count. Returns the new blueprint ID.\n provision-bucket Provision an S3 bucket for a logical bucket in the database.\nReads the bucket config via RLS, then creates and configures\nthe S3 bucket with the appropriate privacy policies, CORS rules,\nand lifecycle settings.\n provision-check-constraint Creates a check constraint on a table from a $type + data blueprint definition. Supports: CheckOneOf (enum validation via = ANY(ARRAY[...])), CheckGreaterThan (single-column > value or cross-column), CheckLessThan (single-column < value or cross-column), CheckNotEqual (cross-column inequality). Builds AST expressions via ast_helpers and inserts into metaschema_public.check_constraint. Graceful: skips if a constraint with the same name already exists.\n provision-full-text-search Creates a full-text search configuration on a table. Accepts a jsonb definition with field (tsvector column name) and sources (array of {field, weight, lang}). Graceful: skips if FTS config already exists for the same (table_id, field_id). Returns the fts_id.\n provision-index Creates an index on a table. Accepts a jsonb definition with columns (array of names or single column string), access_method (default BTREE), is_unique, op_classes, options, and name (auto-generated if omitted). Graceful: skips if an index with the same (table_id, field_ids, access_method) already exists. Returns the index_id.\n provision-relation Composable relation provisioning: creates FK fields, indexes, unique constraints, and junction tables depending on the relation_type. Supports RelationBelongsTo, RelationHasOne, RelationHasMany, and RelationManyToMany. ManyToMany uses provision_table() internally for junction table creation with full node/grant/policy support. All operations are graceful (skip existing). Returns (out_field_id, out_junction_table_id, out_source_field_id, out_target_field_id).\n provision-spatial-relation Idempotent provisioner for metaschema_public.spatial_relation. Inserts a row declaring a spatial predicate between two geometry/geography columns (owner and target). Called from construct_blueprint when a relation entry has $type=RelationSpatial. Graceful: re-running with the same (source_table_id, name) returns the existing id without modifying the row. Operator whitelist and st_dwithin \u2194 param_name pairing are enforced by the spatial_relation table CHECKs. Both fields must already exist \u2014 this is a metadata-only insert.\n provision-table Composable table provisioning: creates or finds a table, then creates fields (so Data* modules can reference them), applies N nodes (Data* modules), enables RLS, creates grants, creates N policies, and optionally creates table-level indexes/full_text_searches/unique_constraints. All operations are graceful (skip existing). Accepts multiple nodes and multiple policies per call, unlike secure_table_provision which is limited to one of each. Returns (out_table_id, out_fields).\n provision-unique-constraint Creates a unique constraint on a table. Accepts a jsonb definition with columns (array of field names). Graceful: skips if the exact same unique constraint already exists.\n\n --help, -h Show this help message\n --version, -v Show version\n"; + "\ncsdk \n\nCommands:\n context Manage API contexts\n auth Manage authentication\n agent-module agentModule CRUD operations\n api-surface-module apiSurfaceModule CRUD operations\n app-module appModule CRUD operations\n billing-module billingModule CRUD operations\n billing-provider-module billingProviderModule CRUD operations\n blueprint blueprint CRUD operations\n blueprint-construction blueprintConstruction CRUD operations\n blueprint-template blueprintTemplate CRUD operations\n catalog-module catalogModule CRUD operations\n compute-log-module computeLogModule CRUD operations\n config-secrets-user-module configSecretsUserModule CRUD operations\n connected-accounts-module connectedAccountsModule CRUD operations\n crypto-addresses-module cryptoAddressesModule CRUD operations\n crypto-auth-module cryptoAuthModule CRUD operations\n database-provision-module databaseProvisionModule CRUD operations\n db-pool-config dbPoolConfig CRUD operations\n db-pool dbPool CRUD operations\n db-preset-module dbPresetModule CRUD operations\n db-usage-module dbUsageModule CRUD operations\n default-ids-module defaultIdsModule CRUD operations\n denormalized-table-field denormalizedTableField CRUD operations\n devices-module devicesModule CRUD operations\n domain-module domainModule CRUD operations\n emails-module emailsModule CRUD operations\n entity-type-provision entityTypeProvision CRUD operations\n events-module eventsModule CRUD operations\n function-deployment-module functionDeploymentModule CRUD operations\n function-invocation-module functionInvocationModule CRUD operations\n function-module functionModule CRUD operations\n graph-execution-module graphExecutionModule CRUD operations\n graph-module graphModule CRUD operations\n hierarchy-module hierarchyModule CRUD operations\n http-route-module httpRouteModule CRUD operations\n i-18-n-module i18NModule CRUD operations\n identity-providers-module identityProvidersModule CRUD operations\n inference-log-module inferenceLogModule CRUD operations\n infra-config-module infraConfigModule CRUD operations\n infra-secrets-module infraSecretsModule CRUD operations\n integration-providers-module integrationProvidersModule CRUD operations\n internal-secrets-module internalSecretsModule CRUD operations\n invites-module invitesModule CRUD operations\n limits-module limitsModule CRUD operations\n membership-types-module membershipTypesModule CRUD operations\n memberships-module membershipsModule CRUD operations\n merkle-store-module merkleStoreModule CRUD operations\n namespace-module namespaceModule CRUD operations\n notifications-module notificationsModule CRUD operations\n permissions-module permissionsModule CRUD operations\n phone-numbers-module phoneNumbersModule CRUD operations\n plans-module plansModule CRUD operations\n principal-auth-module principalAuthModule CRUD operations\n profiles-module profilesModule CRUD operations\n rate-limit-meters-module rateLimitMetersModule CRUD operations\n rate-limits-module rateLimitsModule CRUD operations\n realtime-module realtimeModule CRUD operations\n relation-provision relationProvision CRUD operations\n resource-module resourceModule CRUD operations\n rls-module rlsModule CRUD operations\n route-module routeModule CRUD operations\n secure-table-provision secureTableProvision CRUD operations\n session-secrets-module sessionSecretsModule CRUD operations\n sessions-module sessionsModule CRUD operations\n site-surface-module siteSurfaceModule CRUD operations\n storage-log-module storageLogModule CRUD operations\n storage-module storageModule CRUD operations\n transfer-log-module transferLogModule CRUD operations\n user-auth-module userAuthModule CRUD operations\n user-credentials-module userCredentialsModule CRUD operations\n user-settings-module userSettingsModule CRUD operations\n user-state-module userStateModule CRUD operations\n users-module usersModule CRUD operations\n webauthn-auth-module webauthnAuthModule CRUD operations\n webauthn-credentials-module webauthnCredentialsModule CRUD operations\n webhook-module webhookModule CRUD operations\n resolve-blueprint-field Resolves a field_name within a given table_id to a field_id. Throws if no match is found. Used by construct_blueprint to translate user-authored field names (e.g. \"location\") into field UUIDs for downstream provisioning procedures. table_id must already be resolved (via resolve_blueprint_table) before calling this.\n resolve-blueprint-table Resolves a table_name (with optional schema_name) to a table_id. Resolution order: (1) if schema_name provided, exact lookup via metaschema_public.schema.name + metaschema_public.table; (2) check local table_map (tables created in current blueprint); (3) search metaschema_public.table by name across all schemas; (4) if multiple matches, throw ambiguous error asking for schema_name; (5) if no match, throw not-found error.\n construct-blueprint Executes a blueprint definition by delegating to provision_* procedures. Creates a blueprint_construction record to track the attempt. Eight phases: (0) entity_type_provision for each membership_type entry \u2014 provisions entity tables, membership modules, and security. When a prefix already exists (e.g., 'org'), the entry extends the existing entity type instead of creating a new one; if a storage[] key is present, it provisions entity-scoped storage for that type. (0.5) scope-based storage: each storage[] entry has an optional scope ('app' or 'org' only). App-scoped storage seeds buckets at migration time. Org-scoped storage resolves the org membership type, creates org_buckets/org_files with owner_id, and seeds buckets per-entity via an AFTER INSERT trigger on the users table. When function_module is installed, a private functions bucket is auto-injected into org-scoped or entity-scoped storage entries. (1) provision_table() for each table with nodes[], fields[], policies[], and grants (table-level indexes/fts/unique_constraints/check_constraints are deferred). After provisioning, optional smart_tags (jsonb object) on the table entry are applied via metaschema.append_table_smart_tags(), and optional smart_tags on individual field entries are applied via metaschema.append_field_smart_tags(). (2) provision_relation() for each relation, (3) provision_index() for top-level + deferred indexes, (4) provision_full_text_search() for top-level + deferred FTS, (5) provision_unique_constraint() for top-level + deferred unique constraints, (6) provision_check_constraint() for top-level + deferred check constraints, (7) seed achievements from definition.achievements[] \u2014 resolves events_module by entity_prefix and creates INSERT actions for levels, level_requirements, and achievement_rewards tables. Phase 0 entity tables are added to the table_map so subsequent phases can reference them by name. Table-level entries are deferred to phases 3-6 so they can reference columns created by relations in phase 2. Returns the construction record ID on success, NULL on failure.\n copy-template-to-blueprint Creates a new blueprint by copying a template definition. Checks visibility: owners can always copy their own templates, others require public visibility. Increments the template copy_count. Returns the new blueprint ID.\n provision-bucket Provision an S3 bucket for a logical bucket in the database.\nReads the bucket config via RLS, then creates and configures\nthe S3 bucket with the appropriate privacy policies, CORS rules,\nand lifecycle settings.\n provision-check-constraint Creates a check constraint on a table from a $type + data blueprint definition. Supports: CheckOneOf (enum validation via = ANY(ARRAY[...])), CheckGreaterThan (single-column > value or cross-column), CheckLessThan (single-column < value or cross-column), CheckNotEqual (cross-column inequality). Builds AST expressions via ast_helpers and inserts into metaschema_public.check_constraint. Graceful: skips if a constraint with the same name already exists.\n provision-full-text-search Creates a full-text search configuration on a table. Accepts a jsonb definition with field (tsvector column name) and sources (array of {field, weight, lang}). Graceful: skips if FTS config already exists for the same (table_id, field_id). Returns the fts_id.\n provision-index Creates an index on a table. Accepts a jsonb definition with columns (array of names or single column string), access_method (default BTREE), is_unique, op_classes, options, and name (auto-generated if omitted). Graceful: skips if an index with the same (table_id, field_ids, access_method) already exists. Returns the index_id.\n provision-relation Composable relation provisioning: creates FK fields, indexes, unique constraints, and junction tables depending on the relation_type. Supports RelationBelongsTo, RelationHasOne, RelationHasMany, and RelationManyToMany. ManyToMany uses provision_table() internally for junction table creation with full node/grant/policy support. All operations are graceful (skip existing). Returns (out_field_id, out_junction_table_id, out_source_field_id, out_target_field_id).\n provision-spatial-relation Idempotent provisioner for metaschema_public.spatial_relation. Inserts a row declaring a spatial predicate between two geometry/geography columns (owner and target). Called from construct_blueprint when a relation entry has $type=RelationSpatial. Graceful: re-running with the same (source_table_id, name) returns the existing id without modifying the row. Operator whitelist and st_dwithin \u2194 param_name pairing are enforced by the spatial_relation table CHECKs. Both fields must already exist \u2014 this is a metadata-only insert.\n provision-table Composable table provisioning: creates or finds a table, then creates fields (so Data* modules can reference them), applies N nodes (Data* modules), enables RLS, creates grants, creates N policies, and optionally creates table-level indexes/full_text_searches/unique_constraints. All operations are graceful (skip existing). Accepts multiple nodes and multiple policies per call, unlike secure_table_provision which is limited to one of each. Returns (out_table_id, out_fields).\n provision-unique-constraint Creates a unique constraint on a table. Accepts a jsonb definition with columns (array of field names). Graceful: skips if the exact same unique constraint already exists.\n\n --help, -h Show this help message\n --version, -v Show version\n"; export const commands = async ( argv: Partial>, prompter: Inquirerer, diff --git a/sdk/constructive-cli/src/modules/cli/commands/api-surface-module.ts b/sdk/constructive-cli/src/modules/cli/commands/api-surface-module.ts new file mode 100644 index 000000000..e99f39b82 --- /dev/null +++ b/sdk/constructive-cli/src/modules/cli/commands/api-surface-module.ts @@ -0,0 +1,559 @@ +/** + * CLI commands for ApiSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateApiSurfaceModuleInput, + ApiSurfaceModulePatch, + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + apiName: 'string', + apisTableId: 'uuid', + apisTableName: 'string', + catalogModuleId: 'uuid', + databaseId: 'uuid', + defaultPermissions: 'string', + entityField: 'string', + entityTableId: 'uuid', + id: 'uuid', + policies: 'json', + prefix: 'string', + privateApiName: 'string', + provisions: 'json', + publicSchemaName: 'string', + schemaId: 'uuid', + scope: 'string', +}; +const usage = + '\napi-surface-module \n\nCommands:\n list List apiSurfaceModule records\n find-first Find first matching apiSurfaceModule record\n get Get a apiSurfaceModule by ID\n create Create a new apiSurfaceModule\n update Update an existing apiSurfaceModule\n delete Delete a apiSurfaceModule\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + apisTableId: true, + apisTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs & { + select: ApiSurfaceModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.apiSurfaceModule.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + apisTableId: true, + apisTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs & { + select: ApiSurfaceModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.apiSurfaceModule.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.apiSurfaceModule + .findOne({ + id: answers.id as string, + select: { + apiName: true, + apisTableId: true, + apisTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableId', + message: 'apisTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableName', + message: 'apisTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: true, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateApiSurfaceModuleInput['apiSurfaceModule']; + const client = getClient(); + const result = await client.apiSurfaceModule + .create({ + data: { + apiName: cleanedData.apiName, + apisTableId: cleanedData.apisTableId, + apisTableName: cleanedData.apisTableName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + apisTableId: true, + apisTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableId', + message: 'apisTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableName', + message: 'apisTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: false, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as ApiSurfaceModulePatch; + const client = getClient(); + const result = await client.apiSurfaceModule + .update({ + where: { + id: answers.id as string, + }, + data: { + apiName: cleanedData.apiName, + apisTableId: cleanedData.apisTableId, + apisTableName: cleanedData.apisTableName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + apisTableId: true, + apisTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.apiSurfaceModule + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/modules/cli/commands/app-module.ts b/sdk/constructive-cli/src/modules/cli/commands/app-module.ts new file mode 100644 index 000000000..15311036e --- /dev/null +++ b/sdk/constructive-cli/src/modules/cli/commands/app-module.ts @@ -0,0 +1,644 @@ +/** + * CLI commands for AppModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateAppModuleInput, + AppModulePatch, + AppModuleSelect, + AppModuleFilter, + AppModuleOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + apiName: 'string', + appMembersTableId: 'uuid', + appMembersTableName: 'string', + appsTableId: 'uuid', + appsTableName: 'string', + catalogModuleId: 'uuid', + databaseId: 'uuid', + defaultPermissions: 'string', + entityField: 'string', + entityTableId: 'uuid', + id: 'uuid', + policies: 'json', + prefix: 'string', + privateApiName: 'string', + privateSchemaId: 'uuid', + privateSchemaName: 'string', + provisions: 'json', + publicSchemaName: 'string', + schemaId: 'uuid', + scope: 'string', +}; +const usage = + '\napp-module \n\nCommands:\n list List appModule records\n find-first Find first matching appModule record\n get Get a appModule by ID\n create Create a new appModule\n update Update an existing appModule\n delete Delete a appModule\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + appMembersTableId: true, + appMembersTableName: true, + appsTableId: true, + appsTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs & { + select: AppModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.appModule.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + appMembersTableId: true, + appMembersTableName: true, + appsTableId: true, + appsTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs & { + select: AppModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.appModule.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.appModule + .findOne({ + id: answers.id as string, + select: { + apiName: true, + appMembersTableId: true, + appMembersTableName: true, + appsTableId: true, + appsTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appMembersTableId', + message: 'appMembersTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appMembersTableName', + message: 'appMembersTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableId', + message: 'appsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableName', + message: 'appsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: true, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaId', + message: 'privateSchemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaName', + message: 'privateSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as CreateAppModuleInput['appModule']; + const client = getClient(); + const result = await client.appModule + .create({ + data: { + apiName: cleanedData.apiName, + appMembersTableId: cleanedData.appMembersTableId, + appMembersTableName: cleanedData.appMembersTableName, + appsTableId: cleanedData.appsTableId, + appsTableName: cleanedData.appsTableName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + privateSchemaId: cleanedData.privateSchemaId, + privateSchemaName: cleanedData.privateSchemaName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + appMembersTableId: true, + appMembersTableName: true, + appsTableId: true, + appsTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appMembersTableId', + message: 'appMembersTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appMembersTableName', + message: 'appMembersTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableId', + message: 'appsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableName', + message: 'appsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: false, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaId', + message: 'privateSchemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaName', + message: 'privateSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as AppModulePatch; + const client = getClient(); + const result = await client.appModule + .update({ + where: { + id: answers.id as string, + }, + data: { + apiName: cleanedData.apiName, + appMembersTableId: cleanedData.appMembersTableId, + appMembersTableName: cleanedData.appMembersTableName, + appsTableId: cleanedData.appsTableId, + appsTableName: cleanedData.appsTableName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + privateSchemaId: cleanedData.privateSchemaId, + privateSchemaName: cleanedData.privateSchemaName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + appMembersTableId: true, + appMembersTableName: true, + appsTableId: true, + appsTableName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.appModule + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/modules/cli/commands/catalog-module.ts b/sdk/constructive-cli/src/modules/cli/commands/catalog-module.ts new file mode 100644 index 000000000..1eabe33d2 --- /dev/null +++ b/sdk/constructive-cli/src/modules/cli/commands/catalog-module.ts @@ -0,0 +1,845 @@ +/** + * CLI commands for CatalogModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateCatalogModuleInput, + CatalogModulePatch, + CatalogModuleSelect, + CatalogModuleFilter, + CatalogModuleOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + apiName: 'string', + apisTableId: 'uuid', + apisTableName: 'string', + appsTableId: 'uuid', + appsTableName: 'string', + databaseId: 'uuid', + defaultPermissions: 'string', + domainsTableId: 'uuid', + domainsTableName: 'string', + entityTableId: 'uuid', + functionsTableId: 'uuid', + functionsTableName: 'string', + id: 'uuid', + namespacesTableId: 'uuid', + namespacesTableName: 'string', + policies: 'json', + privateApiName: 'string', + provisions: 'json', + publicSchemaName: 'string', + resourceDefinitionsTableId: 'uuid', + resourceDefinitionsTableName: 'string', + resourceInstallationsTableId: 'uuid', + resourceInstallationsTableName: 'string', + resourcesTableId: 'uuid', + resourcesTableName: 'string', + schemaId: 'uuid', + scope: 'string', + sitesTableId: 'uuid', + sitesTableName: 'string', +}; +const usage = + '\ncatalog-module \n\nCommands:\n list List catalogModule records\n find-first Find first matching catalogModule record\n get Get a catalogModule by ID\n create Create a new catalogModule\n update Update an existing catalogModule\n delete Delete a catalogModule\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + apisTableId: true, + apisTableName: true, + appsTableId: true, + appsTableName: true, + databaseId: true, + defaultPermissions: true, + domainsTableId: true, + domainsTableName: true, + entityTableId: true, + functionsTableId: true, + functionsTableName: true, + id: true, + namespacesTableId: true, + namespacesTableName: true, + policies: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + resourceDefinitionsTableId: true, + resourceDefinitionsTableName: true, + resourceInstallationsTableId: true, + resourceInstallationsTableName: true, + resourcesTableId: true, + resourcesTableName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs & { + select: CatalogModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.catalogModule.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + apisTableId: true, + apisTableName: true, + appsTableId: true, + appsTableName: true, + databaseId: true, + defaultPermissions: true, + domainsTableId: true, + domainsTableName: true, + entityTableId: true, + functionsTableId: true, + functionsTableName: true, + id: true, + namespacesTableId: true, + namespacesTableName: true, + policies: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + resourceDefinitionsTableId: true, + resourceDefinitionsTableName: true, + resourceInstallationsTableId: true, + resourceInstallationsTableName: true, + resourcesTableId: true, + resourcesTableName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs & { + select: CatalogModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.catalogModule.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.catalogModule + .findOne({ + id: answers.id as string, + select: { + apiName: true, + apisTableId: true, + apisTableName: true, + appsTableId: true, + appsTableName: true, + databaseId: true, + defaultPermissions: true, + domainsTableId: true, + domainsTableName: true, + entityTableId: true, + functionsTableId: true, + functionsTableName: true, + id: true, + namespacesTableId: true, + namespacesTableName: true, + policies: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + resourceDefinitionsTableId: true, + resourceDefinitionsTableName: true, + resourceInstallationsTableId: true, + resourceInstallationsTableName: true, + resourcesTableId: true, + resourcesTableName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableId', + message: 'apisTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableName', + message: 'apisTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableId', + message: 'appsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableName', + message: 'appsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: true, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableId', + message: 'domainsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableName', + message: 'domainsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'functionsTableId', + message: 'functionsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'functionsTableName', + message: 'functionsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'namespacesTableId', + message: 'namespacesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'namespacesTableName', + message: 'namespacesTableName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceDefinitionsTableId', + message: 'resourceDefinitionsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceDefinitionsTableName', + message: 'resourceDefinitionsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceInstallationsTableId', + message: 'resourceInstallationsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceInstallationsTableName', + message: 'resourceInstallationsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourcesTableId', + message: 'resourcesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourcesTableName', + message: 'resourcesTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableId', + message: 'sitesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableName', + message: 'sitesTableName', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateCatalogModuleInput['catalogModule']; + const client = getClient(); + const result = await client.catalogModule + .create({ + data: { + apiName: cleanedData.apiName, + apisTableId: cleanedData.apisTableId, + apisTableName: cleanedData.apisTableName, + appsTableId: cleanedData.appsTableId, + appsTableName: cleanedData.appsTableName, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + domainsTableId: cleanedData.domainsTableId, + domainsTableName: cleanedData.domainsTableName, + entityTableId: cleanedData.entityTableId, + functionsTableId: cleanedData.functionsTableId, + functionsTableName: cleanedData.functionsTableName, + namespacesTableId: cleanedData.namespacesTableId, + namespacesTableName: cleanedData.namespacesTableName, + policies: cleanedData.policies, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + resourceDefinitionsTableId: cleanedData.resourceDefinitionsTableId, + resourceDefinitionsTableName: cleanedData.resourceDefinitionsTableName, + resourceInstallationsTableId: cleanedData.resourceInstallationsTableId, + resourceInstallationsTableName: cleanedData.resourceInstallationsTableName, + resourcesTableId: cleanedData.resourcesTableId, + resourcesTableName: cleanedData.resourcesTableName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + sitesTableId: cleanedData.sitesTableId, + sitesTableName: cleanedData.sitesTableName, + }, + select: { + apiName: true, + apisTableId: true, + apisTableName: true, + appsTableId: true, + appsTableName: true, + databaseId: true, + defaultPermissions: true, + domainsTableId: true, + domainsTableName: true, + entityTableId: true, + functionsTableId: true, + functionsTableName: true, + id: true, + namespacesTableId: true, + namespacesTableName: true, + policies: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + resourceDefinitionsTableId: true, + resourceDefinitionsTableName: true, + resourceInstallationsTableId: true, + resourceInstallationsTableName: true, + resourcesTableId: true, + resourcesTableName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableId', + message: 'apisTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'apisTableName', + message: 'apisTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableId', + message: 'appsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'appsTableName', + message: 'appsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: false, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableId', + message: 'domainsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableName', + message: 'domainsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'functionsTableId', + message: 'functionsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'functionsTableName', + message: 'functionsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'namespacesTableId', + message: 'namespacesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'namespacesTableName', + message: 'namespacesTableName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceDefinitionsTableId', + message: 'resourceDefinitionsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceDefinitionsTableName', + message: 'resourceDefinitionsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceInstallationsTableId', + message: 'resourceInstallationsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourceInstallationsTableName', + message: 'resourceInstallationsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourcesTableId', + message: 'resourcesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resourcesTableName', + message: 'resourcesTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableId', + message: 'sitesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableName', + message: 'sitesTableName', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as CatalogModulePatch; + const client = getClient(); + const result = await client.catalogModule + .update({ + where: { + id: answers.id as string, + }, + data: { + apiName: cleanedData.apiName, + apisTableId: cleanedData.apisTableId, + apisTableName: cleanedData.apisTableName, + appsTableId: cleanedData.appsTableId, + appsTableName: cleanedData.appsTableName, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + domainsTableId: cleanedData.domainsTableId, + domainsTableName: cleanedData.domainsTableName, + entityTableId: cleanedData.entityTableId, + functionsTableId: cleanedData.functionsTableId, + functionsTableName: cleanedData.functionsTableName, + namespacesTableId: cleanedData.namespacesTableId, + namespacesTableName: cleanedData.namespacesTableName, + policies: cleanedData.policies, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + resourceDefinitionsTableId: cleanedData.resourceDefinitionsTableId, + resourceDefinitionsTableName: cleanedData.resourceDefinitionsTableName, + resourceInstallationsTableId: cleanedData.resourceInstallationsTableId, + resourceInstallationsTableName: cleanedData.resourceInstallationsTableName, + resourcesTableId: cleanedData.resourcesTableId, + resourcesTableName: cleanedData.resourcesTableName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + sitesTableId: cleanedData.sitesTableId, + sitesTableName: cleanedData.sitesTableName, + }, + select: { + apiName: true, + apisTableId: true, + apisTableName: true, + appsTableId: true, + appsTableName: true, + databaseId: true, + defaultPermissions: true, + domainsTableId: true, + domainsTableName: true, + entityTableId: true, + functionsTableId: true, + functionsTableName: true, + id: true, + namespacesTableId: true, + namespacesTableName: true, + policies: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + resourceDefinitionsTableId: true, + resourceDefinitionsTableName: true, + resourceInstallationsTableId: true, + resourceInstallationsTableName: true, + resourcesTableId: true, + resourcesTableName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.catalogModule + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/modules/cli/commands/database-provision-module.ts b/sdk/constructive-cli/src/modules/cli/commands/database-provision-module.ts index 6fed80341..81c07d4f5 100644 --- a/sdk/constructive-cli/src/modules/cli/commands/database-provision-module.ts +++ b/sdk/constructive-cli/src/modules/cli/commands/database-provision-module.ts @@ -16,6 +16,7 @@ import type { } from '../../orm/input-types'; import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { + async: 'boolean', bootstrapError: 'string', bootstrapStatus: 'string', bootstrapUser: 'boolean', @@ -86,6 +87,7 @@ async function handleTableSubcommand( async function handleList(argv: Partial>, _prompter: Inquirerer) { try { const defaultSelect = { + async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, @@ -128,6 +130,7 @@ async function handleList(argv: Partial>, _prompter: Inq async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { try { const defaultSelect = { + async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, @@ -182,6 +185,7 @@ async function handleGet(argv: Partial>, prompter: Inqui .findOne({ id: answers.id as string, select: { + async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, @@ -215,6 +219,13 @@ async function handleGet(argv: Partial>, prompter: Inqui async function handleCreate(argv: Partial>, prompter: Inquirerer) { try { const rawAnswers = await prompter.prompt(argv, [ + { + type: 'boolean', + name: 'async', + message: 'async', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'bootstrapError', @@ -327,6 +338,7 @@ async function handleCreate(argv: Partial>, prompter: In const result = await client.databaseProvisionModule .create({ data: { + async: cleanedData.async, bootstrapError: cleanedData.bootstrapError, bootstrapStatus: cleanedData.bootstrapStatus, bootstrapUser: cleanedData.bootstrapUser, @@ -344,6 +356,7 @@ async function handleCreate(argv: Partial>, prompter: In subdomain: cleanedData.subdomain, }, select: { + async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, @@ -383,6 +396,13 @@ async function handleUpdate(argv: Partial>, prompter: In message: 'id', required: true, }, + { + type: 'boolean', + name: 'async', + message: 'async', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'bootstrapError', @@ -495,6 +515,7 @@ async function handleUpdate(argv: Partial>, prompter: In id: answers.id as string, }, data: { + async: cleanedData.async, bootstrapError: cleanedData.bootstrapError, bootstrapStatus: cleanedData.bootstrapStatus, bootstrapUser: cleanedData.bootstrapUser, @@ -512,6 +533,7 @@ async function handleUpdate(argv: Partial>, prompter: In subdomain: cleanedData.subdomain, }, select: { + async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, diff --git a/sdk/constructive-cli/src/modules/cli/commands/domain-module.ts b/sdk/constructive-cli/src/modules/cli/commands/domain-module.ts new file mode 100644 index 000000000..becd25fbf --- /dev/null +++ b/sdk/constructive-cli/src/modules/cli/commands/domain-module.ts @@ -0,0 +1,647 @@ +/** + * CLI commands for DomainModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateDomainModuleInput, + DomainModulePatch, + DomainModuleSelect, + DomainModuleFilter, + DomainModuleOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + apiName: 'string', + catalogModuleId: 'uuid', + databaseId: 'uuid', + defaultPermissions: 'string', + domainEventsTableId: 'uuid', + domainEventsTableName: 'string', + domainVerificationsTableId: 'uuid', + domainVerificationsTableName: 'string', + domainsTableId: 'uuid', + domainsTableName: 'string', + entityField: 'string', + entityTableId: 'uuid', + id: 'uuid', + policies: 'json', + prefix: 'string', + privateApiName: 'string', + provisions: 'json', + publicSchemaName: 'string', + schemaId: 'uuid', + scope: 'string', +}; +const usage = + '\ndomain-module \n\nCommands:\n list List domainModule records\n find-first Find first matching domainModule record\n get Get a domainModule by ID\n create Create a new domainModule\n update Update an existing domainModule\n delete Delete a domainModule\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainEventsTableId: true, + domainEventsTableName: true, + domainVerificationsTableId: true, + domainVerificationsTableName: true, + domainsTableId: true, + domainsTableName: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs & { + select: DomainModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.domainModule.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainEventsTableId: true, + domainEventsTableName: true, + domainVerificationsTableId: true, + domainVerificationsTableName: true, + domainsTableId: true, + domainsTableName: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs & { + select: DomainModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.domainModule.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.domainModule + .findOne({ + id: answers.id as string, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainEventsTableId: true, + domainEventsTableName: true, + domainVerificationsTableId: true, + domainVerificationsTableName: true, + domainsTableId: true, + domainsTableName: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: true, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainEventsTableId', + message: 'domainEventsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainEventsTableName', + message: 'domainEventsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainVerificationsTableId', + message: 'domainVerificationsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainVerificationsTableName', + message: 'domainVerificationsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableId', + message: 'domainsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableName', + message: 'domainsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateDomainModuleInput['domainModule']; + const client = getClient(); + const result = await client.domainModule + .create({ + data: { + apiName: cleanedData.apiName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + domainEventsTableId: cleanedData.domainEventsTableId, + domainEventsTableName: cleanedData.domainEventsTableName, + domainVerificationsTableId: cleanedData.domainVerificationsTableId, + domainVerificationsTableName: cleanedData.domainVerificationsTableName, + domainsTableId: cleanedData.domainsTableId, + domainsTableName: cleanedData.domainsTableName, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainEventsTableId: true, + domainEventsTableName: true, + domainVerificationsTableId: true, + domainVerificationsTableName: true, + domainsTableId: true, + domainsTableName: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: false, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainEventsTableId', + message: 'domainEventsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainEventsTableName', + message: 'domainEventsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainVerificationsTableId', + message: 'domainVerificationsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainVerificationsTableName', + message: 'domainVerificationsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableId', + message: 'domainsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainsTableName', + message: 'domainsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as DomainModulePatch; + const client = getClient(); + const result = await client.domainModule + .update({ + where: { + id: answers.id as string, + }, + data: { + apiName: cleanedData.apiName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + domainEventsTableId: cleanedData.domainEventsTableId, + domainEventsTableName: cleanedData.domainEventsTableName, + domainVerificationsTableId: cleanedData.domainVerificationsTableId, + domainVerificationsTableName: cleanedData.domainVerificationsTableName, + domainsTableId: cleanedData.domainsTableId, + domainsTableName: cleanedData.domainsTableName, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainEventsTableId: true, + domainEventsTableName: true, + domainVerificationsTableId: true, + domainVerificationsTableName: true, + domainsTableId: true, + domainsTableName: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.domainModule + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/modules/cli/commands/function-invocation-module.ts b/sdk/constructive-cli/src/modules/cli/commands/function-invocation-module.ts index 37cf6bba6..8b2834fe5 100644 --- a/sdk/constructive-cli/src/modules/cli/commands/function-invocation-module.ts +++ b/sdk/constructive-cli/src/modules/cli/commands/function-invocation-module.ts @@ -17,6 +17,8 @@ import type { import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; const fieldSchema: FieldSchema = { apiName: 'string', + attemptsTableId: 'uuid', + attemptsTableName: 'string', databaseId: 'uuid', defaultPermissions: 'string', entityField: 'string', @@ -88,6 +90,8 @@ async function handleList(argv: Partial>, _prompter: Inq try { const defaultSelect = { apiName: true, + attemptsTableId: true, + attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, @@ -131,6 +135,8 @@ async function handleFindFirst(argv: Partial>, _prompter try { const defaultSelect = { apiName: true, + attemptsTableId: true, + attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, @@ -186,6 +192,8 @@ async function handleGet(argv: Partial>, prompter: Inqui id: answers.id as string, select: { apiName: true, + attemptsTableId: true, + attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, @@ -226,6 +234,20 @@ async function handleCreate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'text', + name: 'attemptsTableId', + message: 'attemptsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'attemptsTableName', + message: 'attemptsTableName', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'databaseId', @@ -355,6 +377,8 @@ async function handleCreate(argv: Partial>, prompter: In .create({ data: { apiName: cleanedData.apiName, + attemptsTableId: cleanedData.attemptsTableId, + attemptsTableName: cleanedData.attemptsTableName, databaseId: cleanedData.databaseId, defaultPermissions: cleanedData.defaultPermissions, entityField: cleanedData.entityField, @@ -375,6 +399,8 @@ async function handleCreate(argv: Partial>, prompter: In }, select: { apiName: true, + attemptsTableId: true, + attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, @@ -421,6 +447,20 @@ async function handleUpdate(argv: Partial>, prompter: In required: false, skipPrompt: true, }, + { + type: 'text', + name: 'attemptsTableId', + message: 'attemptsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'attemptsTableName', + message: 'attemptsTableName', + required: false, + skipPrompt: true, + }, { type: 'text', name: 'databaseId', @@ -550,6 +590,8 @@ async function handleUpdate(argv: Partial>, prompter: In }, data: { apiName: cleanedData.apiName, + attemptsTableId: cleanedData.attemptsTableId, + attemptsTableName: cleanedData.attemptsTableName, databaseId: cleanedData.databaseId, defaultPermissions: cleanedData.defaultPermissions, entityField: cleanedData.entityField, @@ -570,6 +612,8 @@ async function handleUpdate(argv: Partial>, prompter: In }, select: { apiName: true, + attemptsTableId: true, + attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, diff --git a/sdk/constructive-cli/src/modules/cli/commands/route-module.ts b/sdk/constructive-cli/src/modules/cli/commands/route-module.ts new file mode 100644 index 000000000..1acabf736 --- /dev/null +++ b/sdk/constructive-cli/src/modules/cli/commands/route-module.ts @@ -0,0 +1,735 @@ +/** + * CLI commands for RouteModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateRouteModuleInput, + RouteModulePatch, + RouteModuleSelect, + RouteModuleFilter, + RouteModuleOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + apiName: 'string', + catalogModuleId: 'uuid', + databaseId: 'uuid', + defaultPermissions: 'string', + domainModuleId: 'uuid', + entityField: 'string', + entityTableId: 'uuid', + hostnameBindingsTableId: 'uuid', + hostnameBindingsTableName: 'string', + id: 'uuid', + policies: 'json', + prefix: 'string', + privateApiName: 'string', + privateSchemaId: 'uuid', + privateSchemaName: 'string', + provisions: 'json', + publicSchemaName: 'string', + resolverFunctionName: 'string', + routeBindingsTableId: 'uuid', + routeBindingsTableName: 'string', + routesTableId: 'uuid', + routesTableName: 'string', + schemaId: 'uuid', + scope: 'string', +}; +const usage = + '\nroute-module \n\nCommands:\n list List routeModule records\n find-first Find first matching routeModule record\n get Get a routeModule by ID\n create Create a new routeModule\n update Update an existing routeModule\n delete Delete a routeModule\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainModuleId: true, + entityField: true, + entityTableId: true, + hostnameBindingsTableId: true, + hostnameBindingsTableName: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + resolverFunctionName: true, + routeBindingsTableId: true, + routeBindingsTableName: true, + routesTableId: true, + routesTableName: true, + schemaId: true, + scope: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs & { + select: RouteModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.routeModule.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainModuleId: true, + entityField: true, + entityTableId: true, + hostnameBindingsTableId: true, + hostnameBindingsTableName: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + resolverFunctionName: true, + routeBindingsTableId: true, + routeBindingsTableName: true, + routesTableId: true, + routesTableName: true, + schemaId: true, + scope: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs & { + select: RouteModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.routeModule.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.routeModule + .findOne({ + id: answers.id as string, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainModuleId: true, + entityField: true, + entityTableId: true, + hostnameBindingsTableId: true, + hostnameBindingsTableName: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + resolverFunctionName: true, + routeBindingsTableId: true, + routeBindingsTableName: true, + routesTableId: true, + routesTableName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: true, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainModuleId', + message: 'domainModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'hostnameBindingsTableId', + message: 'hostnameBindingsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'hostnameBindingsTableName', + message: 'hostnameBindingsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaId', + message: 'privateSchemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaName', + message: 'privateSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resolverFunctionName', + message: 'resolverFunctionName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routeBindingsTableId', + message: 'routeBindingsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routeBindingsTableName', + message: 'routeBindingsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routesTableId', + message: 'routesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routesTableName', + message: 'routesTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateRouteModuleInput['routeModule']; + const client = getClient(); + const result = await client.routeModule + .create({ + data: { + apiName: cleanedData.apiName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + domainModuleId: cleanedData.domainModuleId, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + hostnameBindingsTableId: cleanedData.hostnameBindingsTableId, + hostnameBindingsTableName: cleanedData.hostnameBindingsTableName, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + privateSchemaId: cleanedData.privateSchemaId, + privateSchemaName: cleanedData.privateSchemaName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + resolverFunctionName: cleanedData.resolverFunctionName, + routeBindingsTableId: cleanedData.routeBindingsTableId, + routeBindingsTableName: cleanedData.routeBindingsTableName, + routesTableId: cleanedData.routesTableId, + routesTableName: cleanedData.routesTableName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainModuleId: true, + entityField: true, + entityTableId: true, + hostnameBindingsTableId: true, + hostnameBindingsTableName: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + resolverFunctionName: true, + routeBindingsTableId: true, + routeBindingsTableName: true, + routesTableId: true, + routesTableName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: false, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'domainModuleId', + message: 'domainModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'hostnameBindingsTableId', + message: 'hostnameBindingsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'hostnameBindingsTableName', + message: 'hostnameBindingsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaId', + message: 'privateSchemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateSchemaName', + message: 'privateSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'resolverFunctionName', + message: 'resolverFunctionName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routeBindingsTableId', + message: 'routeBindingsTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routeBindingsTableName', + message: 'routeBindingsTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routesTableId', + message: 'routesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'routesTableName', + message: 'routesTableName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as RouteModulePatch; + const client = getClient(); + const result = await client.routeModule + .update({ + where: { + id: answers.id as string, + }, + data: { + apiName: cleanedData.apiName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + domainModuleId: cleanedData.domainModuleId, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + hostnameBindingsTableId: cleanedData.hostnameBindingsTableId, + hostnameBindingsTableName: cleanedData.hostnameBindingsTableName, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + privateSchemaId: cleanedData.privateSchemaId, + privateSchemaName: cleanedData.privateSchemaName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + resolverFunctionName: cleanedData.resolverFunctionName, + routeBindingsTableId: cleanedData.routeBindingsTableId, + routeBindingsTableName: cleanedData.routeBindingsTableName, + routesTableId: cleanedData.routesTableId, + routesTableName: cleanedData.routesTableName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + }, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + domainModuleId: true, + entityField: true, + entityTableId: true, + hostnameBindingsTableId: true, + hostnameBindingsTableName: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + privateSchemaId: true, + privateSchemaName: true, + provisions: true, + publicSchemaName: true, + resolverFunctionName: true, + routeBindingsTableId: true, + routeBindingsTableName: true, + routesTableId: true, + routesTableName: true, + schemaId: true, + scope: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.routeModule + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/modules/cli/commands/site-surface-module.ts b/sdk/constructive-cli/src/modules/cli/commands/site-surface-module.ts new file mode 100644 index 000000000..bbd5bdb5c --- /dev/null +++ b/sdk/constructive-cli/src/modules/cli/commands/site-surface-module.ts @@ -0,0 +1,559 @@ +/** + * CLI commands for SiteSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { CLIOptions, Inquirerer, extractFirst } from 'inquirerer'; +import { getClient } from '../executor'; +import { coerceAnswers, parseFindFirstArgs, parseFindManyArgs, stripUndefined } from '../utils'; +import type { FieldSchema } from '../utils'; +import type { + CreateSiteSurfaceModuleInput, + SiteSurfaceModulePatch, + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy, +} from '../../orm/input-types'; +import type { FindManyArgs, FindFirstArgs } from '../../orm/select-types'; +const fieldSchema: FieldSchema = { + apiName: 'string', + catalogModuleId: 'uuid', + databaseId: 'uuid', + defaultPermissions: 'string', + entityField: 'string', + entityTableId: 'uuid', + id: 'uuid', + policies: 'json', + prefix: 'string', + privateApiName: 'string', + provisions: 'json', + publicSchemaName: 'string', + schemaId: 'uuid', + scope: 'string', + sitesTableId: 'uuid', + sitesTableName: 'string', +}; +const usage = + '\nsite-surface-module \n\nCommands:\n list List siteSurfaceModule records\n find-first Find first matching siteSurfaceModule record\n get Get a siteSurfaceModule by ID\n create Create a new siteSurfaceModule\n update Update an existing siteSurfaceModule\n delete Delete a siteSurfaceModule\n\nList Options:\n --limit Max number of records to return (forward pagination)\n --last Number of records from the end (backward pagination)\n --after Cursor for forward pagination\n --before Cursor for backward pagination\n --offset Number of records to skip\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.name.equalTo foo)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\nFind-First Options:\n --select Comma-separated list of fields to return\n --where.. Filter (dot-notation, e.g. --where.status.equalTo active)\n --condition.. Condition filter (dot-notation)\n --orderBy Comma-separated ordering values (e.g. NAME_ASC,CREATED_AT_DESC)\n\n --help, -h Show this help message\n'; +export default async ( + argv: Partial>, + prompter: Inquirerer, + _options: CLIOptions +) => { + if (argv.help || argv.h) { + console.log(usage); + process.exit(0); + } + const { first: subcommand, newArgv } = extractFirst(argv); + if (!subcommand) { + const answer = await prompter.prompt(argv, [ + { + type: 'autocomplete', + name: 'subcommand', + message: 'What do you want to do?', + options: ['list', 'find-first', 'get', 'create', 'update', 'delete'], + }, + ]); + return handleTableSubcommand(answer.subcommand as string, newArgv, prompter); + } + return handleTableSubcommand(subcommand, newArgv, prompter); +}; +async function handleTableSubcommand( + subcommand: string, + argv: Partial>, + prompter: Inquirerer +) { + switch (subcommand) { + case 'list': + return handleList(argv, prompter); + case 'find-first': + return handleFindFirst(argv, prompter); + case 'get': + return handleGet(argv, prompter); + case 'create': + return handleCreate(argv, prompter); + case 'update': + return handleUpdate(argv, prompter); + case 'delete': + return handleDelete(argv, prompter); + default: + console.log(usage); + process.exit(1); + } +} +async function handleList(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }; + const findManyArgs = parseFindManyArgs< + FindManyArgs & { + select: SiteSurfaceModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.siteSurfaceModule.findMany(findManyArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to list records.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleFindFirst(argv: Partial>, _prompter: Inquirerer) { + try { + const defaultSelect = { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }; + const findFirstArgs = parseFindFirstArgs< + FindFirstArgs & { + select: SiteSurfaceModuleSelect; + } + >(argv, defaultSelect); + const client = getClient(); + const result = await client.siteSurfaceModule.findFirst(findFirstArgs).execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to find record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleGet(argv: Partial>, prompter: Inquirerer) { + try { + const answers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const client = getClient(); + const result = await client.siteSurfaceModule + .findOne({ + id: answers.id as string, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Record not found.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleCreate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: true, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableId', + message: 'sitesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableName', + message: 'sitesTableName', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined( + answers, + fieldSchema + ) as CreateSiteSurfaceModuleInput['siteSurfaceModule']; + const client = getClient(); + const result = await client.siteSurfaceModule + .create({ + data: { + apiName: cleanedData.apiName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + sitesTableId: cleanedData.sitesTableId, + sitesTableName: cleanedData.sitesTableName, + }, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to create record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleUpdate(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + { + type: 'text', + name: 'apiName', + message: 'apiName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'catalogModuleId', + message: 'catalogModuleId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'databaseId', + message: 'databaseId', + required: false, + }, + { + type: 'text', + name: 'defaultPermissions', + message: 'defaultPermissions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityField', + message: 'entityField', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'entityTableId', + message: 'entityTableId', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'policies', + message: 'policies', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'prefix', + message: 'prefix', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'privateApiName', + message: 'privateApiName', + required: false, + skipPrompt: true, + }, + { + type: 'json', + name: 'provisions', + message: 'provisions', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'publicSchemaName', + message: 'publicSchemaName', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'schemaId', + message: 'schemaId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'scope', + message: 'scope', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableId', + message: 'sitesTableId', + required: false, + skipPrompt: true, + }, + { + type: 'text', + name: 'sitesTableName', + message: 'sitesTableName', + required: false, + skipPrompt: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const cleanedData = stripUndefined(answers, fieldSchema) as SiteSurfaceModulePatch; + const client = getClient(); + const result = await client.siteSurfaceModule + .update({ + where: { + id: answers.id as string, + }, + data: { + apiName: cleanedData.apiName, + catalogModuleId: cleanedData.catalogModuleId, + databaseId: cleanedData.databaseId, + defaultPermissions: cleanedData.defaultPermissions, + entityField: cleanedData.entityField, + entityTableId: cleanedData.entityTableId, + policies: cleanedData.policies, + prefix: cleanedData.prefix, + privateApiName: cleanedData.privateApiName, + provisions: cleanedData.provisions, + publicSchemaName: cleanedData.publicSchemaName, + schemaId: cleanedData.schemaId, + scope: cleanedData.scope, + sitesTableId: cleanedData.sitesTableId, + sitesTableName: cleanedData.sitesTableName, + }, + select: { + apiName: true, + catalogModuleId: true, + databaseId: true, + defaultPermissions: true, + entityField: true, + entityTableId: true, + id: true, + policies: true, + prefix: true, + privateApiName: true, + provisions: true, + publicSchemaName: true, + schemaId: true, + scope: true, + sitesTableId: true, + sitesTableName: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to update record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} +async function handleDelete(argv: Partial>, prompter: Inquirerer) { + try { + const rawAnswers = await prompter.prompt(argv, [ + { + type: 'text', + name: 'id', + message: 'id', + required: true, + }, + ]); + const answers = coerceAnswers(rawAnswers, fieldSchema); + const client = getClient(); + const result = await client.siteSurfaceModule + .delete({ + where: { + id: answers.id as string, + }, + select: { + id: true, + }, + }) + .execute(); + console.log(JSON.stringify(result, null, 2)); + } catch (error) { + console.error('Failed to delete record.'); + if (error instanceof Error) { + console.error(error.message); + } + process.exit(1); + } +} diff --git a/sdk/constructive-cli/src/modules/orm/README.md b/sdk/constructive-cli/src/modules/orm/README.md index e420c3adb..41c41241d 100644 --- a/sdk/constructive-cli/src/modules/orm/README.md +++ b/sdk/constructive-cli/src/modules/orm/README.md @@ -22,11 +22,14 @@ const db = createClient({ | Model | Operations | |-------|------------| | `agentModule` | findMany, findOne, create, update, delete | +| `apiSurfaceModule` | findMany, findOne, create, update, delete | +| `appModule` | findMany, findOne, create, update, delete | | `billingModule` | findMany, findOne, create, update, delete | | `billingProviderModule` | findMany, findOne, create, update, delete | | `blueprint` | findMany, findOne, create, update, delete | | `blueprintConstruction` | findMany, findOne, create, update, delete | | `blueprintTemplate` | findMany, findOne, create, update, delete | +| `catalogModule` | findMany, findOne, create, update, delete | | `computeLogModule` | findMany, findOne, create, update, delete | | `configSecretsUserModule` | findMany, findOne, create, update, delete | | `connectedAccountsModule` | findMany, findOne, create, update, delete | @@ -40,6 +43,7 @@ const db = createClient({ | `defaultIdsModule` | findMany, findOne, create, update, delete | | `denormalizedTableField` | findMany, findOne, create, update, delete | | `devicesModule` | findMany, findOne, create, update, delete | +| `domainModule` | findMany, findOne, create, update, delete | | `emailsModule` | findMany, findOne, create, update, delete | | `entityTypeProvision` | findMany, findOne, create, update, delete | | `eventsModule` | findMany, findOne, create, update, delete | @@ -75,9 +79,11 @@ const db = createClient({ | `relationProvision` | findMany, findOne, create, update, delete | | `resourceModule` | findMany, findOne, create, update, delete | | `rlsModule` | findMany, findOne, create, update, delete | +| `routeModule` | findMany, findOne, create, update, delete | | `secureTableProvision` | findMany, findOne, create, update, delete | | `sessionSecretsModule` | findMany, findOne, create, update, delete | | `sessionsModule` | findMany, findOne, create, update, delete | +| `siteSurfaceModule` | findMany, findOne, create, update, delete | | `storageLogModule` | findMany, findOne, create, update, delete | | `storageModule` | findMany, findOne, create, update, delete | | `transferLogModule` | findMany, findOne, create, update, delete | @@ -156,6 +162,98 @@ const updated = await db.agentModule.update({ where: { id: '' }, data: { a const deleted = await db.agentModule.delete({ where: { id: '' } }).execute(); ``` +### `db.apiSurfaceModule` + +CRUD operations for ApiSurfaceModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `apisTableId` | UUID | Yes | +| `apisTableName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all apiSurfaceModule records +const items = await db.apiSurfaceModule.findMany({ select: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.apiSurfaceModule.findOne({ id: '', select: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.apiSurfaceModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.apiSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.apiSurfaceModule.delete({ where: { id: '' } }).execute(); +``` + +### `db.appModule` + +CRUD operations for AppModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `appMembersTableId` | UUID | Yes | +| `appMembersTableName` | String | Yes | +| `appsTableId` | UUID | Yes | +| `appsTableName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `privateSchemaId` | UUID | Yes | +| `privateSchemaName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all appModule records +const items = await db.appModule.findMany({ select: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.appModule.findOne({ id: '', select: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.appModule.create({ data: { apiName: '', appMembersTableId: '', appMembersTableName: '', appsTableId: '', appsTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.appModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.appModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.billingModule` CRUD operations for BillingModule records. @@ -388,6 +486,63 @@ const updated = await db.blueprintTemplate.update({ where: { id: '' }, dat const deleted = await db.blueprintTemplate.delete({ where: { id: '' } }).execute(); ``` +### `db.catalogModule` + +CRUD operations for CatalogModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `apisTableId` | UUID | Yes | +| `apisTableName` | String | Yes | +| `appsTableId` | UUID | Yes | +| `appsTableName` | String | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainsTableId` | UUID | Yes | +| `domainsTableName` | String | Yes | +| `entityTableId` | UUID | Yes | +| `functionsTableId` | UUID | Yes | +| `functionsTableName` | String | Yes | +| `id` | UUID | No | +| `namespacesTableId` | UUID | Yes | +| `namespacesTableName` | String | Yes | +| `policies` | JSON | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `resourceDefinitionsTableId` | UUID | Yes | +| `resourceDefinitionsTableName` | String | Yes | +| `resourceInstallationsTableId` | UUID | Yes | +| `resourceInstallationsTableName` | String | Yes | +| `resourcesTableId` | UUID | Yes | +| `resourcesTableName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | +| `sitesTableId` | UUID | Yes | +| `sitesTableName` | String | Yes | + +**Operations:** + +```typescript +// List all catalogModule records +const items = await db.catalogModule.findMany({ select: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Get one by id +const item = await db.catalogModule.findOne({ id: '', select: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Create +const created = await db.catalogModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', appsTableId: '', appsTableName: '', databaseId: '', defaultPermissions: '', domainsTableId: '', domainsTableName: '', entityTableId: '', functionsTableId: '', functionsTableName: '', namespacesTableId: '', namespacesTableName: '', policies: '', privateApiName: '', provisions: '', publicSchemaName: '', resourceDefinitionsTableId: '', resourceDefinitionsTableName: '', resourceInstallationsTableId: '', resourceInstallationsTableName: '', resourcesTableId: '', resourcesTableName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.catalogModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.catalogModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.computeLogModule` CRUD operations for ComputeLogModule records. @@ -597,6 +752,7 @@ CRUD operations for DatabaseProvisionModule records. | Field | Type | Editable | |-------|------|----------| +| `async` | Boolean | Yes | | `bootstrapError` | String | Yes | | `bootstrapStatus` | String | Yes | | `bootstrapUser` | Boolean | Yes | @@ -620,16 +776,16 @@ CRUD operations for DatabaseProvisionModule records. ```typescript // List all databaseProvisionModule records -const items = await db.databaseProvisionModule.findMany({ select: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); +const items = await db.databaseProvisionModule.findMany({ select: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); // Get one by id -const item = await db.databaseProvisionModule.findOne({ id: '', select: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); +const item = await db.databaseProvisionModule.findOne({ id: '', select: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); // Create -const created = await db.databaseProvisionModule.create({ data: { bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute(); +const created = await db.databaseProvisionModule.create({ data: { async: '', bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute(); // Update -const updated = await db.databaseProvisionModule.update({ where: { id: '' }, data: { bootstrapError: '' }, select: { id: true } }).execute(); +const updated = await db.databaseProvisionModule.update({ where: { id: '' }, data: { async: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseProvisionModule.delete({ where: { id: '' } }).execute(); @@ -919,6 +1075,54 @@ const updated = await db.devicesModule.update({ where: { id: '' }, data: { const deleted = await db.devicesModule.delete({ where: { id: '' } }).execute(); ``` +### `db.domainModule` + +CRUD operations for DomainModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainEventsTableId` | UUID | Yes | +| `domainEventsTableName` | String | Yes | +| `domainVerificationsTableId` | UUID | Yes | +| `domainVerificationsTableName` | String | Yes | +| `domainsTableId` | UUID | Yes | +| `domainsTableName` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all domainModule records +const items = await db.domainModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.domainModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.domainModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainEventsTableId: '', domainEventsTableName: '', domainVerificationsTableId: '', domainVerificationsTableName: '', domainsTableId: '', domainsTableName: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.emailsModule` CRUD operations for EmailsModule records. @@ -1153,6 +1357,8 @@ CRUD operations for FunctionInvocationModule records. | Field | Type | Editable | |-------|------|----------| | `apiName` | String | Yes | +| `attemptsTableId` | UUID | Yes | +| `attemptsTableName` | String | Yes | | `databaseId` | UUID | Yes | | `defaultPermissions` | String | Yes | | `entityField` | String | Yes | @@ -1176,13 +1382,13 @@ CRUD operations for FunctionInvocationModule records. ```typescript // List all functionInvocationModule records -const items = await db.functionInvocationModule.findMany({ select: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); +const items = await db.functionInvocationModule.findMany({ select: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); // Get one by id -const item = await db.functionInvocationModule.findOne({ id: '', select: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); +const item = await db.functionInvocationModule.findOne({ id: '', select: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); // Create -const created = await db.functionInvocationModule.create({ data: { apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); +const created = await db.functionInvocationModule.create({ data: { apiName: '', attemptsTableId: '', attemptsTableName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionInvocationModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); @@ -2612,6 +2818,58 @@ const updated = await db.rlsModule.update({ where: { id: '' }, data: { api const deleted = await db.rlsModule.delete({ where: { id: '' } }).execute(); ``` +### `db.routeModule` + +CRUD operations for RouteModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainModuleId` | UUID | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `hostnameBindingsTableId` | UUID | Yes | +| `hostnameBindingsTableName` | String | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `privateSchemaId` | UUID | Yes | +| `privateSchemaName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `resolverFunctionName` | String | Yes | +| `routeBindingsTableId` | UUID | Yes | +| `routeBindingsTableName` | String | Yes | +| `routesTableId` | UUID | Yes | +| `routesTableName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all routeModule records +const items = await db.routeModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.routeModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.routeModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainModuleId: '', entityField: '', entityTableId: '', hostnameBindingsTableId: '', hostnameBindingsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', resolverFunctionName: '', routeBindingsTableId: '', routeBindingsTableName: '', routesTableId: '', routesTableName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.routeModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.routeModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.secureTableProvision` CRUD operations for SecureTableProvision records. @@ -2724,6 +2982,50 @@ const updated = await db.sessionsModule.update({ where: { id: '' }, data: const deleted = await db.sessionsModule.delete({ where: { id: '' } }).execute(); ``` +### `db.siteSurfaceModule` + +CRUD operations for SiteSurfaceModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | +| `sitesTableId` | UUID | Yes | +| `sitesTableName` | String | Yes | + +**Operations:** + +```typescript +// List all siteSurfaceModule records +const items = await db.siteSurfaceModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Get one by id +const item = await db.siteSurfaceModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Create +const created = await db.siteSurfaceModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.siteSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.siteSurfaceModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.storageLogModule` CRUD operations for StorageLogModule records. diff --git a/sdk/constructive-cli/src/modules/orm/index.ts b/sdk/constructive-cli/src/modules/orm/index.ts index dc11b99fb..64ef96660 100644 --- a/sdk/constructive-cli/src/modules/orm/index.ts +++ b/sdk/constructive-cli/src/modules/orm/index.ts @@ -6,11 +6,14 @@ import { OrmClient } from './client'; import type { OrmClientConfig } from './client'; import { AgentModuleModel } from './models/agentModule'; +import { ApiSurfaceModuleModel } from './models/apiSurfaceModule'; +import { AppModuleModel } from './models/appModule'; import { BillingModuleModel } from './models/billingModule'; import { BillingProviderModuleModel } from './models/billingProviderModule'; import { BlueprintModel } from './models/blueprint'; import { BlueprintConstructionModel } from './models/blueprintConstruction'; import { BlueprintTemplateModel } from './models/blueprintTemplate'; +import { CatalogModuleModel } from './models/catalogModule'; import { ComputeLogModuleModel } from './models/computeLogModule'; import { ConfigSecretsUserModuleModel } from './models/configSecretsUserModule'; import { ConnectedAccountsModuleModel } from './models/connectedAccountsModule'; @@ -24,6 +27,7 @@ import { DbUsageModuleModel } from './models/dbUsageModule'; import { DefaultIdsModuleModel } from './models/defaultIdsModule'; import { DenormalizedTableFieldModel } from './models/denormalizedTableField'; import { DevicesModuleModel } from './models/devicesModule'; +import { DomainModuleModel } from './models/domainModule'; import { EmailsModuleModel } from './models/emailsModule'; import { EntityTypeProvisionModel } from './models/entityTypeProvision'; import { EventsModuleModel } from './models/eventsModule'; @@ -59,9 +63,11 @@ import { RealtimeModuleModel } from './models/realtimeModule'; import { RelationProvisionModel } from './models/relationProvision'; import { ResourceModuleModel } from './models/resourceModule'; import { RlsModuleModel } from './models/rlsModule'; +import { RouteModuleModel } from './models/routeModule'; import { SecureTableProvisionModel } from './models/secureTableProvision'; import { SessionSecretsModuleModel } from './models/sessionSecretsModule'; import { SessionsModuleModel } from './models/sessionsModule'; +import { SiteSurfaceModuleModel } from './models/siteSurfaceModule'; import { StorageLogModuleModel } from './models/storageLogModule'; import { StorageModuleModel } from './models/storageModule'; import { TransferLogModuleModel } from './models/transferLogModule'; @@ -109,11 +115,14 @@ export function createClient(config: OrmClientConfig) { const client = new OrmClient(config); return { agentModule: new AgentModuleModel(client), + apiSurfaceModule: new ApiSurfaceModuleModel(client), + appModule: new AppModuleModel(client), billingModule: new BillingModuleModel(client), billingProviderModule: new BillingProviderModuleModel(client), blueprint: new BlueprintModel(client), blueprintConstruction: new BlueprintConstructionModel(client), blueprintTemplate: new BlueprintTemplateModel(client), + catalogModule: new CatalogModuleModel(client), computeLogModule: new ComputeLogModuleModel(client), configSecretsUserModule: new ConfigSecretsUserModuleModel(client), connectedAccountsModule: new ConnectedAccountsModuleModel(client), @@ -127,6 +136,7 @@ export function createClient(config: OrmClientConfig) { defaultIdsModule: new DefaultIdsModuleModel(client), denormalizedTableField: new DenormalizedTableFieldModel(client), devicesModule: new DevicesModuleModel(client), + domainModule: new DomainModuleModel(client), emailsModule: new EmailsModuleModel(client), entityTypeProvision: new EntityTypeProvisionModel(client), eventsModule: new EventsModuleModel(client), @@ -162,9 +172,11 @@ export function createClient(config: OrmClientConfig) { relationProvision: new RelationProvisionModel(client), resourceModule: new ResourceModuleModel(client), rlsModule: new RlsModuleModel(client), + routeModule: new RouteModuleModel(client), secureTableProvision: new SecureTableProvisionModel(client), sessionSecretsModule: new SessionSecretsModuleModel(client), sessionsModule: new SessionsModuleModel(client), + siteSurfaceModule: new SiteSurfaceModuleModel(client), storageLogModule: new StorageLogModuleModel(client), storageModule: new StorageModuleModel(client), transferLogModule: new TransferLogModuleModel(client), diff --git a/sdk/constructive-cli/src/modules/orm/input-types.ts b/sdk/constructive-cli/src/modules/orm/input-types.ts index a163f67d4..c151221f6 100644 --- a/sdk/constructive-cli/src/modules/orm/input-types.ts +++ b/sdk/constructive-cli/src/modules/orm/input-types.ts @@ -269,6 +269,46 @@ export interface AgentModule { threadTableId?: string | null; threadTableName?: string | null; } +export interface ApiSurfaceModule { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface AppModule { + apiName?: string | null; + appMembersTableId?: string | null; + appMembersTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} export interface BillingModule { apiName?: string | null; balancesTableId?: string | null; @@ -417,6 +457,37 @@ export interface BlueprintTemplate { /** Access control for the template. private: only the owner can see and copy. public: anyone can browse and copy from the marketplace. Defaults to private. */ visibility?: string | null; } +export interface CatalogModule { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityTableId?: string | null; + functionsTableId?: string | null; + functionsTableName?: string | null; + id: string; + namespacesTableId?: string | null; + namespacesTableName?: string | null; + policies?: Record | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resourceDefinitionsTableId?: string | null; + resourceDefinitionsTableName?: string | null; + resourceInstallationsTableId?: string | null; + resourceInstallationsTableName?: string | null; + resourcesTableId?: string | null; + resourcesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} export interface ComputeLogModule { actorFkTableId?: string | null; apiName?: string | null; @@ -490,6 +561,8 @@ export interface CryptoAuthModule { } /** Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. */ export interface DatabaseProvisionModule { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean | null; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string | null; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -639,6 +712,28 @@ export interface DevicesModule { userDevicesTableId?: string | null; userDevicesTableName?: string | null; } +export interface DomainModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainEventsTableId?: string | null; + domainEventsTableName?: string | null; + domainVerificationsTableId?: string | null; + domainVerificationsTableName?: string | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} export interface EmailsModule { apiName?: string | null; databaseId?: string | null; @@ -982,6 +1077,8 @@ export interface FunctionDeploymentModule { } export interface FunctionInvocationModule { apiName?: string | null; + attemptsTableId?: string | null; + attemptsTableName?: string | null; databaseId?: string | null; defaultPermissions?: string[] | null; entityField?: string | null; @@ -1772,6 +1869,32 @@ export interface RlsModule { sessionsTableId?: string | null; usersTableId?: string | null; } +export interface RouteModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainModuleId?: string | null; + entityField?: string | null; + entityTableId?: string | null; + hostnameBindingsTableId?: string | null; + hostnameBindingsTableName?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resolverFunctionName?: string | null; + routeBindingsTableId?: string | null; + routeBindingsTableName?: string | null; + routesTableId?: string | null; + routesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; +} /** Provisions security, fields, grants, and policies onto a table. Each row can independently: (1) create fields via nodes[] array (supporting multiple Data* modules per row), (2) grant privileges via grants[] array (supporting per-role privilege targeting), (3) create RLS policies via policies[] array (supporting multiple Authz* policies per row). Multiple rows can target the same table to compose different concerns. All three concerns are optional and independent. */ export interface SecureTableProvision { /** The database this provision belongs to. Required. */ @@ -1820,6 +1943,24 @@ export interface SessionsModule { sessionsTableName?: string | null; usersTableId?: string | null; } +export interface SiteSurfaceModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} export interface StorageLogModule { actorFkTableId?: string | null; apiName?: string | null; @@ -2048,6 +2189,12 @@ export interface PageInfo { } // ============ Entity Relation Types ============ export interface AgentModuleRelations {} +export interface ApiSurfaceModuleRelations { + catalogModule?: CatalogModule | null; +} +export interface AppModuleRelations { + catalogModule?: CatalogModule | null; +} export interface BillingModuleRelations {} export interface BillingProviderModuleRelations {} export interface BlueprintRelations { @@ -2062,6 +2209,7 @@ export interface BlueprintTemplateRelations { blueprintTemplatesByForkedFromId?: ConnectionResult; blueprintsByTemplateId?: ConnectionResult; } +export interface CatalogModuleRelations {} export interface ComputeLogModuleRelations {} export interface ConfigSecretsUserModuleRelations {} export interface ConnectedAccountsModuleRelations {} @@ -2077,6 +2225,9 @@ export interface DbUsageModuleRelations {} export interface DefaultIdsModuleRelations {} export interface DenormalizedTableFieldRelations {} export interface DevicesModuleRelations {} +export interface DomainModuleRelations { + catalogModule?: CatalogModule | null; +} export interface EmailsModuleRelations {} export interface EntityTypeProvisionRelations {} export interface EventsModuleRelations {} @@ -2129,9 +2280,16 @@ export interface ResourceModuleRelations { namespaceModule?: NamespaceModule | null; } export interface RlsModuleRelations {} +export interface RouteModuleRelations { + catalogModule?: CatalogModule | null; + domainModule?: DomainModule | null; +} export interface SecureTableProvisionRelations {} export interface SessionSecretsModuleRelations {} export interface SessionsModuleRelations {} +export interface SiteSurfaceModuleRelations { + catalogModule?: CatalogModule | null; +} export interface StorageLogModuleRelations {} export interface StorageModuleRelations {} export interface TransferLogModuleRelations {} @@ -2150,6 +2308,8 @@ export interface WebhookModuleRelations { } // ============ Entity Types With Relations ============ export type AgentModuleWithRelations = AgentModule & AgentModuleRelations; +export type ApiSurfaceModuleWithRelations = ApiSurfaceModule & ApiSurfaceModuleRelations; +export type AppModuleWithRelations = AppModule & AppModuleRelations; export type BillingModuleWithRelations = BillingModule & BillingModuleRelations; export type BillingProviderModuleWithRelations = BillingProviderModule & BillingProviderModuleRelations; @@ -2157,6 +2317,7 @@ export type BlueprintWithRelations = Blueprint & BlueprintRelations; export type BlueprintConstructionWithRelations = BlueprintConstruction & BlueprintConstructionRelations; export type BlueprintTemplateWithRelations = BlueprintTemplate & BlueprintTemplateRelations; +export type CatalogModuleWithRelations = CatalogModule & CatalogModuleRelations; export type ComputeLogModuleWithRelations = ComputeLogModule & ComputeLogModuleRelations; export type ConfigSecretsUserModuleWithRelations = ConfigSecretsUserModule & ConfigSecretsUserModuleRelations; @@ -2175,6 +2336,7 @@ export type DefaultIdsModuleWithRelations = DefaultIdsModule & DefaultIdsModuleR export type DenormalizedTableFieldWithRelations = DenormalizedTableField & DenormalizedTableFieldRelations; export type DevicesModuleWithRelations = DevicesModule & DevicesModuleRelations; +export type DomainModuleWithRelations = DomainModule & DomainModuleRelations; export type EmailsModuleWithRelations = EmailsModule & EmailsModuleRelations; export type EntityTypeProvisionWithRelations = EntityTypeProvision & EntityTypeProvisionRelations; export type EventsModuleWithRelations = EventsModule & EventsModuleRelations; @@ -2218,11 +2380,13 @@ export type RealtimeModuleWithRelations = RealtimeModule & RealtimeModuleRelatio export type RelationProvisionWithRelations = RelationProvision & RelationProvisionRelations; export type ResourceModuleWithRelations = ResourceModule & ResourceModuleRelations; export type RlsModuleWithRelations = RlsModule & RlsModuleRelations; +export type RouteModuleWithRelations = RouteModule & RouteModuleRelations; export type SecureTableProvisionWithRelations = SecureTableProvision & SecureTableProvisionRelations; export type SessionSecretsModuleWithRelations = SessionSecretsModule & SessionSecretsModuleRelations; export type SessionsModuleWithRelations = SessionsModule & SessionsModuleRelations; +export type SiteSurfaceModuleWithRelations = SiteSurfaceModule & SiteSurfaceModuleRelations; export type StorageLogModuleWithRelations = StorageLogModule & StorageLogModuleRelations; export type StorageModuleWithRelations = StorageModule & StorageModuleRelations; export type TransferLogModuleWithRelations = TransferLogModule & TransferLogModuleRelations; @@ -2275,6 +2439,52 @@ export type AgentModuleSelect = { threadTableId?: boolean; threadTableName?: boolean; }; +export type ApiSurfaceModuleSelect = { + apiName?: boolean; + apisTableId?: boolean; + apisTableName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; +export type AppModuleSelect = { + apiName?: boolean; + appMembersTableId?: boolean; + appMembersTableName?: boolean; + appsTableId?: boolean; + appsTableName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + privateSchemaId?: boolean; + privateSchemaName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type BillingModuleSelect = { apiName?: boolean; balancesTableId?: boolean; @@ -2404,6 +2614,37 @@ export type BlueprintTemplateSelect = { orderBy?: BlueprintOrderBy[]; }; }; +export type CatalogModuleSelect = { + apiName?: boolean; + apisTableId?: boolean; + apisTableName?: boolean; + appsTableId?: boolean; + appsTableName?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainsTableId?: boolean; + domainsTableName?: boolean; + entityTableId?: boolean; + functionsTableId?: boolean; + functionsTableName?: boolean; + id?: boolean; + namespacesTableId?: boolean; + namespacesTableName?: boolean; + policies?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + resourceDefinitionsTableId?: boolean; + resourceDefinitionsTableName?: boolean; + resourceInstallationsTableId?: boolean; + resourceInstallationsTableName?: boolean; + resourcesTableId?: boolean; + resourcesTableName?: boolean; + schemaId?: boolean; + scope?: boolean; + sitesTableId?: boolean; + sitesTableName?: boolean; +}; export type ComputeLogModuleSelect = { actorFkTableId?: boolean; apiName?: boolean; @@ -2476,6 +2717,7 @@ export type CryptoAuthModuleSelect = { usersTableId?: boolean; }; export type DatabaseProvisionModuleSelect = { + async?: boolean; bootstrapError?: boolean; bootstrapStatus?: boolean; bootstrapUser?: boolean; @@ -2600,6 +2842,31 @@ export type DevicesModuleSelect = { userDevicesTableId?: boolean; userDevicesTableName?: boolean; }; +export type DomainModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainEventsTableId?: boolean; + domainEventsTableName?: boolean; + domainVerificationsTableId?: boolean; + domainVerificationsTableName?: boolean; + domainsTableId?: boolean; + domainsTableName?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type EmailsModuleSelect = { apiName?: boolean; databaseId?: boolean; @@ -2729,6 +2996,8 @@ export type FunctionDeploymentModuleSelect = { }; export type FunctionInvocationModuleSelect = { apiName?: boolean; + attemptsTableId?: boolean; + attemptsTableName?: boolean; databaseId?: boolean; defaultPermissions?: boolean; entityField?: boolean; @@ -3422,6 +3691,38 @@ export type RlsModuleSelect = { sessionsTableId?: boolean; usersTableId?: boolean; }; +export type RouteModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainModuleId?: boolean; + entityField?: boolean; + entityTableId?: boolean; + hostnameBindingsTableId?: boolean; + hostnameBindingsTableName?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + privateSchemaId?: boolean; + privateSchemaName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + resolverFunctionName?: boolean; + routeBindingsTableId?: boolean; + routeBindingsTableName?: boolean; + routesTableId?: boolean; + routesTableName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; + domainModule?: { + select: DomainModuleSelect; + }; +}; export type SecureTableProvisionSelect = { databaseId?: boolean; fields?: boolean; @@ -3456,6 +3757,27 @@ export type SessionsModuleSelect = { sessionsTableName?: boolean; usersTableId?: boolean; }; +export type SiteSurfaceModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + sitesTableId?: boolean; + sitesTableName?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type StorageLogModuleSelect = { actorFkTableId?: boolean; apiName?: boolean; @@ -3756,74 +4078,170 @@ export interface AgentModuleFilter { /** Filter by the object’s `threadTableName` field. */ threadTableName?: StringFilter; } -export interface BillingModuleFilter { +export interface ApiSurfaceModuleFilter { /** Checks for all expressions in this list. */ - and?: BillingModuleFilter[]; + and?: ApiSurfaceModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; - /** Filter by the object’s `balancesTableId` field. */ - balancesTableId?: UUIDFilter; - /** Filter by the object’s `balancesTableName` field. */ - balancesTableName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `defaultPermissions` field. */ defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; /** Filter by the object’s `id` field. */ id?: UUIDFilter; - /** Filter by the object’s `ledgerTableId` field. */ - ledgerTableId?: UUIDFilter; - /** Filter by the object’s `ledgerTableName` field. */ - ledgerTableName?: StringFilter; - /** Filter by the object’s `meterCreditsTableId` field. */ - meterCreditsTableId?: UUIDFilter; - /** Filter by the object’s `meterCreditsTableName` field. */ - meterCreditsTableName?: StringFilter; - /** Filter by the object’s `meterDefaultsTableId` field. */ - meterDefaultsTableId?: UUIDFilter; - /** Filter by the object’s `meterDefaultsTableName` field. */ - meterDefaultsTableName?: StringFilter; - /** Filter by the object’s `meterSourcesTableId` field. */ - meterSourcesTableId?: UUIDFilter; - /** Filter by the object’s `meterSourcesTableName` field. */ - meterSourcesTableName?: StringFilter; - /** Filter by the object’s `metersTableId` field. */ - metersTableId?: UUIDFilter; - /** Filter by the object’s `metersTableName` field. */ - metersTableName?: StringFilter; /** Negates the expression. */ - not?: BillingModuleFilter; + not?: ApiSurfaceModuleFilter; /** Checks for any expressions in this list. */ - or?: BillingModuleFilter[]; - /** Filter by the object’s `planSubscriptionsTableId` field. */ - planSubscriptionsTableId?: UUIDFilter; - /** Filter by the object’s `planSubscriptionsTableName` field. */ - planSubscriptionsTableName?: StringFilter; + or?: ApiSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; /** Filter by the object’s `prefix` field. */ prefix?: StringFilter; /** Filter by the object’s `privateApiName` field. */ privateApiName?: StringFilter; - /** Filter by the object’s `privateSchemaId` field. */ - privateSchemaId?: UUIDFilter; - /** Filter by the object’s `privateSchemaName` field. */ - privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; /** Filter by the object’s `publicSchemaName` field. */ publicSchemaName?: StringFilter; - /** Filter by the object’s `recordUsageFunction` field. */ - recordUsageFunction?: StringFilter; - /** Filter by the object’s `rollupUsageSummaryFunction` field. */ - rollupUsageSummaryFunction?: StringFilter; /** Filter by the object’s `schemaId` field. */ schemaId?: UUIDFilter; - /** Filter by the object’s `sweepExpiredSubscriptionsFunction` field. */ - sweepExpiredSubscriptionsFunction?: StringFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; } -export interface BillingProviderModuleFilter { +export interface AppModuleFilter { /** Checks for all expressions in this list. */ - and?: BillingProviderModuleFilter[]; + and?: AppModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; - /** Filter by the object’s `billingCustomersTableId` field. */ + /** Filter by the object’s `appMembersTableId` field. */ + appMembersTableId?: UUIDFilter; + /** Filter by the object’s `appMembersTableName` field. */ + appMembersTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: AppModuleFilter; + /** Checks for any expressions in this list. */ + or?: AppModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} +export interface BillingModuleFilter { + /** Checks for all expressions in this list. */ + and?: BillingModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `balancesTableId` field. */ + balancesTableId?: UUIDFilter; + /** Filter by the object’s `balancesTableName` field. */ + balancesTableName?: StringFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `ledgerTableId` field. */ + ledgerTableId?: UUIDFilter; + /** Filter by the object’s `ledgerTableName` field. */ + ledgerTableName?: StringFilter; + /** Filter by the object’s `meterCreditsTableId` field. */ + meterCreditsTableId?: UUIDFilter; + /** Filter by the object’s `meterCreditsTableName` field. */ + meterCreditsTableName?: StringFilter; + /** Filter by the object’s `meterDefaultsTableId` field. */ + meterDefaultsTableId?: UUIDFilter; + /** Filter by the object’s `meterDefaultsTableName` field. */ + meterDefaultsTableName?: StringFilter; + /** Filter by the object’s `meterSourcesTableId` field. */ + meterSourcesTableId?: UUIDFilter; + /** Filter by the object’s `meterSourcesTableName` field. */ + meterSourcesTableName?: StringFilter; + /** Filter by the object’s `metersTableId` field. */ + metersTableId?: UUIDFilter; + /** Filter by the object’s `metersTableName` field. */ + metersTableName?: StringFilter; + /** Negates the expression. */ + not?: BillingModuleFilter; + /** Checks for any expressions in this list. */ + or?: BillingModuleFilter[]; + /** Filter by the object’s `planSubscriptionsTableId` field. */ + planSubscriptionsTableId?: UUIDFilter; + /** Filter by the object’s `planSubscriptionsTableName` field. */ + planSubscriptionsTableName?: StringFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `recordUsageFunction` field. */ + recordUsageFunction?: StringFilter; + /** Filter by the object’s `rollupUsageSummaryFunction` field. */ + rollupUsageSummaryFunction?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `sweepExpiredSubscriptionsFunction` field. */ + sweepExpiredSubscriptionsFunction?: StringFilter; +} +export interface BillingProviderModuleFilter { + /** Checks for all expressions in this list. */ + and?: BillingProviderModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `billingCustomersTableId` field. */ billingCustomersTableId?: UUIDFilter; /** Filter by the object’s `billingCustomersTableName` field. */ billingCustomersTableName?: StringFilter; @@ -4002,6 +4420,72 @@ export interface BlueprintTemplateFilter { /** Filter by the object’s `visibility` field. */ visibility?: StringFilter; } +export interface CatalogModuleFilter { + /** Checks for all expressions in this list. */ + and?: CatalogModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableId` field. */ + functionsTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableName` field. */ + functionsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `namespacesTableId` field. */ + namespacesTableId?: UUIDFilter; + /** Filter by the object’s `namespacesTableName` field. */ + namespacesTableName?: StringFilter; + /** Negates the expression. */ + not?: CatalogModuleFilter; + /** Checks for any expressions in this list. */ + or?: CatalogModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resourceDefinitionsTableId` field. */ + resourceDefinitionsTableId?: UUIDFilter; + /** Filter by the object’s `resourceDefinitionsTableName` field. */ + resourceDefinitionsTableName?: StringFilter; + /** Filter by the object’s `resourceInstallationsTableId` field. */ + resourceInstallationsTableId?: UUIDFilter; + /** Filter by the object’s `resourceInstallationsTableName` field. */ + resourceInstallationsTableName?: StringFilter; + /** Filter by the object’s `resourcesTableId` field. */ + resourcesTableId?: UUIDFilter; + /** Filter by the object’s `resourcesTableName` field. */ + resourcesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} export interface ComputeLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ actorFkTableId?: UUIDFilter; @@ -4167,6 +4651,8 @@ export interface CryptoAuthModuleFilter { export interface DatabaseProvisionModuleFilter { /** Checks for all expressions in this list. */ and?: DatabaseProvisionModuleFilter[]; + /** Filter by the object’s `async` field. */ + async?: BooleanFilter; /** Filter by the object’s `bootstrapError` field. */ bootstrapError?: StringFilter; /** Filter by the object’s `bootstrapStatus` field. */ @@ -4442,6 +4928,58 @@ export interface DevicesModuleFilter { /** Filter by the object’s `userDevicesTableName` field. */ userDevicesTableName?: StringFilter; } +export interface DomainModuleFilter { + /** Checks for all expressions in this list. */ + and?: DomainModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainEventsTableId` field. */ + domainEventsTableId?: UUIDFilter; + /** Filter by the object’s `domainEventsTableName` field. */ + domainEventsTableName?: StringFilter; + /** Filter by the object’s `domainVerificationsTableId` field. */ + domainVerificationsTableId?: UUIDFilter; + /** Filter by the object’s `domainVerificationsTableName` field. */ + domainVerificationsTableName?: StringFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: DomainModuleFilter; + /** Checks for any expressions in this list. */ + or?: DomainModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} export interface EmailsModuleFilter { /** Checks for all expressions in this list. */ and?: EmailsModuleFilter[]; @@ -4713,6 +5251,10 @@ export interface FunctionInvocationModuleFilter { and?: FunctionInvocationModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; + /** Filter by the object’s `attemptsTableId` field. */ + attemptsTableId?: UUIDFilter; + /** Filter by the object’s `attemptsTableName` field. */ + attemptsTableName?: StringFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `defaultPermissions` field. */ @@ -6188,6 +6730,70 @@ export interface RlsModuleFilter { /** Filter by the object’s `usersTableId` field. */ usersTableId?: UUIDFilter; } +export interface RouteModuleFilter { + /** Checks for all expressions in this list. */ + and?: RouteModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainModule` relation. */ + domainModule?: DomainModuleFilter; + /** A related `domainModule` exists. */ + domainModuleExists?: boolean; + /** Filter by the object’s `domainModuleId` field. */ + domainModuleId?: UUIDFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableId` field. */ + hostnameBindingsTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableName` field. */ + hostnameBindingsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: RouteModuleFilter; + /** Checks for any expressions in this list. */ + or?: RouteModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resolverFunctionName` field. */ + resolverFunctionName?: StringFilter; + /** Filter by the object’s `routeBindingsTableId` field. */ + routeBindingsTableId?: UUIDFilter; + /** Filter by the object’s `routeBindingsTableName` field. */ + routeBindingsTableName?: StringFilter; + /** Filter by the object’s `routesTableId` field. */ + routesTableId?: UUIDFilter; + /** Filter by the object’s `routesTableName` field. */ + routesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} export interface SecureTableProvisionFilter { /** Checks for all expressions in this list. */ and?: SecureTableProvisionFilter[]; @@ -6268,6 +6874,50 @@ export interface SessionsModuleFilter { /** Filter by the object’s `usersTableId` field. */ usersTableId?: UUIDFilter; } +export interface SiteSurfaceModuleFilter { + /** Checks for all expressions in this list. */ + and?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: SiteSurfaceModuleFilter; + /** Checks for any expressions in this list. */ + or?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} export interface StorageLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ actorFkTableId?: UUIDFilter; @@ -6819,6 +7469,86 @@ export type AgentModuleOrderBy = | 'THREAD_TABLE_ID_DESC' | 'THREAD_TABLE_NAME_ASC' | 'THREAD_TABLE_NAME_DESC'; +export type ApiSurfaceModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; +export type AppModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'APP_MEMBERS_TABLE_ID_ASC' + | 'APP_MEMBERS_TABLE_ID_DESC' + | 'APP_MEMBERS_TABLE_NAME_ASC' + | 'APP_MEMBERS_TABLE_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type BillingModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' @@ -7023,6 +7753,68 @@ export type BlueprintTemplateOrderBy = | 'VERSION_DESC' | 'VISIBILITY_ASC' | 'VISIBILITY_DESC'; +export type CatalogModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_ID_ASC' + | 'FUNCTIONS_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_NAME_ASC' + | 'FUNCTIONS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NAMESPACES_TABLE_ID_ASC' + | 'NAMESPACES_TABLE_ID_DESC' + | 'NAMESPACES_TABLE_NAME_ASC' + | 'NAMESPACES_TABLE_NAME_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOURCES_TABLE_ID_ASC' + | 'RESOURCES_TABLE_ID_DESC' + | 'RESOURCES_TABLE_NAME_ASC' + | 'RESOURCES_TABLE_NAME_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; export type ComputeLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' | 'ACTOR_FK_TABLE_ID_DESC' @@ -7166,6 +7958,8 @@ export type CryptoAuthModuleOrderBy = | 'USER_FIELD_ASC' | 'USER_FIELD_DESC'; export type DatabaseProvisionModuleOrderBy = + | 'ASYNC_ASC' + | 'ASYNC_DESC' | 'BOOTSTRAP_ERROR_ASC' | 'BOOTSTRAP_ERROR_DESC' | 'BOOTSTRAP_STATUS_ASC' @@ -7409,6 +8203,50 @@ export type DevicesModuleOrderBy = | 'USER_DEVICES_TABLE_ID_DESC' | 'USER_DEVICES_TABLE_NAME_ASC' | 'USER_DEVICES_TABLE_NAME_DESC'; +export type DomainModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'DOMAIN_EVENTS_TABLE_ID_ASC' + | 'DOMAIN_EVENTS_TABLE_ID_DESC' + | 'DOMAIN_EVENTS_TABLE_NAME_ASC' + | 'DOMAIN_EVENTS_TABLE_NAME_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type EmailsModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' @@ -7654,6 +8492,10 @@ export type FunctionDeploymentModuleOrderBy = export type FunctionInvocationModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' + | 'ATTEMPTS_TABLE_ID_ASC' + | 'ATTEMPTS_TABLE_ID_DESC' + | 'ATTEMPTS_TABLE_NAME_ASC' + | 'ATTEMPTS_TABLE_NAME_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DEFAULT_PERMISSIONS_ASC' @@ -8975,6 +9817,58 @@ export type RlsModuleOrderBy = | 'SESSION_CREDENTIALS_TABLE_ID_DESC' | 'USERS_TABLE_ID_ASC' | 'USERS_TABLE_ID_DESC'; +export type RouteModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAIN_MODULE_ID_ASC' + | 'DOMAIN_MODULE_ID_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_ID_ASC' + | 'HOSTNAME_BINDINGS_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_ASC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOLVER_FUNCTION_NAME_ASC' + | 'RESOLVER_FUNCTION_NAME_DESC' + | 'ROUTES_TABLE_ID_ASC' + | 'ROUTES_TABLE_ID_DESC' + | 'ROUTES_TABLE_NAME_ASC' + | 'ROUTES_TABLE_NAME_DESC' + | 'ROUTE_BINDINGS_TABLE_ID_ASC' + | 'ROUTE_BINDINGS_TABLE_ID_DESC' + | 'ROUTE_BINDINGS_TABLE_NAME_ASC' + | 'ROUTE_BINDINGS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type SecureTableProvisionOrderBy = | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' @@ -9031,18 +9925,54 @@ export type SessionsModuleOrderBy = | 'PRIMARY_KEY_DESC' | 'SCHEMA_ID_ASC' | 'SCHEMA_ID_DESC' - | 'SESSIONS_DEFAULT_EXPIRATION_ASC' - | 'SESSIONS_DEFAULT_EXPIRATION_DESC' - | 'SESSIONS_TABLE_ID_ASC' - | 'SESSIONS_TABLE_ID_DESC' - | 'SESSIONS_TABLE_NAME_ASC' - | 'SESSIONS_TABLE_NAME_DESC' - | 'SESSION_CREDENTIALS_TABLE_ID_ASC' - | 'SESSION_CREDENTIALS_TABLE_ID_DESC' - | 'SESSION_CREDENTIALS_TABLE_NAME_ASC' - | 'SESSION_CREDENTIALS_TABLE_NAME_DESC' - | 'USERS_TABLE_ID_ASC' - | 'USERS_TABLE_ID_DESC'; + | 'SESSIONS_DEFAULT_EXPIRATION_ASC' + | 'SESSIONS_DEFAULT_EXPIRATION_DESC' + | 'SESSIONS_TABLE_ID_ASC' + | 'SESSIONS_TABLE_ID_DESC' + | 'SESSIONS_TABLE_NAME_ASC' + | 'SESSIONS_TABLE_NAME_DESC' + | 'SESSION_CREDENTIALS_TABLE_ID_ASC' + | 'SESSION_CREDENTIALS_TABLE_ID_DESC' + | 'SESSION_CREDENTIALS_TABLE_NAME_ASC' + | 'SESSION_CREDENTIALS_TABLE_NAME_DESC' + | 'USERS_TABLE_ID_ASC' + | 'USERS_TABLE_ID_DESC'; +export type SiteSurfaceModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; export type StorageLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' | 'ACTOR_FK_TABLE_ID_DESC' @@ -9544,6 +10474,106 @@ export interface DeleteAgentModuleInput { clientMutationId?: string; id: string; } +export interface CreateApiSurfaceModuleInput { + clientMutationId?: string; + apiSurfaceModule: { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface ApiSurfaceModulePatch { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateApiSurfaceModuleInput { + clientMutationId?: string; + id: string; + apiSurfaceModulePatch: ApiSurfaceModulePatch; +} +export interface DeleteApiSurfaceModuleInput { + clientMutationId?: string; + id: string; +} +export interface CreateAppModuleInput { + clientMutationId?: string; + appModule: { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface AppModulePatch { + apiName?: string | null; + appMembersTableId?: string | null; + appMembersTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateAppModuleInput { + clientMutationId?: string; + id: string; + appModulePatch: AppModulePatch; +} +export interface DeleteAppModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateBillingModuleInput { clientMutationId?: string; billingModule: { @@ -9786,6 +10816,78 @@ export interface DeleteBlueprintTemplateInput { clientMutationId?: string; id: string; } +export interface CreateCatalogModuleInput { + clientMutationId?: string; + catalogModule: { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: Record; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; + }; +} +export interface CatalogModulePatch { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityTableId?: string | null; + functionsTableId?: string | null; + functionsTableName?: string | null; + namespacesTableId?: string | null; + namespacesTableName?: string | null; + policies?: Record | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resourceDefinitionsTableId?: string | null; + resourceDefinitionsTableName?: string | null; + resourceInstallationsTableId?: string | null; + resourceInstallationsTableName?: string | null; + resourcesTableId?: string | null; + resourcesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} +export interface UpdateCatalogModuleInput { + clientMutationId?: string; + id: string; + catalogModulePatch: CatalogModulePatch; +} +export interface DeleteCatalogModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateComputeLogModuleInput { clientMutationId?: string; computeLogModule: { @@ -9981,6 +11083,7 @@ export interface DeleteCryptoAuthModuleInput { export interface CreateDatabaseProvisionModuleInput { clientMutationId?: string; databaseProvisionModule: { + async?: boolean; bootstrapError?: string; bootstrapStatus?: string; bootstrapUser?: boolean; @@ -9999,6 +11102,7 @@ export interface CreateDatabaseProvisionModuleInput { }; } export interface DatabaseProvisionModulePatch { + async?: boolean | null; bootstrapError?: string | null; bootstrapStatus?: string | null; bootstrapUser?: boolean | null; @@ -10288,6 +11392,60 @@ export interface DeleteDevicesModuleInput { clientMutationId?: string; id: string; } +export interface CreateDomainModuleInput { + clientMutationId?: string; + domainModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface DomainModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainEventsTableId?: string | null; + domainEventsTableName?: string | null; + domainVerificationsTableId?: string | null; + domainVerificationsTableName?: string | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateDomainModuleInput { + clientMutationId?: string; + id: string; + domainModulePatch: DomainModulePatch; +} +export interface DeleteDomainModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateEmailsModuleInput { clientMutationId?: string; emailsModule: { @@ -10574,6 +11732,8 @@ export interface CreateFunctionInvocationModuleInput { clientMutationId?: string; functionInvocationModule: { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId: string; defaultPermissions?: string[]; entityField?: string; @@ -10595,6 +11755,8 @@ export interface CreateFunctionInvocationModuleInput { } export interface FunctionInvocationModulePatch { apiName?: string | null; + attemptsTableId?: string | null; + attemptsTableName?: string | null; databaseId?: string | null; defaultPermissions?: string[] | null; entityField?: string | null; @@ -12196,6 +13358,68 @@ export interface DeleteRlsModuleInput { clientMutationId?: string; id: string; } +export interface CreateRouteModuleInput { + clientMutationId?: string; + routeModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface RouteModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainModuleId?: string | null; + entityField?: string | null; + entityTableId?: string | null; + hostnameBindingsTableId?: string | null; + hostnameBindingsTableName?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resolverFunctionName?: string | null; + routeBindingsTableId?: string | null; + routeBindingsTableName?: string | null; + routesTableId?: string | null; + routesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateRouteModuleInput { + clientMutationId?: string; + id: string; + routeModulePatch: RouteModulePatch; +} +export interface DeleteRouteModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateSecureTableProvisionInput { clientMutationId?: string; secureTableProvision: { @@ -12278,19 +13502,65 @@ export interface SessionsModulePatch { authSettingsTableName?: string | null; databaseId?: string | null; schemaId?: string | null; - sessionCredentialsTableId?: string | null; - sessionCredentialsTableName?: string | null; - sessionsDefaultExpiration?: IntervalInput | null; - sessionsTableId?: string | null; - sessionsTableName?: string | null; - usersTableId?: string | null; + sessionCredentialsTableId?: string | null; + sessionCredentialsTableName?: string | null; + sessionsDefaultExpiration?: IntervalInput | null; + sessionsTableId?: string | null; + sessionsTableName?: string | null; + usersTableId?: string | null; +} +export interface UpdateSessionsModuleInput { + clientMutationId?: string; + id: string; + sessionsModulePatch: SessionsModulePatch; +} +export interface DeleteSessionsModuleInput { + clientMutationId?: string; + id: string; +} +export interface CreateSiteSurfaceModuleInput { + clientMutationId?: string; + siteSurfaceModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; + }; +} +export interface SiteSurfaceModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; } -export interface UpdateSessionsModuleInput { +export interface UpdateSiteSurfaceModuleInput { clientMutationId?: string; id: string; - sessionsModulePatch: SessionsModulePatch; + siteSurfaceModulePatch: SiteSurfaceModulePatch; } -export interface DeleteSessionsModuleInput { +export interface DeleteSiteSurfaceModuleInput { clientMutationId?: string; id: string; } @@ -12897,14 +14167,14 @@ export interface ProvisionRelationInput { } export interface ProvisionSpatialRelationInput { clientMutationId?: string; - pDatabaseId?: string; - pName?: string; - pOperator?: string; - pParamName?: string; - pSourceFieldId?: string; - pSourceTableId?: string; - pTargetFieldId?: string; - pTargetTableId?: string; + databaseId?: string; + name?: string; + operator?: string; + paramName?: string; + sourceFieldId?: string; + sourceTableId?: string; + targetFieldId?: string; + targetTableId?: string; } export interface ProvisionTableInput { clientMutationId?: string; @@ -13076,6 +14346,48 @@ export interface AgentModuleInput { threadTableId?: string; threadTableName?: string; } +/** An input for mutations affecting `ApiSurfaceModule` */ +export interface ApiSurfaceModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} +/** An input for mutations affecting `AppModule` */ +export interface AppModuleInput { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `BillingModule` */ export interface BillingModuleInput { apiName?: string; @@ -13226,6 +14538,38 @@ export interface BlueprintTemplateInput { /** Access control for the template. private: only the owner can see and copy. public: anyone can browse and copy from the marketplace. Defaults to private. */ visibility?: string; } +/** An input for mutations affecting `CatalogModule` */ +export interface CatalogModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + id?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: Record; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** An input for mutations affecting `ComputeLogModule` */ export interface ComputeLogModuleInput { actorFkTableId?: string; @@ -13304,6 +14648,8 @@ export interface CryptoAuthModuleInput { } /** An input for mutations affecting `DatabaseProvisionModule` */ export interface DatabaseProvisionModuleInput { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -13477,6 +14823,29 @@ export interface DevicesModuleInput { userDevicesTableId?: string; userDevicesTableName?: string; } +/** An input for mutations affecting `DomainModule` */ +export interface DomainModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `EmailsModule` */ export interface EmailsModuleInput { apiName?: string; @@ -13815,6 +15184,8 @@ export interface FunctionDeploymentModuleInput { /** An input for mutations affecting `FunctionInvocationModule` */ export interface FunctionInvocationModuleInput { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId: string; defaultPermissions?: string[]; entityField?: string; @@ -14603,6 +15974,33 @@ export interface RlsModuleInput { sessionsTableId?: string; usersTableId?: string; } +/** An input for mutations affecting `RouteModule` */ +export interface RouteModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `SecureTableProvision` */ export interface SecureTableProvisionInput { /** The database this provision belongs to. Required. */ @@ -14652,6 +16050,25 @@ export interface SessionsModuleInput { sessionsTableName?: string; usersTableId?: string; } +/** An input for mutations affecting `SiteSurfaceModule` */ +export interface SiteSurfaceModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** An input for mutations affecting `StorageLogModule` */ export interface StorageLogModuleInput { actorFkTableId?: string; @@ -15517,6 +16934,96 @@ export type DeleteAgentModulePayloadSelect = { }; clientMutationId?: boolean; }; +export interface CreateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was created by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was updated by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was deleted by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface CreateAppModulePayload { + /** The `AppModule` that was created by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateAppModulePayload { + /** The `AppModule` that was updated by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteAppModulePayload { + /** The `AppModule` that was deleted by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; export interface CreateBillingModulePayload { /** The `BillingModule` that was created by this mutation. */ billingModule?: BillingModule | null; @@ -15742,6 +17249,51 @@ export type DeleteBlueprintTemplatePayloadSelect = { }; clientMutationId?: boolean; }; +export interface CreateCatalogModulePayload { + /** The `CatalogModule` that was created by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateCatalogModulePayload { + /** The `CatalogModule` that was updated by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteCatalogModulePayload { + /** The `CatalogModule` that was deleted by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; export interface CreateComputeLogModulePayload { clientMutationId?: string | null; /** The `ComputeLogModule` that was created by this mutation. */ @@ -16327,6 +17879,51 @@ export type DeleteDevicesModulePayloadSelect = { select: DevicesModuleEdgeSelect; }; }; +export interface CreateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was created by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type CreateDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; +export interface UpdateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was updated by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type UpdateDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; +export interface DeleteDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was deleted by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type DeleteDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; export interface CreateEmailsModulePayload { clientMutationId?: string | null; /** The `EmailsModule` that was created by this mutation. */ @@ -17902,6 +19499,51 @@ export type DeleteRlsModulePayloadSelect = { select: RlsModuleEdgeSelect; }; }; +export interface CreateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was created by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type CreateRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; +export interface UpdateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was updated by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type UpdateRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; +export interface DeleteRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was deleted by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type DeleteRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; export interface CreateSecureTableProvisionPayload { clientMutationId?: string | null; /** The `SecureTableProvision` that was created by this mutation. */ @@ -18037,6 +19679,51 @@ export type DeleteSessionsModulePayloadSelect = { select: SessionsModuleEdgeSelect; }; }; +export interface CreateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was created by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type CreateSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; +export interface UpdateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was updated by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type UpdateSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; +export interface DeleteSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was deleted by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type DeleteSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; export interface CreateStorageLogModulePayload { clientMutationId?: string | null; /** The `StorageLogModule` that was created by this mutation. */ @@ -18564,6 +20251,30 @@ export type AgentModuleEdgeSelect = { select: AgentModuleSelect; }; }; +/** A `ApiSurfaceModule` edge in the connection. */ +export interface ApiSurfaceModuleEdge { + cursor?: string | null; + /** The `ApiSurfaceModule` at the end of the edge. */ + node?: ApiSurfaceModule | null; +} +export type ApiSurfaceModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: ApiSurfaceModuleSelect; + }; +}; +/** A `AppModule` edge in the connection. */ +export interface AppModuleEdge { + cursor?: string | null; + /** The `AppModule` at the end of the edge. */ + node?: AppModule | null; +} +export type AppModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: AppModuleSelect; + }; +}; /** A `BillingModule` edge in the connection. */ export interface BillingModuleEdge { cursor?: string | null; @@ -18624,6 +20335,18 @@ export type BlueprintTemplateEdgeSelect = { select: BlueprintTemplateSelect; }; }; +/** A `CatalogModule` edge in the connection. */ +export interface CatalogModuleEdge { + cursor?: string | null; + /** The `CatalogModule` at the end of the edge. */ + node?: CatalogModule | null; +} +export type CatalogModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: CatalogModuleSelect; + }; +}; /** A `ComputeLogModule` edge in the connection. */ export interface ComputeLogModuleEdge { cursor?: string | null; @@ -18780,6 +20503,18 @@ export type DevicesModuleEdgeSelect = { select: DevicesModuleSelect; }; }; +/** A `DomainModule` edge in the connection. */ +export interface DomainModuleEdge { + cursor?: string | null; + /** The `DomainModule` at the end of the edge. */ + node?: DomainModule | null; +} +export type DomainModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainModuleSelect; + }; +}; /** A `EmailsModule` edge in the connection. */ export interface EmailsModuleEdge { cursor?: string | null; @@ -19200,6 +20935,18 @@ export type RlsModuleEdgeSelect = { select: RlsModuleSelect; }; }; +/** A `RouteModule` edge in the connection. */ +export interface RouteModuleEdge { + cursor?: string | null; + /** The `RouteModule` at the end of the edge. */ + node?: RouteModule | null; +} +export type RouteModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: RouteModuleSelect; + }; +}; /** A `SecureTableProvision` edge in the connection. */ export interface SecureTableProvisionEdge { cursor?: string | null; @@ -19236,6 +20983,18 @@ export type SessionsModuleEdgeSelect = { select: SessionsModuleSelect; }; }; +/** A `SiteSurfaceModule` edge in the connection. */ +export interface SiteSurfaceModuleEdge { + cursor?: string | null; + /** The `SiteSurfaceModule` at the end of the edge. */ + node?: SiteSurfaceModule | null; +} +export type SiteSurfaceModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: SiteSurfaceModuleSelect; + }; +}; /** A `StorageLogModule` edge in the connection. */ export interface StorageLogModuleEdge { cursor?: string | null; diff --git a/sdk/constructive-cli/src/modules/orm/models/apiSurfaceModule.ts b/sdk/constructive-cli/src/modules/orm/models/apiSurfaceModule.ts new file mode 100644 index 000000000..12cb1d83e --- /dev/null +++ b/sdk/constructive-cli/src/modules/orm/models/apiSurfaceModule.ts @@ -0,0 +1,245 @@ +/** + * ApiSurfaceModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ApiSurfaceModule, + ApiSurfaceModuleWithRelations, + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy, + CreateApiSurfaceModuleInput, + UpdateApiSurfaceModuleInput, + ApiSurfaceModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ApiSurfaceModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModule', + document, + variables, + transform: (data: { + apiSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + apiSurfaceModule: data.apiSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModule', + document, + variables, + transform: (data: { + apiSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + apiSurfaceModule: data.apiSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ApiSurfaceModule', + 'createApiSurfaceModule', + 'apiSurfaceModule', + args.select, + args.data, + 'CreateApiSurfaceModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'createApiSurfaceModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + ApiSurfaceModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'ApiSurfaceModule', + 'updateApiSurfaceModule', + 'apiSurfaceModule', + args.select, + args.where.id, + args.data, + 'UpdateApiSurfaceModuleInput', + 'id', + 'apiSurfaceModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'updateApiSurfaceModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'ApiSurfaceModule', + 'deleteApiSurfaceModule', + 'apiSurfaceModule', + { + id: args.where.id, + }, + 'DeleteApiSurfaceModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'deleteApiSurfaceModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/modules/orm/models/appModule.ts b/sdk/constructive-cli/src/modules/orm/models/appModule.ts new file mode 100644 index 000000000..78c5786d0 --- /dev/null +++ b/sdk/constructive-cli/src/modules/orm/models/appModule.ts @@ -0,0 +1,245 @@ +/** + * AppModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + AppModule, + AppModuleWithRelations, + AppModuleSelect, + AppModuleFilter, + AppModuleOrderBy, + CreateAppModuleInput, + UpdateAppModuleInput, + AppModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class AppModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'AppModule', + 'appModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'AppModule', + 'appModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModule', + document, + variables, + transform: (data: { + appModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + appModule: data.appModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'AppModule', + 'appModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModule', + document, + variables, + transform: (data: { + appModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + appModule: data.appModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'AppModule', + 'createAppModule', + 'appModule', + args.select, + args.data, + 'CreateAppModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'createAppModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + AppModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'AppModule', + 'updateAppModule', + 'appModule', + args.select, + args.where.id, + args.data, + 'UpdateAppModuleInput', + 'id', + 'appModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'updateAppModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'AppModule', + 'deleteAppModule', + 'appModule', + { + id: args.where.id, + }, + 'DeleteAppModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'deleteAppModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/modules/orm/models/catalogModule.ts b/sdk/constructive-cli/src/modules/orm/models/catalogModule.ts new file mode 100644 index 000000000..f03b06347 --- /dev/null +++ b/sdk/constructive-cli/src/modules/orm/models/catalogModule.ts @@ -0,0 +1,245 @@ +/** + * CatalogModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + CatalogModule, + CatalogModuleWithRelations, + CatalogModuleSelect, + CatalogModuleFilter, + CatalogModuleOrderBy, + CreateCatalogModuleInput, + UpdateCatalogModuleInput, + CatalogModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class CatalogModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModule', + document, + variables, + transform: (data: { + catalogModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + catalogModule: data.catalogModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModule', + document, + variables, + transform: (data: { + catalogModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + catalogModule: data.catalogModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'CatalogModule', + 'createCatalogModule', + 'catalogModule', + args.select, + args.data, + 'CreateCatalogModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'createCatalogModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + CatalogModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'CatalogModule', + 'updateCatalogModule', + 'catalogModule', + args.select, + args.where.id, + args.data, + 'UpdateCatalogModuleInput', + 'id', + 'catalogModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'updateCatalogModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'CatalogModule', + 'deleteCatalogModule', + 'catalogModule', + { + id: args.where.id, + }, + 'DeleteCatalogModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'deleteCatalogModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/modules/orm/models/domainModule.ts b/sdk/constructive-cli/src/modules/orm/models/domainModule.ts new file mode 100644 index 000000000..fd1f53622 --- /dev/null +++ b/sdk/constructive-cli/src/modules/orm/models/domainModule.ts @@ -0,0 +1,245 @@ +/** + * DomainModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainModule, + DomainModuleWithRelations, + DomainModuleSelect, + DomainModuleFilter, + DomainModuleOrderBy, + CreateDomainModuleInput, + UpdateDomainModuleInput, + DomainModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModule', + document, + variables, + transform: (data: { + domainModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainModule: data.domainModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModule', + document, + variables, + transform: (data: { + domainModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainModule: data.domainModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainModule', + 'createDomainModule', + 'domainModule', + args.select, + args.data, + 'CreateDomainModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'createDomainModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainModule', + 'updateDomainModule', + 'domainModule', + args.select, + args.where.id, + args.data, + 'UpdateDomainModuleInput', + 'id', + 'domainModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'updateDomainModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainModule', + 'deleteDomainModule', + 'domainModule', + { + id: args.where.id, + }, + 'DeleteDomainModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'deleteDomainModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/modules/orm/models/index.ts b/sdk/constructive-cli/src/modules/orm/models/index.ts index 4cabf5cd9..2143a553f 100644 --- a/sdk/constructive-cli/src/modules/orm/models/index.ts +++ b/sdk/constructive-cli/src/modules/orm/models/index.ts @@ -4,11 +4,14 @@ * DO NOT EDIT - changes will be overwritten */ export { AgentModuleModel } from './agentModule'; +export { ApiSurfaceModuleModel } from './apiSurfaceModule'; +export { AppModuleModel } from './appModule'; export { BillingModuleModel } from './billingModule'; export { BillingProviderModuleModel } from './billingProviderModule'; export { BlueprintModel } from './blueprint'; export { BlueprintConstructionModel } from './blueprintConstruction'; export { BlueprintTemplateModel } from './blueprintTemplate'; +export { CatalogModuleModel } from './catalogModule'; export { ComputeLogModuleModel } from './computeLogModule'; export { ConfigSecretsUserModuleModel } from './configSecretsUserModule'; export { ConnectedAccountsModuleModel } from './connectedAccountsModule'; @@ -22,6 +25,7 @@ export { DbUsageModuleModel } from './dbUsageModule'; export { DefaultIdsModuleModel } from './defaultIdsModule'; export { DenormalizedTableFieldModel } from './denormalizedTableField'; export { DevicesModuleModel } from './devicesModule'; +export { DomainModuleModel } from './domainModule'; export { EmailsModuleModel } from './emailsModule'; export { EntityTypeProvisionModel } from './entityTypeProvision'; export { EventsModuleModel } from './eventsModule'; @@ -57,9 +61,11 @@ export { RealtimeModuleModel } from './realtimeModule'; export { RelationProvisionModel } from './relationProvision'; export { ResourceModuleModel } from './resourceModule'; export { RlsModuleModel } from './rlsModule'; +export { RouteModuleModel } from './routeModule'; export { SecureTableProvisionModel } from './secureTableProvision'; export { SessionSecretsModuleModel } from './sessionSecretsModule'; export { SessionsModuleModel } from './sessionsModule'; +export { SiteSurfaceModuleModel } from './siteSurfaceModule'; export { StorageLogModuleModel } from './storageLogModule'; export { StorageModuleModel } from './storageModule'; export { TransferLogModuleModel } from './transferLogModule'; diff --git a/sdk/constructive-cli/src/modules/orm/models/routeModule.ts b/sdk/constructive-cli/src/modules/orm/models/routeModule.ts new file mode 100644 index 000000000..d57b13cea --- /dev/null +++ b/sdk/constructive-cli/src/modules/orm/models/routeModule.ts @@ -0,0 +1,245 @@ +/** + * RouteModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + RouteModule, + RouteModuleWithRelations, + RouteModuleSelect, + RouteModuleFilter, + RouteModuleOrderBy, + CreateRouteModuleInput, + UpdateRouteModuleInput, + RouteModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class RouteModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModule', + document, + variables, + transform: (data: { + routeModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + routeModule: data.routeModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModule', + document, + variables, + transform: (data: { + routeModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + routeModule: data.routeModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'RouteModule', + 'createRouteModule', + 'routeModule', + args.select, + args.data, + 'CreateRouteModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'createRouteModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + RouteModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'RouteModule', + 'updateRouteModule', + 'routeModule', + args.select, + args.where.id, + args.data, + 'UpdateRouteModuleInput', + 'id', + 'routeModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'updateRouteModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'RouteModule', + 'deleteRouteModule', + 'routeModule', + { + id: args.where.id, + }, + 'DeleteRouteModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'deleteRouteModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-cli/src/modules/orm/models/siteSurfaceModule.ts b/sdk/constructive-cli/src/modules/orm/models/siteSurfaceModule.ts new file mode 100644 index 000000000..891f21403 --- /dev/null +++ b/sdk/constructive-cli/src/modules/orm/models/siteSurfaceModule.ts @@ -0,0 +1,245 @@ +/** + * SiteSurfaceModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + SiteSurfaceModule, + SiteSurfaceModuleWithRelations, + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy, + CreateSiteSurfaceModuleInput, + UpdateSiteSurfaceModuleInput, + SiteSurfaceModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class SiteSurfaceModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModule', + document, + variables, + transform: (data: { + siteSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + siteSurfaceModule: data.siteSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModule', + document, + variables, + transform: (data: { + siteSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + siteSurfaceModule: data.siteSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'SiteSurfaceModule', + 'createSiteSurfaceModule', + 'siteSurfaceModule', + args.select, + args.data, + 'CreateSiteSurfaceModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'createSiteSurfaceModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + SiteSurfaceModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'SiteSurfaceModule', + 'updateSiteSurfaceModule', + 'siteSurfaceModule', + args.select, + args.where.id, + args.data, + 'UpdateSiteSurfaceModuleInput', + 'id', + 'siteSurfaceModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'updateSiteSurfaceModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'SiteSurfaceModule', + 'deleteSiteSurfaceModule', + 'siteSurfaceModule', + { + id: args.where.id, + }, + 'DeleteSiteSurfaceModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'deleteSiteSurfaceModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/admin/hooks/README.md b/sdk/constructive-react/src/admin/hooks/README.md index 29f843ffe..5479468c7 100644 --- a/sdk/constructive-react/src/admin/hooks/README.md +++ b/sdk/constructive-react/src/admin/hooks/README.md @@ -870,10 +870,10 @@ orgIsManagerOf | Argument | Type | |----------|------| - | `pEntityId` | UUID | - | `pManagerId` | UUID | - | `pMaxDepth` | Int | - | `pUserId` | UUID | + | `managerId` | UUID | + | `maxDepth` | Int | + | `targetEntityId` | UUID | + | `userId` | UUID | ### `useOrgPermissionsGetByMaskQuery` diff --git a/sdk/constructive-react/src/admin/hooks/queries/useOrgIsManagerOfQuery.ts b/sdk/constructive-react/src/admin/hooks/queries/useOrgIsManagerOfQuery.ts index 51294fd3c..633e202eb 100644 --- a/sdk/constructive-react/src/admin/hooks/queries/useOrgIsManagerOfQuery.ts +++ b/sdk/constructive-react/src/admin/hooks/queries/useOrgIsManagerOfQuery.ts @@ -19,7 +19,7 @@ export const orgIsManagerOfQueryKey = customQueryKeys.orgIsManagerOf; * * @example * ```tsx - * const { data, isLoading } = useOrgIsManagerOfQuery({ variables: { pEntityId, pManagerId, pMaxDepth, pUserId } }); + * const { data, isLoading } = useOrgIsManagerOfQuery({ variables: { managerId, maxDepth, targetEntityId, userId } }); * * if (data?.orgIsManagerOf) { * console.log(data.orgIsManagerOf); @@ -76,7 +76,7 @@ export function useOrgIsManagerOfQuery< * * @example * ```ts - * const data = await fetchOrgIsManagerOfQuery({ variables: { pEntityId, pManagerId, pMaxDepth, pUserId } }); + * const data = await fetchOrgIsManagerOfQuery({ variables: { managerId, maxDepth, targetEntityId, userId } }); * ``` */ export async function fetchOrgIsManagerOfQuery(params?: { variables?: OrgIsManagerOfVariables }) { @@ -88,7 +88,7 @@ export async function fetchOrgIsManagerOfQuery(params?: { variables?: OrgIsManag * * @example * ```ts - * await prefetchOrgIsManagerOfQuery(queryClient, { variables: { pEntityId, pManagerId, pMaxDepth, pUserId } }); + * await prefetchOrgIsManagerOfQuery(queryClient, { variables: { managerId, maxDepth, targetEntityId, userId } }); * ``` */ export async function prefetchOrgIsManagerOfQuery( diff --git a/sdk/constructive-react/src/admin/orm/README.md b/sdk/constructive-react/src/admin/orm/README.md index af0e170ff..c5a36159a 100644 --- a/sdk/constructive-react/src/admin/orm/README.md +++ b/sdk/constructive-react/src/admin/orm/README.md @@ -1196,13 +1196,13 @@ orgIsManagerOf | Argument | Type | |----------|------| - | `pEntityId` | UUID | - | `pManagerId` | UUID | - | `pMaxDepth` | Int | - | `pUserId` | UUID | + | `managerId` | UUID | + | `maxDepth` | Int | + | `targetEntityId` | UUID | + | `userId` | UUID | ```typescript -const result = await db.query.orgIsManagerOf({ pEntityId: '', pManagerId: '', pMaxDepth: '', pUserId: '' }).execute(); +const result = await db.query.orgIsManagerOf({ managerId: '', maxDepth: '', targetEntityId: '', userId: '' }).execute(); ``` ### `db.query.orgPermissionsGetByMask` diff --git a/sdk/constructive-react/src/admin/orm/query/index.ts b/sdk/constructive-react/src/admin/orm/query/index.ts index 79642089b..6d5f48130 100644 --- a/sdk/constructive-react/src/admin/orm/query/index.ts +++ b/sdk/constructive-react/src/admin/orm/query/index.ts @@ -30,10 +30,10 @@ export interface AppPermissionsGetPaddedMaskVariables { mask?: string; } export interface OrgIsManagerOfVariables { - pEntityId?: string; - pManagerId?: string; - pMaxDepth?: number; - pUserId?: string; + managerId?: string; + maxDepth?: number; + targetEntityId?: string; + userId?: string; } export interface OrgPermissionsGetByMaskVariables { /** Read all values in the set after (below) this cursor. */ @@ -207,19 +207,19 @@ export function createQueryOperations(client: OrmClient) { args, [ { - name: 'pEntityId', + name: 'managerId', type: 'UUID', }, { - name: 'pManagerId', - type: 'UUID', + name: 'maxDepth', + type: 'Int', }, { - name: 'pMaxDepth', - type: 'Int', + name: 'targetEntityId', + type: 'UUID', }, { - name: 'pUserId', + name: 'userId', type: 'UUID', }, ], diff --git a/sdk/constructive-react/src/admin/schema-types.ts b/sdk/constructive-react/src/admin/schema-types.ts index 20dc55761..4356cb4d6 100644 --- a/sdk/constructive-react/src/admin/schema-types.ts +++ b/sdk/constructive-react/src/admin/schema-types.ts @@ -3583,6 +3583,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -3863,6 +3865,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -3895,6 +3910,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -3960,3 +3977,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/agent/schema-types.ts b/sdk/constructive-react/src/agent/schema-types.ts index 0f06f32ce..2fe205b15 100644 --- a/sdk/constructive-react/src/agent/schema-types.ts +++ b/sdk/constructive-react/src/agent/schema-types.ts @@ -1756,6 +1756,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -1910,6 +1912,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -1942,6 +1957,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -2007,3 +2024,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/api/README.md b/sdk/constructive-react/src/api/README.md index 5c390ab25..2f3f1a47a 100644 --- a/sdk/constructive-react/src/api/README.md +++ b/sdk/constructive-react/src/api/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 47 +- **Tables:** 49 - **Custom queries:** 2 - **Custom mutations:** 7 diff --git a/sdk/constructive-react/src/api/hooks/README.md b/sdk/constructive-react/src/api/hooks/README.md index 4cc5bda6d..7f79e3da1 100644 --- a/sdk/constructive-react/src/api/hooks/README.md +++ b/sdk/constructive-react/src/api/hooks/README.md @@ -102,6 +102,16 @@ function App() { | `useCreateDomainMutation` | Mutation | DNS domain and subdomain routing: maps hostnames to either an API endpoint or a site | | `useUpdateDomainMutation` | Mutation | DNS domain and subdomain routing: maps hostnames to either an API endpoint or a site | | `useDeleteDomainMutation` | Mutation | DNS domain and subdomain routing: maps hostnames to either an API endpoint or a site | +| `useDomainEventsQuery` | Query | Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. | +| `useDomainEventQuery` | Query | Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. | +| `useCreateDomainEventMutation` | Mutation | Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. | +| `useUpdateDomainEventMutation` | Mutation | Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. | +| `useDeleteDomainEventMutation` | Mutation | Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. | +| `useDomainVerificationsQuery` | Query | One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. | +| `useDomainVerificationQuery` | Query | One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. | +| `useCreateDomainVerificationMutation` | Mutation | One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. | +| `useUpdateDomainVerificationMutation` | Mutation | One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. | +| `useDeleteDomainVerificationMutation` | Mutation | One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. | | `useEmbeddingChunksQuery` | Query | List all embeddingChunks | | `useEmbeddingChunkQuery` | Query | Get one embeddingChunk | | `useCreateEmbeddingChunkMutation` | Mutation | Create a embeddingChunk | @@ -279,7 +289,7 @@ and lifecycle settings. | | `useRejectDatabaseTransferMutation` | Mutation | rejectDatabaseTransfer | | `useRequestDatabaseMutation` | Mutation | Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); @@ -582,6 +592,48 @@ const { mutate: create } = useCreateDomainMutation({ create({ annotations: '', apiId: '', databaseId: '', domain: '', labels: '', serviceId: '', siteId: '', subdomain: '' }); ``` +### DomainEvent + +```typescript +// List all domainEvents +const { data, isLoading } = useDomainEventsQuery({ + selection: { fields: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }, +}); + +// Get one domainEvent +const { data: item } = useDomainEventQuery({ + id: '', + selection: { fields: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }, +}); + +// Create a domainEvent +const { mutate: create } = useCreateDomainEventMutation({ + selection: { fields: { id: true } }, +}); +create({ actorId: '', domainVerificationId: '', eventType: '', managedDomainId: '', message: '', metadata: '', ownerId: '' }); +``` + +### DomainVerification + +```typescript +// List all domainVerifications +const { data, isLoading } = useDomainVerificationsQuery({ + selection: { fields: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }, +}); + +// Get one domainVerification +const { data: item } = useDomainVerificationQuery({ + id: '', + selection: { fields: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }, +}); + +// Create a domainVerification +const { mutate: create } = useCreateDomainVerificationMutation({ + selection: { fields: { id: true } }, +}); +create({ attempts: '', error: '', expiresAt: '', lastCheckedAt: '', managedDomainId: '', method: '', ownerId: '', recordName: '', recordType: '', recordValue: '', status: '', verifiedAt: '' }); +``` + ### EmbeddingChunk ```typescript @@ -755,20 +807,20 @@ create({ accessMethod: '', category: '', databaseId: '', - selection: { fields: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }, + selection: { fields: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }, }); // Create a managedDomain const { mutate: create } = useCreateManagedDomainMutation({ selection: { fields: { id: true } }, }); -create({ annotations: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }); +create({ allowPublicUsage: '', annotations: '', certStatus: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }); ``` ### NodeTypeRegistry @@ -1298,9 +1350,9 @@ resolveHttpRoute | Argument | Type | |----------|------| - | `pHost` | String | - | `pMethod` | String | - | `pPath` | String | + | `requestHost` | String | + | `requestMethod` | String | + | `requestPath` | String | ### `useAcceptDatabaseTransferMutation` @@ -1364,7 +1416,7 @@ rejectDatabaseTransfer Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-react/src/api/hooks/index.ts b/sdk/constructive-react/src/api/hooks/index.ts index d3bb41d46..ac16e457f 100644 --- a/sdk/constructive-react/src/api/hooks/index.ts +++ b/sdk/constructive-react/src/api/hooks/index.ts @@ -2,7 +2,7 @@ * GraphQL SDK * @generated by @constructive-io/graphql-codegen * - * Tables: Api, ApiModule, ApiSchema, ApiSetting, App, AstMigration, CheckConstraint, CompositeType, CorsSetting, Database, DatabaseSetting, DatabaseTransfer, DefaultPrivilege, Domain, EmbeddingChunk, Enum, Field, ForeignKeyConstraint, FullTextSearch, Function, HttpRoute, Index, ManagedDomain, NodeTypeRegistry, Partition, Policy, PrimaryKeyConstraint, PubkeySetting, RlsSetting, Schema, SchemaGrant, Site, SiteMetadatum, SiteModule, SiteTheme, SpatialRelation, SqlAction, Table, TableGrant, Trigger, TriggerFunction, UniqueConstraint, View, ViewGrant, ViewRule, ViewTable, WebauthnSetting + * Tables: Api, ApiModule, ApiSchema, ApiSetting, App, AstMigration, CheckConstraint, CompositeType, CorsSetting, Database, DatabaseSetting, DatabaseTransfer, DefaultPrivilege, Domain, DomainEvent, DomainVerification, EmbeddingChunk, Enum, Field, ForeignKeyConstraint, FullTextSearch, Function, HttpRoute, Index, ManagedDomain, NodeTypeRegistry, Partition, Policy, PrimaryKeyConstraint, PubkeySetting, RlsSetting, Schema, SchemaGrant, Site, SiteMetadatum, SiteModule, SiteTheme, SpatialRelation, SqlAction, Table, TableGrant, Trigger, TriggerFunction, UniqueConstraint, View, ViewGrant, ViewRule, ViewTable, WebauthnSetting * * Usage: * diff --git a/sdk/constructive-react/src/api/hooks/invalidation.ts b/sdk/constructive-react/src/api/hooks/invalidation.ts index 4ee618adf..3579ec1fa 100644 --- a/sdk/constructive-react/src/api/hooks/invalidation.ts +++ b/sdk/constructive-react/src/api/hooks/invalidation.ts @@ -29,6 +29,8 @@ import { databaseTransferKeys, defaultPrivilegeKeys, domainKeys, + domainEventKeys, + domainVerificationKeys, embeddingChunkKeys, enumKeys, fieldKeys, @@ -309,6 +311,40 @@ export const invalidate = { queryKey: domainKeys.detail(id), }), }, + /** Invalidate domainEvent queries */ domainEvent: { + /** Invalidate all domainEvent queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: domainEventKeys.all, + }), + /** Invalidate domainEvent list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: domainEventKeys.lists(), + }), + /** Invalidate a specific domainEvent */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: domainEventKeys.detail(id), + }), + }, + /** Invalidate domainVerification queries */ domainVerification: { + /** Invalidate all domainVerification queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: domainVerificationKeys.all, + }), + /** Invalidate domainVerification list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: domainVerificationKeys.lists(), + }), + /** Invalidate a specific domainVerification */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: domainVerificationKeys.detail(id), + }), + }, /** Invalidate embeddingChunk queries */ embeddingChunk: { /** Invalidate all embeddingChunk queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -944,6 +980,22 @@ export const remove = { queryKey: domainKeys.detail(id), }); }, + /** Remove domainEvent from cache */ domainEvent: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: domainEventKeys.detail(id), + }); + }, + /** Remove domainVerification from cache */ domainVerification: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: domainVerificationKeys.detail(id), + }); + }, /** Remove embeddingChunk from cache */ embeddingChunk: ( queryClient: QueryClient, id: string | number diff --git a/sdk/constructive-react/src/api/hooks/mutation-keys.ts b/sdk/constructive-react/src/api/hooks/mutation-keys.ts index fa3d71740..6bffb197b 100644 --- a/sdk/constructive-react/src/api/hooks/mutation-keys.ts +++ b/sdk/constructive-react/src/api/hooks/mutation-keys.ts @@ -137,6 +137,24 @@ export const domainMutationKeys = { /** Delete domain mutation key */ delete: (id: string | number) => ['mutation', 'domain', 'delete', id] as const, } as const; +export const domainEventMutationKeys = { + /** All domainEvent mutation keys */ all: ['mutation', 'domainevent'] as const, + /** Create domainEvent mutation key */ create: () => + ['mutation', 'domainevent', 'create'] as const, + /** Update domainEvent mutation key */ update: (id: string | number) => + ['mutation', 'domainevent', 'update', id] as const, + /** Delete domainEvent mutation key */ delete: (id: string | number) => + ['mutation', 'domainevent', 'delete', id] as const, +} as const; +export const domainVerificationMutationKeys = { + /** All domainVerification mutation keys */ all: ['mutation', 'domainverification'] as const, + /** Create domainVerification mutation key */ create: () => + ['mutation', 'domainverification', 'create'] as const, + /** Update domainVerification mutation key */ update: (id: string | number) => + ['mutation', 'domainverification', 'update', id] as const, + /** Delete domainVerification mutation key */ delete: (id: string | number) => + ['mutation', 'domainverification', 'delete', id] as const, +} as const; export const embeddingChunkMutationKeys = { /** All embeddingChunk mutation keys */ all: ['mutation', 'embeddingchunk'] as const, /** Create embeddingChunk mutation key */ create: () => @@ -486,6 +504,8 @@ export const mutationKeys = { databaseTransfer: databaseTransferMutationKeys, defaultPrivilege: defaultPrivilegeMutationKeys, domain: domainMutationKeys, + domainEvent: domainEventMutationKeys, + domainVerification: domainVerificationMutationKeys, embeddingChunk: embeddingChunkMutationKeys, enum: enumMutationKeys, field: fieldMutationKeys, diff --git a/sdk/constructive-react/src/api/hooks/mutations/index.ts b/sdk/constructive-react/src/api/hooks/mutations/index.ts index c5eacaa1a..44a8ad8e9 100644 --- a/sdk/constructive-react/src/api/hooks/mutations/index.ts +++ b/sdk/constructive-react/src/api/hooks/mutations/index.ts @@ -43,6 +43,12 @@ export * from './useDeleteDefaultPrivilegeMutation'; export * from './useCreateDomainMutation'; export * from './useUpdateDomainMutation'; export * from './useDeleteDomainMutation'; +export * from './useCreateDomainEventMutation'; +export * from './useUpdateDomainEventMutation'; +export * from './useDeleteDomainEventMutation'; +export * from './useCreateDomainVerificationMutation'; +export * from './useUpdateDomainVerificationMutation'; +export * from './useDeleteDomainVerificationMutation'; export * from './useCreateEmbeddingChunkMutation'; export * from './useUpdateEmbeddingChunkMutation'; export * from './useDeleteEmbeddingChunkMutation'; diff --git a/sdk/constructive-react/src/api/hooks/mutations/useCreateDomainEventMutation.ts b/sdk/constructive-react/src/api/hooks/mutations/useCreateDomainEventMutation.ts new file mode 100644 index 000000000..49ba6d0c2 --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/mutations/useCreateDomainEventMutation.ts @@ -0,0 +1,88 @@ +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainEventKeys } from '../query-keys'; +import { domainEventMutationKeys } from '../mutation-keys'; +import type { + DomainEventSelect, + DomainEventWithRelations, + CreateDomainEventInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainEventSelect, + DomainEventWithRelations, + CreateDomainEventInput, +} from '../../orm/input-types'; +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateDomainEventMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateDomainEventMutation( + params: { + selection: { + fields: S & DomainEventSelect; + } & HookStrictSelect, DomainEventSelect>; + } & Omit< + UseMutationOptions< + { + createDomainEvent: { + domainEvent: InferSelectResult; + }; + }, + Error, + CreateDomainEventInput['domainEvent'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createDomainEvent: { + domainEvent: InferSelectResult; + }; + }, + Error, + CreateDomainEventInput['domainEvent'] +>; +export function useCreateDomainEventMutation( + params: { + selection: SelectionConfig; + } & Omit, 'mutationFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainEventMutationKeys.create(), + mutationFn: (data: CreateDomainEventInput['domainEvent']) => + getClient() + .domainEvent.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: domainEventKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/api/hooks/mutations/useCreateDomainVerificationMutation.ts b/sdk/constructive-react/src/api/hooks/mutations/useCreateDomainVerificationMutation.ts new file mode 100644 index 000000000..77e04c9bd --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/mutations/useCreateDomainVerificationMutation.ts @@ -0,0 +1,91 @@ +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainVerificationKeys } from '../query-keys'; +import { domainVerificationMutationKeys } from '../mutation-keys'; +import type { + DomainVerificationSelect, + DomainVerificationWithRelations, + CreateDomainVerificationInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainVerificationSelect, + DomainVerificationWithRelations, + CreateDomainVerificationInput, +} from '../../orm/input-types'; +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateDomainVerificationMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateDomainVerificationMutation( + params: { + selection: { + fields: S & DomainVerificationSelect; + } & HookStrictSelect, DomainVerificationSelect>; + } & Omit< + UseMutationOptions< + { + createDomainVerification: { + domainVerification: InferSelectResult; + }; + }, + Error, + CreateDomainVerificationInput['domainVerification'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createDomainVerification: { + domainVerification: InferSelectResult; + }; + }, + Error, + CreateDomainVerificationInput['domainVerification'] +>; +export function useCreateDomainVerificationMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainVerificationMutationKeys.create(), + mutationFn: (data: CreateDomainVerificationInput['domainVerification']) => + getClient() + .domainVerification.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: domainVerificationKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainEventMutation.ts b/sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainEventMutation.ts new file mode 100644 index 000000000..97512b8c5 --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainEventMutation.ts @@ -0,0 +1,98 @@ +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainEventKeys } from '../query-keys'; +import { domainEventMutationKeys } from '../mutation-keys'; +import type { DomainEventSelect, DomainEventWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { DomainEventSelect, DomainEventWithRelations } from '../../orm/input-types'; +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteDomainEventMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteDomainEventMutation( + params: { + selection: { + fields: S & DomainEventSelect; + } & HookStrictSelect, DomainEventSelect>; + } & Omit< + UseMutationOptions< + { + deleteDomainEvent: { + domainEvent: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteDomainEvent: { + domainEvent: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteDomainEventMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainEventMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .domainEvent.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: domainEventKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: domainEventKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainVerificationMutation.ts b/sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainVerificationMutation.ts new file mode 100644 index 000000000..118f8535b --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/mutations/useDeleteDomainVerificationMutation.ts @@ -0,0 +1,104 @@ +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainVerificationKeys } from '../query-keys'; +import { domainVerificationMutationKeys } from '../mutation-keys'; +import type { + DomainVerificationSelect, + DomainVerificationWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainVerificationSelect, + DomainVerificationWithRelations, +} from '../../orm/input-types'; +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteDomainVerificationMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteDomainVerificationMutation( + params: { + selection: { + fields: S & DomainVerificationSelect; + } & HookStrictSelect, DomainVerificationSelect>; + } & Omit< + UseMutationOptions< + { + deleteDomainVerification: { + domainVerification: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteDomainVerification: { + domainVerification: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteDomainVerificationMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainVerificationMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .domainVerification.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: domainVerificationKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: domainVerificationKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainEventMutation.ts b/sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainEventMutation.ts new file mode 100644 index 000000000..39251e33b --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainEventMutation.ts @@ -0,0 +1,110 @@ +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainEventKeys } from '../query-keys'; +import { domainEventMutationKeys } from '../mutation-keys'; +import type { + DomainEventSelect, + DomainEventWithRelations, + DomainEventPatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainEventSelect, + DomainEventWithRelations, + DomainEventPatch, +} from '../../orm/input-types'; +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateDomainEventMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', domainEventPatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateDomainEventMutation( + params: { + selection: { + fields: S & DomainEventSelect; + } & HookStrictSelect, DomainEventSelect>; + } & Omit< + UseMutationOptions< + { + updateDomainEvent: { + domainEvent: InferSelectResult; + }; + }, + Error, + { + id: string; + domainEventPatch: DomainEventPatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateDomainEvent: { + domainEvent: InferSelectResult; + }; + }, + Error, + { + id: string; + domainEventPatch: DomainEventPatch; + } +>; +export function useUpdateDomainEventMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + domainEventPatch: DomainEventPatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainEventMutationKeys.all, + mutationFn: ({ id, domainEventPatch }: { id: string; domainEventPatch: DomainEventPatch }) => + getClient() + .domainEvent.update({ + where: { + id, + }, + data: domainEventPatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: domainEventKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: domainEventKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainVerificationMutation.ts b/sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainVerificationMutation.ts new file mode 100644 index 000000000..7b9ed1073 --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/mutations/useUpdateDomainVerificationMutation.ts @@ -0,0 +1,116 @@ +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainVerificationKeys } from '../query-keys'; +import { domainVerificationMutationKeys } from '../mutation-keys'; +import type { + DomainVerificationSelect, + DomainVerificationWithRelations, + DomainVerificationPatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainVerificationSelect, + DomainVerificationWithRelations, + DomainVerificationPatch, +} from '../../orm/input-types'; +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateDomainVerificationMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', domainVerificationPatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateDomainVerificationMutation( + params: { + selection: { + fields: S & DomainVerificationSelect; + } & HookStrictSelect, DomainVerificationSelect>; + } & Omit< + UseMutationOptions< + { + updateDomainVerification: { + domainVerification: InferSelectResult; + }; + }, + Error, + { + id: string; + domainVerificationPatch: DomainVerificationPatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateDomainVerification: { + domainVerification: InferSelectResult; + }; + }, + Error, + { + id: string; + domainVerificationPatch: DomainVerificationPatch; + } +>; +export function useUpdateDomainVerificationMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + domainVerificationPatch: DomainVerificationPatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainVerificationMutationKeys.all, + mutationFn: ({ + id, + domainVerificationPatch, + }: { + id: string; + domainVerificationPatch: DomainVerificationPatch; + }) => + getClient() + .domainVerification.update({ + where: { + id, + }, + data: domainVerificationPatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: domainVerificationKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: domainVerificationKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/api/hooks/queries/index.ts b/sdk/constructive-react/src/api/hooks/queries/index.ts index 68d7ba475..f1931a9f9 100644 --- a/sdk/constructive-react/src/api/hooks/queries/index.ts +++ b/sdk/constructive-react/src/api/hooks/queries/index.ts @@ -31,6 +31,10 @@ export * from './useDefaultPrivilegesQuery'; export * from './useDefaultPrivilegeQuery'; export * from './useDomainsQuery'; export * from './useDomainQuery'; +export * from './useDomainEventsQuery'; +export * from './useDomainEventQuery'; +export * from './useDomainVerificationsQuery'; +export * from './useDomainVerificationQuery'; export * from './useEmbeddingChunksQuery'; export * from './useEmbeddingChunkQuery'; export * from './useEnumsQuery'; diff --git a/sdk/constructive-react/src/api/hooks/queries/useDomainEventQuery.ts b/sdk/constructive-react/src/api/hooks/queries/useDomainEventQuery.ts new file mode 100644 index 000000000..754508d23 --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/queries/useDomainEventQuery.ts @@ -0,0 +1,138 @@ +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainEventKeys } from '../query-keys'; +import type { DomainEventSelect, DomainEventWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { DomainEventSelect, DomainEventWithRelations } from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const domainEventQueryKey = domainEventKeys.detail; +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```tsx + * const { data, isLoading } = useDomainEventQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useDomainEventQuery< + S extends DomainEventSelect, + TData = { + domainEvent: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainEventSelect>; + } & Omit< + UseQueryOptions< + { + domainEvent: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useDomainEventQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: domainEventKeys.detail(params.id), + queryFn: () => + getClient() + .domainEvent.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```ts + * const data = await fetchDomainEventQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchDomainEventQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainEventSelect>; +}): Promise<{ + domainEvent: InferSelectResult | null; +}>; +export async function fetchDomainEventQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .domainEvent.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```ts + * await prefetchDomainEventQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchDomainEventQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainEventSelect>; + } +): Promise; +export async function prefetchDomainEventQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: domainEventKeys.detail(params.id), + queryFn: () => + getClient() + .domainEvent.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/api/hooks/queries/useDomainEventsQuery.ts b/sdk/constructive-react/src/api/hooks/queries/useDomainEventsQuery.ts new file mode 100644 index 000000000..9240a1a61 --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/queries/useDomainEventsQuery.ts @@ -0,0 +1,145 @@ +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { domainEventKeys } from '../query-keys'; +import type { + DomainEventSelect, + DomainEventWithRelations, + DomainEventFilter, + DomainEventOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + DomainEventSelect, + DomainEventWithRelations, + DomainEventFilter, + DomainEventOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const domainEventsQueryKey = domainEventKeys.list; +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```tsx + * const { data, isLoading } = useDomainEventsQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useDomainEventsQuery< + S extends DomainEventSelect, + TData = { + domainEvents: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, DomainEventSelect>; + } & Omit< + UseQueryOptions< + { + domainEvents: ConnectionResult>; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useDomainEventsQuery( + params: { + selection: ListSelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs( + params.selection + ); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: domainEventKeys.list(args), + queryFn: () => getClient().domainEvent.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```ts + * const data = await fetchDomainEventsQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchDomainEventsQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, DomainEventSelect>; +}): Promise<{ + domainEvents: ConnectionResult>; +}>; +export async function fetchDomainEventsQuery(params: { + selection: ListSelectionConfig; +}) { + const args = buildListSelectionArgs( + params.selection + ); + return getClient().domainEvent.findMany(args).unwrap(); +} +/** + * Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. + * + * @example + * ```ts + * await prefetchDomainEventsQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchDomainEventsQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, DomainEventSelect>; + } +): Promise; +export async function prefetchDomainEventsQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig; + } +): Promise { + const args = buildListSelectionArgs( + params.selection + ); + await queryClient.prefetchQuery({ + queryKey: domainEventKeys.list(args), + queryFn: () => getClient().domainEvent.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/api/hooks/queries/useDomainVerificationQuery.ts b/sdk/constructive-react/src/api/hooks/queries/useDomainVerificationQuery.ts new file mode 100644 index 000000000..37349d79e --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/queries/useDomainVerificationQuery.ts @@ -0,0 +1,144 @@ +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainVerificationKeys } from '../query-keys'; +import type { + DomainVerificationSelect, + DomainVerificationWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainVerificationSelect, + DomainVerificationWithRelations, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const domainVerificationQueryKey = domainVerificationKeys.detail; +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```tsx + * const { data, isLoading } = useDomainVerificationQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useDomainVerificationQuery< + S extends DomainVerificationSelect, + TData = { + domainVerification: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainVerificationSelect>; + } & Omit< + UseQueryOptions< + { + domainVerification: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useDomainVerificationQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: domainVerificationKeys.detail(params.id), + queryFn: () => + getClient() + .domainVerification.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```ts + * const data = await fetchDomainVerificationQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchDomainVerificationQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainVerificationSelect>; +}): Promise<{ + domainVerification: InferSelectResult | null; +}>; +export async function fetchDomainVerificationQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .domainVerification.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```ts + * await prefetchDomainVerificationQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchDomainVerificationQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainVerificationSelect>; + } +): Promise; +export async function prefetchDomainVerificationQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: domainVerificationKeys.detail(params.id), + queryFn: () => + getClient() + .domainVerification.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/api/hooks/queries/useDomainVerificationsQuery.ts b/sdk/constructive-react/src/api/hooks/queries/useDomainVerificationsQuery.ts new file mode 100644 index 000000000..2632d1f40 --- /dev/null +++ b/sdk/constructive-react/src/api/hooks/queries/useDomainVerificationsQuery.ts @@ -0,0 +1,171 @@ +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { domainVerificationKeys } from '../query-keys'; +import type { + DomainVerificationSelect, + DomainVerificationWithRelations, + DomainVerificationFilter, + DomainVerificationOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + DomainVerificationSelect, + DomainVerificationWithRelations, + DomainVerificationFilter, + DomainVerificationOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const domainVerificationsQueryKey = domainVerificationKeys.list; +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```tsx + * const { data, isLoading } = useDomainVerificationsQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useDomainVerificationsQuery< + S extends DomainVerificationSelect, + TData = { + domainVerifications: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, DomainVerificationSelect>; + } & Omit< + UseQueryOptions< + { + domainVerifications: ConnectionResult< + InferSelectResult + >; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useDomainVerificationsQuery( + params: { + selection: ListSelectionConfig< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: domainVerificationKeys.list(args), + queryFn: () => getClient().domainVerification.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```ts + * const data = await fetchDomainVerificationsQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchDomainVerificationsQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, DomainVerificationSelect>; +}): Promise<{ + domainVerifications: ConnectionResult>; +}>; +export async function fetchDomainVerificationsQuery(params: { + selection: ListSelectionConfig< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + >; +}) { + const args = buildListSelectionArgs< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + >(params.selection); + return getClient().domainVerification.findMany(args).unwrap(); +} +/** + * One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. + * + * @example + * ```ts + * await prefetchDomainVerificationsQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchDomainVerificationsQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, DomainVerificationSelect>; + } +): Promise; +export async function prefetchDomainVerificationsQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: domainVerificationKeys.list(args), + queryFn: () => getClient().domainVerification.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/api/hooks/queries/useResolveHttpRouteQuery.ts b/sdk/constructive-react/src/api/hooks/queries/useResolveHttpRouteQuery.ts index 2bd163e3a..104d05258 100644 --- a/sdk/constructive-react/src/api/hooks/queries/useResolveHttpRouteQuery.ts +++ b/sdk/constructive-react/src/api/hooks/queries/useResolveHttpRouteQuery.ts @@ -22,7 +22,7 @@ export const resolveHttpRouteQueryKey = customQueryKeys.resolveHttpRoute; * * @example * ```tsx - * const { data, isLoading } = useResolveHttpRouteQuery({ variables: { pHost, pMethod, pPath }, selection: { fields: { id: true } } }); + * const { data, isLoading } = useResolveHttpRouteQuery({ variables: { requestHost, requestMethod, requestPath }, selection: { fields: { id: true } } }); * * if (data?.resolveHttpRoute) { * console.log(data.resolveHttpRoute); @@ -78,7 +78,7 @@ export function useResolveHttpRouteQuery( * * @example * ```ts - * const data = await fetchResolveHttpRouteQuery({ variables: { pHost, pMethod, pPath }, selection: { fields: { id: true } } }); + * const data = await fetchResolveHttpRouteQuery({ variables: { requestHost, requestMethod, requestPath }, selection: { fields: { id: true } } }); * ``` */ export async function fetchResolveHttpRouteQuery(params: { @@ -106,7 +106,7 @@ export async function fetchResolveHttpRouteQuery(params: { * * @example * ```ts - * await prefetchResolveHttpRouteQuery(queryClient, { variables: { pHost, pMethod, pPath }, selection: { fields: { id: true } } }); + * await prefetchResolveHttpRouteQuery(queryClient, { variables: { requestHost, requestMethod, requestPath }, selection: { fields: { id: true } } }); * ``` */ export async function prefetchResolveHttpRouteQuery( diff --git a/sdk/constructive-react/src/api/hooks/query-keys.ts b/sdk/constructive-react/src/api/hooks/query-keys.ts index a6f0d29cd..881c8ed26 100644 --- a/sdk/constructive-react/src/api/hooks/query-keys.ts +++ b/sdk/constructive-react/src/api/hooks/query-keys.ts @@ -145,6 +145,24 @@ export const domainKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...domainKeys.details(), id] as const, } as const; +export const domainEventKeys = { + /** All domainEvent queries */ all: ['domainevent'] as const, + /** List query keys */ lists: () => [...domainEventKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...domainEventKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...domainEventKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...domainEventKeys.details(), id] as const, +} as const; +export const domainVerificationKeys = { + /** All domainVerification queries */ all: ['domainverification'] as const, + /** List query keys */ lists: () => [...domainVerificationKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...domainVerificationKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...domainVerificationKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...domainVerificationKeys.details(), id] as const, +} as const; export const embeddingChunkKeys = { /** All embeddingChunk queries */ all: ['embeddingchunk'] as const, /** List query keys */ lists: () => [...embeddingChunkKeys.all, 'list'] as const, @@ -490,6 +508,8 @@ export const queryKeys = { databaseTransfer: databaseTransferKeys, defaultPrivilege: defaultPrivilegeKeys, domain: domainKeys, + domainEvent: domainEventKeys, + domainVerification: domainVerificationKeys, embeddingChunk: embeddingChunkKeys, enum: enumKeys, field: fieldKeys, diff --git a/sdk/constructive-react/src/api/orm/README.md b/sdk/constructive-react/src/api/orm/README.md index eaebbb607..05e83f6ea 100644 --- a/sdk/constructive-react/src/api/orm/README.md +++ b/sdk/constructive-react/src/api/orm/README.md @@ -35,6 +35,8 @@ const db = createClient({ | `databaseTransfer` | findMany, findOne, create, update, delete | | `defaultPrivilege` | findMany, findOne, create, update, delete | | `domain` | findMany, findOne, create, update, delete | +| `domainEvent` | findMany, findOne, create, update, delete | +| `domainVerification` | findMany, findOne, create, update, delete | | `embeddingChunk` | findMany, findOne, create, update, delete | | `enum` | findMany, findOne, create, update, delete | | `field` | findMany, findOne, create, update, delete | @@ -601,6 +603,86 @@ const updated = await db.domain.update({ where: { id: '' }, data: { annota const deleted = await db.domain.delete({ where: { id: '' } }).execute(); ``` +### `db.domainEvent` + +CRUD operations for DomainEvent records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `createdAt` | Datetime | No | +| `domainVerificationId` | UUID | Yes | +| `eventType` | String | Yes | +| `id` | UUID | No | +| `managedDomainId` | UUID | Yes | +| `message` | String | Yes | +| `metadata` | JSON | Yes | +| `ownerId` | UUID | Yes | + +**Operations:** + +```typescript +// List all domainEvent records +const items = await db.domainEvent.findMany({ select: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }).execute(); + +// Get one by id +const item = await db.domainEvent.findOne({ id: '', select: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }).execute(); + +// Create +const created = await db.domainEvent.create({ data: { actorId: '', domainVerificationId: '', eventType: '', managedDomainId: '', message: '', metadata: '', ownerId: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainEvent.delete({ where: { id: '' } }).execute(); +``` + +### `db.domainVerification` + +CRUD operations for DomainVerification records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `attempts` | Int | Yes | +| `createdAt` | Datetime | No | +| `error` | String | Yes | +| `expiresAt` | Datetime | Yes | +| `id` | UUID | No | +| `lastCheckedAt` | Datetime | Yes | +| `managedDomainId` | UUID | Yes | +| `method` | String | Yes | +| `ownerId` | UUID | Yes | +| `recordName` | String | Yes | +| `recordType` | String | Yes | +| `recordValue` | String | Yes | +| `status` | String | Yes | +| `updatedAt` | Datetime | No | +| `verifiedAt` | Datetime | Yes | + +**Operations:** + +```typescript +// List all domainVerification records +const items = await db.domainVerification.findMany({ select: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }).execute(); + +// Get one by id +const item = await db.domainVerification.findOne({ id: '', select: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }).execute(); + +// Create +const created = await db.domainVerification.create({ data: { attempts: '', error: '', expiresAt: '', lastCheckedAt: '', managedDomainId: '', method: '', ownerId: '', recordName: '', recordType: '', recordValue: '', status: '', verifiedAt: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainVerification.update({ where: { id: '' }, data: { attempts: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainVerification.delete({ where: { id: '' } }).execute(); +``` + ### `db.embeddingChunk` CRUD operations for EmbeddingChunk records. @@ -947,7 +1029,9 @@ CRUD operations for ManagedDomain records. | Field | Type | Editable | |-------|------|----------| +| `allowPublicUsage` | Boolean | Yes | | `annotations` | JSON | Yes | +| `certStatus` | String | Yes | | `databaseId` | UUID | Yes | | `domain` | ConstructiveInternalTypeHostname | Yes | | `id` | UUID | No | @@ -961,16 +1045,16 @@ CRUD operations for ManagedDomain records. ```typescript // List all managedDomain records -const items = await db.managedDomain.findMany({ select: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); +const items = await db.managedDomain.findMany({ select: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); // Get one by id -const item = await db.managedDomain.findOne({ id: '', select: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); +const item = await db.managedDomain.findOne({ id: '', select: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); // Create -const created = await db.managedDomain.create({ data: { annotations: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute(); +const created = await db.managedDomain.create({ data: { allowPublicUsage: '', annotations: '', certStatus: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute(); // Update -const updated = await db.managedDomain.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); +const updated = await db.managedDomain.update({ where: { id: '' }, data: { allowPublicUsage: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.managedDomain.delete({ where: { id: '' } }).execute(); @@ -1922,12 +2006,12 @@ resolveHttpRoute | Argument | Type | |----------|------| - | `pHost` | String | - | `pMethod` | String | - | `pPath` | String | + | `requestHost` | String | + | `requestMethod` | String | + | `requestPath` | String | ```typescript -const result = await db.query.resolveHttpRoute({ pHost: '', pMethod: '', pPath: '' }).execute(); +const result = await db.query.resolveHttpRoute({ requestHost: '', requestMethod: '', requestPath: '' }).execute(); ``` ### `db.mutation.acceptDatabaseTransfer` @@ -2012,7 +2096,7 @@ const result = await db.mutation.rejectDatabaseTransfer({ input: { transferId: ' Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-react/src/api/orm/index.ts b/sdk/constructive-react/src/api/orm/index.ts index bc2913d21..4d3130d87 100644 --- a/sdk/constructive-react/src/api/orm/index.ts +++ b/sdk/constructive-react/src/api/orm/index.ts @@ -19,6 +19,8 @@ import { DatabaseSettingModel } from './models/databaseSetting'; import { DatabaseTransferModel } from './models/databaseTransfer'; import { DefaultPrivilegeModel } from './models/defaultPrivilege'; import { DomainModel } from './models/domain'; +import { DomainEventModel } from './models/domainEvent'; +import { DomainVerificationModel } from './models/domainVerification'; import { EmbeddingChunkModel } from './models/embeddingChunk'; import { EnumModel } from './models/enum'; import { FieldModel } from './models/field'; @@ -101,6 +103,8 @@ export function createClient(config: OrmClientConfig) { databaseTransfer: new DatabaseTransferModel(client), defaultPrivilege: new DefaultPrivilegeModel(client), domain: new DomainModel(client), + domainEvent: new DomainEventModel(client), + domainVerification: new DomainVerificationModel(client), embeddingChunk: new EmbeddingChunkModel(client), enum: new EnumModel(client), field: new FieldModel(client), diff --git a/sdk/constructive-react/src/api/orm/input-types.ts b/sdk/constructive-react/src/api/orm/input-types.ts index b4c236a86..1180c3e08 100644 --- a/sdk/constructive-react/src/api/orm/input-types.ts +++ b/sdk/constructive-react/src/api/orm/input-types.ts @@ -486,6 +486,60 @@ export interface Domain { /** Subdomain portion of the hostname */ subdomain?: ConstructiveInternalTypeHostname | null; } +/** Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. */ +export interface DomainEvent { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string | null; + /** Event timestamp */ + createdAt?: string | null; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string | null; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType?: string | null; + /** Unique event identifier */ + id: string; + /** The managed_domain this event belongs to */ + managedDomainId?: string | null; + /** Human-readable description of the event */ + message?: string | null; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: Record | null; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId?: string | null; +} +/** One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. */ +export interface DomainVerification { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number | null; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string | null; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string | null; + /** When this challenge expires and must be reissued */ + expiresAt?: string | null; + /** Unique identifier for this verification challenge */ + id: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string | null; + /** The managed_domain this challenge proves ownership of */ + managedDomainId?: string | null; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string | null; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId?: string | null; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string | null; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string | null; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string | null; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string | null; + /** When this row was last updated */ + updatedAt?: string | null; + /** When status last became verified */ + verifiedAt?: string | null; +} export interface EmbeddingChunk { chunkOverlap?: number | null; chunkSize?: number | null; @@ -627,8 +681,12 @@ export interface Index { } /** One row per cert-bearing host or wildcard; tracks domain verification and TLS provisioning independently of services_public.domains. Reconcilers match a route's root domain to a row here by string (no FK/coupling in v1) */ export interface ManagedDomain { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean | null; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: Record | null; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string | null; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId?: string | null; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -639,9 +697,9 @@ export interface ManagedDomain { isWildcard?: boolean | null; /** When tls_status last became active */ tlsReadyAt?: string | null; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string | null; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string | null; /** When verification_status last became verified */ verifiedAt?: string | null; @@ -1128,6 +1186,14 @@ export interface DomainRelations { site?: Site | null; httpRoutes?: ConnectionResult; } +export interface DomainEventRelations { + domainVerification?: DomainVerification | null; + managedDomain?: ManagedDomain | null; +} +export interface DomainVerificationRelations { + managedDomain?: ManagedDomain | null; + domainEvents?: ConnectionResult; +} export interface EmbeddingChunkRelations { chunksTable?: Table | null; database?: Database | null; @@ -1167,6 +1233,8 @@ export interface IndexRelations { } export interface ManagedDomainRelations { database?: Database | null; + domainEvents?: ConnectionResult; + domainVerifications?: ConnectionResult; } export interface NodeTypeRegistryRelations {} export interface PartitionRelations { @@ -1329,6 +1397,8 @@ export type DatabaseSettingWithRelations = DatabaseSetting & DatabaseSettingRela export type DatabaseTransferWithRelations = DatabaseTransfer & DatabaseTransferRelations; export type DefaultPrivilegeWithRelations = DefaultPrivilege & DefaultPrivilegeRelations; export type DomainWithRelations = Domain & DomainRelations; +export type DomainEventWithRelations = DomainEvent & DomainEventRelations; +export type DomainVerificationWithRelations = DomainVerification & DomainVerificationRelations; export type EmbeddingChunkWithRelations = EmbeddingChunk & EmbeddingChunkRelations; export type EnumWithRelations = Enum & EnumRelations; export type FieldWithRelations = Field & FieldRelations; @@ -1873,6 +1943,49 @@ export type DomainSelect = { orderBy?: HttpRouteOrderBy[]; }; }; +export type DomainEventSelect = { + actorId?: boolean; + createdAt?: boolean; + domainVerificationId?: boolean; + eventType?: boolean; + id?: boolean; + managedDomainId?: boolean; + message?: boolean; + metadata?: boolean; + ownerId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + managedDomain?: { + select: ManagedDomainSelect; + }; +}; +export type DomainVerificationSelect = { + attempts?: boolean; + createdAt?: boolean; + error?: boolean; + expiresAt?: boolean; + id?: boolean; + lastCheckedAt?: boolean; + managedDomainId?: boolean; + method?: boolean; + ownerId?: boolean; + recordName?: boolean; + recordType?: boolean; + recordValue?: boolean; + status?: boolean; + updatedAt?: boolean; + verifiedAt?: boolean; + managedDomain?: { + select: ManagedDomainSelect; + }; + domainEvents?: { + select: DomainEventSelect; + first?: number; + filter?: DomainEventFilter; + orderBy?: DomainEventOrderBy[]; + }; +}; export type EmbeddingChunkSelect = { chunkOverlap?: boolean; chunkSize?: boolean; @@ -2073,7 +2186,9 @@ export type IndexSelect = { }; }; export type ManagedDomainSelect = { + allowPublicUsage?: boolean; annotations?: boolean; + certStatus?: boolean; databaseId?: boolean; domain?: boolean; id?: boolean; @@ -2085,6 +2200,18 @@ export type ManagedDomainSelect = { database?: { select: DatabaseSelect; }; + domainEvents?: { + select: DomainEventSelect; + first?: number; + filter?: DomainEventFilter; + orderBy?: DomainEventOrderBy[]; + }; + domainVerifications?: { + select: DomainVerificationSelect; + first?: number; + filter?: DomainVerificationFilter; + orderBy?: DomainVerificationOrderBy[]; + }; }; export type NodeTypeRegistrySelect = { category?: boolean; @@ -3405,6 +3532,82 @@ export interface DomainFilter { /** Filter by the object’s `subdomain` field. */ subdomain?: ConstructiveInternalTypeHostnameFilter; } +export interface DomainEventFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: DomainEventFilter[]; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainVerification` relation. */ + domainVerification?: DomainVerificationFilter; + /** A related `domainVerification` exists. */ + domainVerificationExists?: boolean; + /** Filter by the object’s `domainVerificationId` field. */ + domainVerificationId?: UUIDFilter; + /** Filter by the object’s `eventType` field. */ + eventType?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `message` field. */ + message?: StringFilter; + /** Filter by the object’s `metadata` field. */ + metadata?: JSONFilter; + /** Negates the expression. */ + not?: DomainEventFilter; + /** Checks for any expressions in this list. */ + or?: DomainEventFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; +} +export interface DomainVerificationFilter { + /** Checks for all expressions in this list. */ + and?: DomainVerificationFilter[]; + /** Filter by the object’s `attempts` field. */ + attempts?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: DomainVerificationToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `expiresAt` field. */ + expiresAt?: DatetimeFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `lastCheckedAt` field. */ + lastCheckedAt?: DatetimeFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `method` field. */ + method?: StringFilter; + /** Negates the expression. */ + not?: DomainVerificationFilter; + /** Checks for any expressions in this list. */ + or?: DomainVerificationFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; + /** Filter by the object’s `recordName` field. */ + recordName?: StringFilter; + /** Filter by the object’s `recordType` field. */ + recordType?: StringFilter; + /** Filter by the object’s `recordValue` field. */ + recordValue?: StringFilter; + /** Filter by the object’s `status` field. */ + status?: StringFilter; + /** Filter by the object’s `updatedAt` field. */ + updatedAt?: DatetimeFilter; + /** Filter by the object’s `verifiedAt` field. */ + verifiedAt?: DatetimeFilter; +} export interface EmbeddingChunkFilter { /** Checks for all expressions in this list. */ and?: EmbeddingChunkFilter[]; @@ -3750,16 +3953,28 @@ export interface IndexFilter { whereClause?: JSONFilter; } export interface ManagedDomainFilter { + /** Filter by the object’s `allowPublicUsage` field. */ + allowPublicUsage?: BooleanFilter; /** Checks for all expressions in this list. */ and?: ManagedDomainFilter[]; /** Filter by the object’s `annotations` field. */ annotations?: JSONFilter; + /** Filter by the object’s `certStatus` field. */ + certStatus?: StringFilter; /** Filter by the object’s `database` relation. */ database?: DatabaseFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `domain` field. */ domain?: ConstructiveInternalTypeHostnameFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: ManagedDomainToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `domainVerifications` relation. */ + domainVerifications?: ManagedDomainToManyDomainVerificationFilter; + /** `domainVerifications` exist. */ + domainVerificationsExist?: boolean; /** Filter by the object’s `id` field. */ id?: UUIDFilter; /** Filter by the object’s `isWildcard` field. */ @@ -5104,6 +5319,62 @@ export type DomainOrderBy = | 'SITE_ID_DESC' | 'SUBDOMAIN_ASC' | 'SUBDOMAIN_DESC'; +export type DomainEventOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DOMAIN_VERIFICATION_ID_ASC' + | 'DOMAIN_VERIFICATION_ID_DESC' + | 'EVENT_TYPE_ASC' + | 'EVENT_TYPE_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'MESSAGE_ASC' + | 'MESSAGE_DESC' + | 'METADATA_ASC' + | 'METADATA_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC'; +export type DomainVerificationOrderBy = + | 'ATTEMPTS_ASC' + | 'ATTEMPTS_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'EXPIRES_AT_ASC' + | 'EXPIRES_AT_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'LAST_CHECKED_AT_ASC' + | 'LAST_CHECKED_AT_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'METHOD_ASC' + | 'METHOD_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'RECORD_NAME_ASC' + | 'RECORD_NAME_DESC' + | 'RECORD_TYPE_ASC' + | 'RECORD_TYPE_DESC' + | 'RECORD_VALUE_ASC' + | 'RECORD_VALUE_DESC' + | 'STATUS_ASC' + | 'STATUS_DESC' + | 'UPDATED_AT_ASC' + | 'UPDATED_AT_DESC' + | 'VERIFIED_AT_ASC' + | 'VERIFIED_AT_DESC'; export type EmbeddingChunkOrderBy = | 'CHUNKING_TASK_NAME_ASC' | 'CHUNKING_TASK_NAME_DESC' @@ -5365,8 +5636,12 @@ export type IndexOrderBy = | 'WHERE_CLAUSE_ASC' | 'WHERE_CLAUSE_DESC'; export type ManagedDomainOrderBy = + | 'ALLOW_PUBLIC_USAGE_ASC' + | 'ALLOW_PUBLIC_USAGE_DESC' | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' + | 'CERT_STATUS_ASC' + | 'CERT_STATUS_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DOMAIN_ASC' @@ -6434,6 +6709,76 @@ export interface DeleteDomainInput { clientMutationId?: string; id: string; } +export interface CreateDomainEventInput { + clientMutationId?: string; + domainEvent: { + actorId?: string; + domainVerificationId?: string; + eventType: string; + managedDomainId: string; + message?: string; + metadata?: Record; + ownerId: string; + }; +} +export interface DomainEventPatch { + actorId?: string | null; + domainVerificationId?: string | null; + eventType?: string | null; + managedDomainId?: string | null; + message?: string | null; + metadata?: Record | null; + ownerId?: string | null; +} +export interface UpdateDomainEventInput { + clientMutationId?: string; + id: string; + domainEventPatch: DomainEventPatch; +} +export interface DeleteDomainEventInput { + clientMutationId?: string; + id: string; +} +export interface CreateDomainVerificationInput { + clientMutationId?: string; + domainVerification: { + attempts?: number; + error?: string; + expiresAt?: string; + lastCheckedAt?: string; + managedDomainId: string; + method?: string; + ownerId: string; + recordName?: string; + recordType?: string; + recordValue?: string; + status?: string; + verifiedAt?: string; + }; +} +export interface DomainVerificationPatch { + attempts?: number | null; + error?: string | null; + expiresAt?: string | null; + lastCheckedAt?: string | null; + managedDomainId?: string | null; + method?: string | null; + ownerId?: string | null; + recordName?: string | null; + recordType?: string | null; + recordValue?: string | null; + status?: string | null; + verifiedAt?: string | null; +} +export interface UpdateDomainVerificationInput { + clientMutationId?: string; + id: string; + domainVerificationPatch: DomainVerificationPatch; +} +export interface DeleteDomainVerificationInput { + clientMutationId?: string; + id: string; +} export interface CreateEmbeddingChunkInput { clientMutationId?: string; embeddingChunk: { @@ -6753,7 +7098,9 @@ export interface DeleteIndexInput { export interface CreateManagedDomainInput { clientMutationId?: string; managedDomain: { + allowPublicUsage?: boolean; annotations?: Record; + certStatus?: string; databaseId: string; domain: ConstructiveInternalTypeHostname; isWildcard?: boolean; @@ -6764,7 +7111,9 @@ export interface CreateManagedDomainInput { }; } export interface ManagedDomainPatch { + allowPublicUsage?: boolean | null; annotations?: Record | null; + certStatus?: string | null; databaseId?: string | null; domain?: ConstructiveInternalTypeHostname | null; isWildcard?: boolean | null; @@ -7624,10 +7973,17 @@ export const connectionFieldsMap = { Domain: { httpRoutes: 'HttpRoute', }, + DomainVerification: { + domainEvents: 'DomainEvent', + }, Field: { spatialRelations: 'SpatialRelation', spatialRelationsByRefFieldId: 'SpatialRelation', }, + ManagedDomain: { + domainEvents: 'DomainEvent', + domainVerifications: 'DomainVerification', + }, Schema: { apiSchemas: 'ApiSchema', compositeTypes: 'CompositeType', @@ -8314,6 +8670,15 @@ export interface DomainToManyHttpRouteFilter { /** Filters to entities where at least one related entity matches. */ some?: HttpRouteFilter; } +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} /** A filter to be used against many `SpatialRelation` object types. All fields are combined with a logical ‘and.’ */ export interface FieldToManySpatialRelationFilter { /** Filters to entities where every related entity matches. */ @@ -8323,6 +8688,24 @@ export interface FieldToManySpatialRelationFilter { /** Filters to entities where at least one related entity matches. */ some?: SpatialRelationFilter; } +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} +/** A filter to be used against many `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainVerificationFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainVerificationFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainVerificationFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainVerificationFilter; +} /** A filter to be used against ApiExposureLevel fields. All fields are combined with a logical ‘and.’ */ export interface ApiExposureLevelFilter { /** Not equal to the specified value, treating null like an ordinary value. */ @@ -8923,6 +9306,60 @@ export interface DomainInput { /** Subdomain portion of the hostname */ subdomain?: ConstructiveInternalTypeHostname; } +/** An input for mutations affecting `DomainEvent` */ +export interface DomainEventInput { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string; + /** Event timestamp */ + createdAt?: string; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType: string; + /** Unique event identifier */ + id?: string; + /** The managed_domain this event belongs to */ + managedDomainId: string; + /** Human-readable description of the event */ + message?: string; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: Record; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId: string; +} +/** An input for mutations affecting `DomainVerification` */ +export interface DomainVerificationInput { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string; + /** When this challenge expires and must be reissued */ + expiresAt?: string; + /** Unique identifier for this verification challenge */ + id?: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string; + /** The managed_domain this challenge proves ownership of */ + managedDomainId: string; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId: string; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string; + /** When this row was last updated */ + updatedAt?: string; + /** When status last became verified */ + verifiedAt?: string; +} /** An input for mutations affecting `EmbeddingChunk` */ export interface EmbeddingChunkInput { chunkOverlap?: number; @@ -9071,8 +9508,12 @@ export interface IndexInput { } /** An input for mutations affecting `ManagedDomain` */ export interface ManagedDomainInput { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: Record; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId: string; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -9083,9 +9524,9 @@ export interface ManagedDomainInput { isWildcard?: boolean; /** When tls_status last became active */ tlsReadyAt?: string; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string; /** When verification_status last became verified */ verifiedAt?: string; @@ -10146,16 +10587,28 @@ export interface IndexFilter { } /** A filter to be used against `ManagedDomain` object types. All fields are combined with a logical ‘and.’ */ export interface ManagedDomainFilter { + /** Filter by the object’s `allowPublicUsage` field. */ + allowPublicUsage?: BooleanFilter; /** Checks for all expressions in this list. */ and?: ManagedDomainFilter[]; /** Filter by the object’s `annotations` field. */ annotations?: JSONFilter; + /** Filter by the object’s `certStatus` field. */ + certStatus?: StringFilter; /** Filter by the object’s `database` relation. */ database?: DatabaseFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `domain` field. */ domain?: ConstructiveInternalTypeHostnameFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: ManagedDomainToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `domainVerifications` relation. */ + domainVerifications?: ManagedDomainToManyDomainVerificationFilter; + /** `domainVerifications` exist. */ + domainVerificationsExist?: boolean; /** Filter by the object’s `id` field. */ id?: UUIDFilter; /** Filter by the object’s `isWildcard` field. */ @@ -10979,6 +11432,84 @@ export interface HttpRouteFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +/** A filter to be used against `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainEventFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: DomainEventFilter[]; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainVerification` relation. */ + domainVerification?: DomainVerificationFilter; + /** A related `domainVerification` exists. */ + domainVerificationExists?: boolean; + /** Filter by the object’s `domainVerificationId` field. */ + domainVerificationId?: UUIDFilter; + /** Filter by the object’s `eventType` field. */ + eventType?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `message` field. */ + message?: StringFilter; + /** Filter by the object’s `metadata` field. */ + metadata?: JSONFilter; + /** Negates the expression. */ + not?: DomainEventFilter; + /** Checks for any expressions in this list. */ + or?: DomainEventFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; +} +/** A filter to be used against `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationFilter { + /** Checks for all expressions in this list. */ + and?: DomainVerificationFilter[]; + /** Filter by the object’s `attempts` field. */ + attempts?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: DomainVerificationToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `expiresAt` field. */ + expiresAt?: DatetimeFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `lastCheckedAt` field. */ + lastCheckedAt?: DatetimeFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `method` field. */ + method?: StringFilter; + /** Negates the expression. */ + not?: DomainVerificationFilter; + /** Checks for any expressions in this list. */ + or?: DomainVerificationFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; + /** Filter by the object’s `recordName` field. */ + recordName?: StringFilter; + /** Filter by the object’s `recordType` field. */ + recordType?: StringFilter; + /** Filter by the object’s `recordValue` field. */ + recordValue?: StringFilter; + /** Filter by the object’s `status` field. */ + status?: StringFilter; + /** Filter by the object’s `updatedAt` field. */ + updatedAt?: DatetimeFilter; + /** Filter by the object’s `verifiedAt` field. */ + verifiedAt?: DatetimeFilter; +} /** A filter to be used against UUID fields. All fields are combined with a logical ‘and.’ */ export interface UUIDFilter { /** Not equal to the specified value, treating null like an ordinary value. */ @@ -12426,6 +12957,96 @@ export type DeleteDomainPayloadSelect = { select: DomainEdgeSelect; }; }; +export interface CreateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was created by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type CreateDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface UpdateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was updated by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type UpdateDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface DeleteDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was deleted by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type DeleteDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface CreateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was created by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type CreateDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; +export interface UpdateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was updated by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type UpdateDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; +export interface DeleteDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was deleted by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type DeleteDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; export interface CreateEmbeddingChunkPayload { clientMutationId?: string | null; /** The `EmbeddingChunk` that was created by this mutation. */ @@ -13868,6 +14489,8 @@ export type DeleteWebauthnSettingPayloadSelect = { }; /** Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. */ export interface DatabaseProvisionModule { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string | null; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -13901,6 +14524,7 @@ export interface DatabaseProvisionModule { updatedAt: string; } export type DatabaseProvisionModuleSelect = { + async?: boolean; bootstrapError?: boolean; bootstrapStatus?: boolean; bootstrapUser?: boolean; @@ -14076,6 +14700,30 @@ export type DomainEdgeSelect = { select: DomainSelect; }; }; +/** A `DomainEvent` edge in the connection. */ +export interface DomainEventEdge { + cursor?: string | null; + /** The `DomainEvent` at the end of the edge. */ + node?: DomainEvent | null; +} +export type DomainEventEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainEventSelect; + }; +}; +/** A `DomainVerification` edge in the connection. */ +export interface DomainVerificationEdge { + cursor?: string | null; + /** The `DomainVerification` at the end of the edge. */ + node?: DomainVerification | null; +} +export type DomainVerificationEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainVerificationSelect; + }; +}; /** A `EmbeddingChunk` edge in the connection. */ export interface EmbeddingChunkEdge { cursor?: string | null; diff --git a/sdk/constructive-react/src/api/orm/models/domainEvent.ts b/sdk/constructive-react/src/api/orm/models/domainEvent.ts new file mode 100644 index 000000000..7177a7270 --- /dev/null +++ b/sdk/constructive-react/src/api/orm/models/domainEvent.ts @@ -0,0 +1,245 @@ +/** + * DomainEvent model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainEvent, + DomainEventWithRelations, + DomainEventSelect, + DomainEventFilter, + DomainEventOrderBy, + CreateDomainEventInput, + UpdateDomainEventInput, + DomainEventPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainEventModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvents: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvents', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvent: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvent', + document, + variables, + transform: (data: { + domainEvents?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainEvent: data.domainEvents?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvent: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvent', + document, + variables, + transform: (data: { + domainEvents?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainEvent: data.domainEvents?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainEvent', + 'createDomainEvent', + 'domainEvent', + args.select, + args.data, + 'CreateDomainEventInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'createDomainEvent', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainEventPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainEvent', + 'updateDomainEvent', + 'domainEvent', + args.select, + args.where.id, + args.data, + 'UpdateDomainEventInput', + 'id', + 'domainEventPatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'updateDomainEvent', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainEvent', + 'deleteDomainEvent', + 'domainEvent', + { + id: args.where.id, + }, + 'DeleteDomainEventInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'deleteDomainEvent', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/api/orm/models/domainVerification.ts b/sdk/constructive-react/src/api/orm/models/domainVerification.ts new file mode 100644 index 000000000..b004e0b4d --- /dev/null +++ b/sdk/constructive-react/src/api/orm/models/domainVerification.ts @@ -0,0 +1,245 @@ +/** + * DomainVerification model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainVerification, + DomainVerificationWithRelations, + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy, + CreateDomainVerificationInput, + UpdateDomainVerificationInput, + DomainVerificationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainVerificationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerifications: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerifications', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerification: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerification', + document, + variables, + transform: (data: { + domainVerifications?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainVerification: data.domainVerifications?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerification: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerification', + document, + variables, + transform: (data: { + domainVerifications?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainVerification: data.domainVerifications?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainVerification', + 'createDomainVerification', + 'domainVerification', + args.select, + args.data, + 'CreateDomainVerificationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'createDomainVerification', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainVerificationPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainVerification', + 'updateDomainVerification', + 'domainVerification', + args.select, + args.where.id, + args.data, + 'UpdateDomainVerificationInput', + 'id', + 'domainVerificationPatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'updateDomainVerification', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainVerification', + 'deleteDomainVerification', + 'domainVerification', + { + id: args.where.id, + }, + 'DeleteDomainVerificationInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'deleteDomainVerification', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/api/orm/models/index.ts b/sdk/constructive-react/src/api/orm/models/index.ts index 26dab64b2..a21fca3c5 100644 --- a/sdk/constructive-react/src/api/orm/models/index.ts +++ b/sdk/constructive-react/src/api/orm/models/index.ts @@ -17,6 +17,8 @@ export { DatabaseSettingModel } from './databaseSetting'; export { DatabaseTransferModel } from './databaseTransfer'; export { DefaultPrivilegeModel } from './defaultPrivilege'; export { DomainModel } from './domain'; +export { DomainEventModel } from './domainEvent'; +export { DomainVerificationModel } from './domainVerification'; export { EmbeddingChunkModel } from './embeddingChunk'; export { EnumModel } from './enum'; export { FieldModel } from './field'; diff --git a/sdk/constructive-react/src/api/orm/mutation/index.ts b/sdk/constructive-react/src/api/orm/mutation/index.ts index 242a60b79..0192a395b 100644 --- a/sdk/constructive-react/src/api/orm/mutation/index.ts +++ b/sdk/constructive-react/src/api/orm/mutation/index.ts @@ -56,7 +56,7 @@ export interface RejectDatabaseTransferVariables { * Variables for requestDatabase * Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-react/src/api/orm/query/index.ts b/sdk/constructive-react/src/api/orm/query/index.ts index 0b7b1b1f0..1e86e6234 100644 --- a/sdk/constructive-react/src/api/orm/query/index.ts +++ b/sdk/constructive-react/src/api/orm/query/index.ts @@ -13,9 +13,9 @@ export interface ApplyRegistryDefaultsVariables { nodeType?: string; } export interface ResolveHttpRouteVariables { - pHost?: string; - pMethod?: string; - pPath?: string; + requestHost?: string; + requestMethod?: string; + requestPath?: string; } export function createQueryOperations(client: OrmClient) { return { @@ -73,15 +73,15 @@ export function createQueryOperations(client: OrmClient) { args, [ { - name: 'pHost', + name: 'requestHost', type: 'String', }, { - name: 'pMethod', + name: 'requestMethod', type: 'String', }, { - name: 'pPath', + name: 'requestPath', type: 'String', }, ], diff --git a/sdk/constructive-react/src/api/schema-types.ts b/sdk/constructive-react/src/api/schema-types.ts index 993d1754c..e9778ad7e 100644 --- a/sdk/constructive-react/src/api/schema-types.ts +++ b/sdk/constructive-react/src/api/schema-types.ts @@ -19,6 +19,8 @@ import type { DatabaseTransfer, DefaultPrivilege, Domain, + DomainEvent, + DomainVerification, EmbeddingChunk, Enum, Field, @@ -396,6 +398,29 @@ export type DefaultPrivilegeOrderBy = | 'PRIVILEGE_DESC' | 'SCHEMA_ID_ASC' | 'SCHEMA_ID_DESC'; +/** Methods to use when ordering `DomainEvent`. */ +export type DomainEventOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DOMAIN_VERIFICATION_ID_ASC' + | 'DOMAIN_VERIFICATION_ID_DESC' + | 'EVENT_TYPE_ASC' + | 'EVENT_TYPE_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'MESSAGE_ASC' + | 'MESSAGE_DESC' + | 'METADATA_ASC' + | 'METADATA_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC'; /** Methods to use when ordering `Domain`. */ export type DomainOrderBy = | 'ANNOTATIONS_ASC' @@ -419,6 +444,41 @@ export type DomainOrderBy = | 'SITE_ID_DESC' | 'SUBDOMAIN_ASC' | 'SUBDOMAIN_DESC'; +/** Methods to use when ordering `DomainVerification`. */ +export type DomainVerificationOrderBy = + | 'ATTEMPTS_ASC' + | 'ATTEMPTS_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'EXPIRES_AT_ASC' + | 'EXPIRES_AT_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'LAST_CHECKED_AT_ASC' + | 'LAST_CHECKED_AT_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'METHOD_ASC' + | 'METHOD_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'RECORD_NAME_ASC' + | 'RECORD_NAME_DESC' + | 'RECORD_TYPE_ASC' + | 'RECORD_TYPE_DESC' + | 'RECORD_VALUE_ASC' + | 'RECORD_VALUE_DESC' + | 'STATUS_ASC' + | 'STATUS_DESC' + | 'UPDATED_AT_ASC' + | 'UPDATED_AT_DESC' + | 'VERIFIED_AT_ASC' + | 'VERIFIED_AT_DESC'; /** Methods to use when ordering `EmbeddingChunk`. */ export type EmbeddingChunkOrderBy = | 'CHUNKING_TASK_NAME_ASC' @@ -689,8 +749,12 @@ export type IndexOrderBy = | 'WHERE_CLAUSE_DESC'; /** Methods to use when ordering `ManagedDomain`. */ export type ManagedDomainOrderBy = + | 'ALLOW_PUBLIC_USAGE_ASC' + | 'ALLOW_PUBLIC_USAGE_DESC' | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' + | 'CERT_STATUS_ASC' + | 'CERT_STATUS_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DOMAIN_ASC' @@ -2307,11 +2371,21 @@ export interface CreateDefaultPrivilegeInput { /** The `DefaultPrivilege` to be created by this mutation. */ defaultPrivilege: DefaultPrivilegeInput; } +export interface CreateDomainEventInput { + clientMutationId?: string; + /** The `DomainEvent` to be created by this mutation. */ + domainEvent: DomainEventInput; +} export interface CreateDomainInput { clientMutationId?: string; /** The `Domain` to be created by this mutation. */ domain: DomainInput; } +export interface CreateDomainVerificationInput { + clientMutationId?: string; + /** The `DomainVerification` to be created by this mutation. */ + domainVerification: DomainVerificationInput; +} export interface CreateEmbeddingChunkInput { clientMutationId?: string; /** The `EmbeddingChunk` to be created by this mutation. */ @@ -3327,11 +3401,21 @@ export interface DeleteDefaultPrivilegeInput { clientMutationId?: string; id: string; } +export interface DeleteDomainEventInput { + clientMutationId?: string; + /** Unique event identifier */ + id: string; +} export interface DeleteDomainInput { clientMutationId?: string; /** Unique identifier for this domain record */ id: string; } +export interface DeleteDomainVerificationInput { + clientMutationId?: string; + /** Unique identifier for this verification challenge */ + id: string; +} export interface DeleteEmbeddingChunkInput { clientMutationId?: string; id: string; @@ -3468,6 +3552,81 @@ export interface DeleteWebauthnSettingInput { /** Unique identifier for this WebAuthn settings record */ id: string; } +/** A filter to be used against `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainEventFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: DomainEventFilter[]; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainVerification` relation. */ + domainVerification?: DomainVerificationFilter; + /** A related `domainVerification` exists. */ + domainVerificationExists?: boolean; + /** Filter by the object’s `domainVerificationId` field. */ + domainVerificationId?: UUIDFilter; + /** Filter by the object’s `eventType` field. */ + eventType?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `message` field. */ + message?: StringFilter; + /** Filter by the object’s `metadata` field. */ + metadata?: JSONFilter; + /** Negates the expression. */ + not?: DomainEventFilter; + /** Checks for any expressions in this list. */ + or?: DomainEventFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; +} +/** An input for mutations affecting `DomainEvent` */ +export interface DomainEventInput { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string; + /** Event timestamp */ + createdAt?: string; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType: string; + /** Unique event identifier */ + id?: string; + /** The managed_domain this event belongs to */ + managedDomainId: string; + /** Human-readable description of the event */ + message?: string; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: unknown; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId: string; +} +/** Represents an update to a `DomainEvent`. Fields that are set will be updated. */ +export interface DomainEventPatch { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string; + /** Event timestamp */ + createdAt?: string; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType?: string; + /** Unique event identifier */ + id?: string; + /** The managed_domain this event belongs to */ + managedDomainId?: string; + /** Human-readable description of the event */ + message?: string; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: unknown; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId?: string; +} /** A filter to be used against `Domain` object types. All fields are combined with a logical ‘and.’ */ export interface DomainFilter { /** Checks for all expressions in this list. */ @@ -3560,6 +3719,126 @@ export interface DomainToManyHttpRouteFilter { /** Filters to entities where at least one related entity matches. */ some?: HttpRouteFilter; } +/** A filter to be used against `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationFilter { + /** Checks for all expressions in this list. */ + and?: DomainVerificationFilter[]; + /** Filter by the object’s `attempts` field. */ + attempts?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: DomainVerificationToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `expiresAt` field. */ + expiresAt?: DatetimeFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `lastCheckedAt` field. */ + lastCheckedAt?: DatetimeFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `method` field. */ + method?: StringFilter; + /** Negates the expression. */ + not?: DomainVerificationFilter; + /** Checks for any expressions in this list. */ + or?: DomainVerificationFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; + /** Filter by the object’s `recordName` field. */ + recordName?: StringFilter; + /** Filter by the object’s `recordType` field. */ + recordType?: StringFilter; + /** Filter by the object’s `recordValue` field. */ + recordValue?: StringFilter; + /** Filter by the object’s `status` field. */ + status?: StringFilter; + /** Filter by the object’s `updatedAt` field. */ + updatedAt?: DatetimeFilter; + /** Filter by the object’s `verifiedAt` field. */ + verifiedAt?: DatetimeFilter; +} +/** An input for mutations affecting `DomainVerification` */ +export interface DomainVerificationInput { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string; + /** When this challenge expires and must be reissued */ + expiresAt?: string; + /** Unique identifier for this verification challenge */ + id?: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string; + /** The managed_domain this challenge proves ownership of */ + managedDomainId: string; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId: string; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string; + /** When this row was last updated */ + updatedAt?: string; + /** When status last became verified */ + verifiedAt?: string; +} +/** Represents an update to a `DomainVerification`. Fields that are set will be updated. */ +export interface DomainVerificationPatch { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string; + /** When this challenge expires and must be reissued */ + expiresAt?: string; + /** Unique identifier for this verification challenge */ + id?: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string; + /** The managed_domain this challenge proves ownership of */ + managedDomainId?: string; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId?: string; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string; + /** When this row was last updated */ + updatedAt?: string; + /** When status last became verified */ + verifiedAt?: string; +} +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} /** A filter to be used against `EmbeddingChunk` object types. All fields are combined with a logical ‘and.’ */ export interface EmbeddingChunkFilter { /** Checks for all expressions in this list. */ @@ -4215,16 +4494,28 @@ export interface IndexPatch { } /** A filter to be used against `ManagedDomain` object types. All fields are combined with a logical ‘and.’ */ export interface ManagedDomainFilter { + /** Filter by the object’s `allowPublicUsage` field. */ + allowPublicUsage?: BooleanFilter; /** Checks for all expressions in this list. */ and?: ManagedDomainFilter[]; /** Filter by the object’s `annotations` field. */ annotations?: JSONFilter; + /** Filter by the object’s `certStatus` field. */ + certStatus?: StringFilter; /** Filter by the object’s `database` relation. */ database?: DatabaseFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `domain` field. */ domain?: ConstructiveInternalTypeHostnameFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: ManagedDomainToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `domainVerifications` relation. */ + domainVerifications?: ManagedDomainToManyDomainVerificationFilter; + /** `domainVerifications` exist. */ + domainVerificationsExist?: boolean; /** Filter by the object’s `id` field. */ id?: UUIDFilter; /** Filter by the object’s `isWildcard` field. */ @@ -4244,8 +4535,12 @@ export interface ManagedDomainFilter { } /** An input for mutations affecting `ManagedDomain` */ export interface ManagedDomainInput { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: unknown; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId: string; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -4256,17 +4551,21 @@ export interface ManagedDomainInput { isWildcard?: boolean; /** When tls_status last became active */ tlsReadyAt?: string; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string; /** When verification_status last became verified */ verifiedAt?: string; } /** Represents an update to a `ManagedDomain`. Fields that are set will be updated. */ export interface ManagedDomainPatch { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: unknown; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId?: string; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -4277,13 +4576,31 @@ export interface ManagedDomainPatch { isWildcard?: boolean; /** When tls_status last became active */ tlsReadyAt?: string; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string; /** When verification_status last became verified */ verifiedAt?: string; } +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} +/** A filter to be used against many `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainVerificationFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainVerificationFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainVerificationFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainVerificationFilter; +} /** A filter to be used against `NodeTypeRegistry` object types. All fields are combined with a logical ‘and.’ */ export interface NodeTypeRegistryFilter { /** Checks for all expressions in this list. */ @@ -6031,6 +6348,13 @@ export interface UpdateDefaultPrivilegeInput { defaultPrivilegePatch: DefaultPrivilegePatch; id: string; } +export interface UpdateDomainEventInput { + clientMutationId?: string; + /** An object where the defined keys will be set on the `DomainEvent` being updated. */ + domainEventPatch: DomainEventPatch; + /** Unique event identifier */ + id: string; +} export interface UpdateDomainInput { clientMutationId?: string; /** An object where the defined keys will be set on the `Domain` being updated. */ @@ -6038,6 +6362,13 @@ export interface UpdateDomainInput { /** Unique identifier for this domain record */ id: string; } +export interface UpdateDomainVerificationInput { + clientMutationId?: string; + /** An object where the defined keys will be set on the `DomainVerification` being updated. */ + domainVerificationPatch: DomainVerificationPatch; + /** Unique identifier for this verification challenge */ + id: string; +} export interface UpdateEmbeddingChunkInput { clientMutationId?: string; /** An object where the defined keys will be set on the `EmbeddingChunk` being updated. */ @@ -6747,6 +7078,20 @@ export interface DefaultPrivilegeConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `DomainEvent` values. */ +export interface DomainEventConnection { + edges: DomainEventEdge[]; + nodes: DomainEvent[]; + pageInfo: PageInfo; + totalCount: number; +} +/** A connection to a list of `DomainVerification` values. */ +export interface DomainVerificationConnection { + edges: DomainVerificationEdge[]; + nodes: DomainVerification[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `Domain` values. */ export interface DomainConnection { edges: DomainEdge[]; @@ -7083,6 +7428,18 @@ export interface CreateDomainPayload { domain?: Domain | null; domainEdge?: DomainEdge | null; } +export interface CreateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was created by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export interface CreateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was created by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} export interface CreateEmbeddingChunkPayload { clientMutationId?: string | null; /** The `EmbeddingChunk` that was created by this mutation. */ @@ -7353,6 +7710,18 @@ export interface DeleteDomainPayload { domain?: Domain | null; domainEdge?: DomainEdge | null; } +export interface DeleteDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was deleted by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export interface DeleteDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was deleted by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} export interface DeleteEmbeddingChunkPayload { clientMutationId?: string | null; /** The `EmbeddingChunk` that was deleted by this mutation. */ @@ -7648,6 +8017,18 @@ export interface UpdateDomainPayload { domain?: Domain | null; domainEdge?: DomainEdge | null; } +export interface UpdateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was updated by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export interface UpdateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was updated by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} export interface UpdateEmbeddingChunkPayload { clientMutationId?: string | null; /** The `EmbeddingChunk` that was updated by this mutation. */ @@ -7856,6 +8237,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -7951,6 +8334,18 @@ export interface DefaultPrivilegeEdge { /** The `DefaultPrivilege` at the end of the edge. */ node?: DefaultPrivilege | null; } +/** A `DomainEvent` edge in the connection. */ +export interface DomainEventEdge { + cursor?: string | null; + /** The `DomainEvent` at the end of the edge. */ + node?: DomainEvent | null; +} +/** A `DomainVerification` edge in the connection. */ +export interface DomainVerificationEdge { + cursor?: string | null; + /** The `DomainVerification` at the end of the edge. */ + node?: DomainVerification | null; +} /** A `Domain` edge in the connection. */ export interface DomainEdge { cursor?: string | null; @@ -8157,6 +8552,8 @@ export interface WebauthnSettingEdge { } /** Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. */ export interface DatabaseProvisionModule { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string | null; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -8272,6 +8669,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -8304,6 +8714,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -8369,3 +8781,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/api/types.ts b/sdk/constructive-react/src/api/types.ts index 528358496..3971bbb3a 100644 --- a/sdk/constructive-react/src/api/types.ts +++ b/sdk/constructive-react/src/api/types.ts @@ -174,6 +174,34 @@ export interface Domain { siteId: string | null; subdomain: ConstructiveInternalTypeHostname | null; } +export interface DomainEvent { + actorId: string | null; + createdAt: string | null; + domainVerificationId: string | null; + eventType: string | null; + id: string | null; + managedDomainId: string | null; + message: string | null; + metadata: unknown | null; + ownerId: string | null; +} +export interface DomainVerification { + attempts: number | null; + createdAt: string | null; + error: string | null; + expiresAt: string | null; + id: string | null; + lastCheckedAt: string | null; + managedDomainId: string | null; + method: string | null; + ownerId: string | null; + recordName: string | null; + recordType: string | null; + recordValue: string | null; + status: string | null; + updatedAt: string | null; + verifiedAt: string | null; +} export interface EmbeddingChunk { chunkOverlap: number | null; chunkSize: number | null; @@ -305,7 +333,9 @@ export interface Index { whereClause: unknown | null; } export interface ManagedDomain { + allowPublicUsage: boolean | null; annotations: unknown | null; + certStatus: string | null; databaseId: string | null; domain: ConstructiveInternalTypeHostname | null; id: string | null; diff --git a/sdk/constructive-react/src/auth/schema-types.ts b/sdk/constructive-react/src/auth/schema-types.ts index 5403f23be..efbac343f 100644 --- a/sdk/constructive-react/src/auth/schema-types.ts +++ b/sdk/constructive-react/src/auth/schema-types.ts @@ -2056,6 +2056,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -2285,6 +2287,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -2317,6 +2332,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -2382,3 +2399,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/compute/README.md b/sdk/constructive-react/src/compute/README.md index 3e8305921..a896e6ebe 100644 --- a/sdk/constructive-react/src/compute/README.md +++ b/sdk/constructive-react/src/compute/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 65 +- **Tables:** 67 - **Custom queries:** 1 - **Custom mutations:** 28 diff --git a/sdk/constructive-react/src/compute/hooks/README.md b/sdk/constructive-react/src/compute/hooks/README.md index 8dea333bf..adcf565cf 100644 --- a/sdk/constructive-react/src/compute/hooks/README.md +++ b/sdk/constructive-react/src/compute/hooks/README.md @@ -37,8 +37,6 @@ function App() { | `useCreateDbPresetMutation` | Mutation | Database provisioning preset catalog — merkle-versioned head over the infra store | | `useUpdateDbPresetMutation` | Mutation | Database provisioning preset catalog — merkle-versioned head over the infra store | | `useDeleteDbPresetMutation` | Mutation | Database provisioning preset catalog — merkle-versioned head over the infra store | -| `useDeclaredCapacitiesQuery` | Query | List all declaredCapacities | -| `useCreateDeclaredCapacityMutation` | Mutation | Create a declaredCapacity | | `useFunctionApiBindingsQuery` | Query | Join table binding function definitions to API endpoints with per-binding alias and config | | `useFunctionApiBindingQuery` | Query | Join table binding function definitions to API endpoints with per-binding alias and config | | `useCreateFunctionApiBindingMutation` | Mutation | Join table binding function definitions to API endpoints with per-binding alias and config | @@ -104,6 +102,11 @@ function App() { | `useCreateFunctionGraphStoreMutation` | Mutation | Named stores — one per version-controlled tree (e.g. one graph, one definition set) | | `useUpdateFunctionGraphStoreMutation` | Mutation | Named stores — one per version-controlled tree (e.g. one graph, one definition set) | | `useDeleteFunctionGraphStoreMutation` | Mutation | Named stores — one per version-controlled tree (e.g. one graph, one definition set) | +| `useFunctionInvocationAttemptsQuery` | Query | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `useFunctionInvocationAttemptQuery` | Query | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `useCreateFunctionInvocationAttemptMutation` | Mutation | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `useUpdateFunctionInvocationAttemptMutation` | Mutation | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `useDeleteFunctionInvocationAttemptMutation` | Mutation | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | | `useFunctionInvocationsQuery` | Query | Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. | | `useFunctionInvocationQuery` | Query | Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. | | `useCreateFunctionInvocationMutation` | Mutation | Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. | @@ -148,8 +151,6 @@ function App() { | `useCreateNamespaceEventMutation` | Mutation | Namespace lifecycle events — audit log of creation, activation, deactivation, label changes | | `useUpdateNamespaceEventMutation` | Mutation | Namespace lifecycle events — audit log of creation, activation, deactivation, label changes | | `useDeleteNamespaceEventMutation` | Mutation | Namespace lifecycle events — audit log of creation, activation, deactivation, label changes | -| `usePlatformDeclaredCapacitiesQuery` | Query | List all platformDeclaredCapacities | -| `useCreatePlatformDeclaredCapacityMutation` | Mutation | Create a platformDeclaredCapacity | | `usePlatformFunctionApiBindingsQuery` | Query | Join table binding function definitions to API endpoints with per-binding alias and config | | `usePlatformFunctionApiBindingQuery` | Query | Join table binding function definitions to API endpoints with per-binding alias and config | | `useCreatePlatformFunctionApiBindingMutation` | Mutation | Join table binding function definitions to API endpoints with per-binding alias and config | @@ -175,6 +176,11 @@ function App() { | `useCreatePlatformFunctionExecutionLogMutation` | Mutation | Function execution logs — structured console output per invocation | | `useUpdatePlatformFunctionExecutionLogMutation` | Mutation | Function execution logs — structured console output per invocation | | `useDeletePlatformFunctionExecutionLogMutation` | Mutation | Function execution logs — structured console output per invocation | +| `usePlatformFunctionInvocationAttemptsQuery` | Query | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `usePlatformFunctionInvocationAttemptQuery` | Query | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `useCreatePlatformFunctionInvocationAttemptMutation` | Mutation | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `useUpdatePlatformFunctionInvocationAttemptMutation` | Mutation | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | +| `useDeletePlatformFunctionInvocationAttemptMutation` | Mutation | Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail | | `usePlatformFunctionInvocationsQuery` | Query | Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. | | `usePlatformFunctionInvocationQuery` | Query | Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. | | `useCreatePlatformFunctionInvocationMutation` | Mutation | Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. | @@ -217,6 +223,8 @@ function App() { | `useCreatePlatformResourceMutation` | Mutation | Unified K8s resource declarations — stores desired state (spec) and observed state (status) for all resource kinds within a namespace | | `useUpdatePlatformResourceMutation` | Mutation | Unified K8s resource declarations — stores desired state (spec) and observed state (status) for all resource kinds within a namespace | | `useDeletePlatformResourceMutation` | Mutation | Unified K8s resource declarations — stores desired state (spec) and observed state (status) for all resource kinds within a namespace | +| `usePlatformResourceDeclaredCapacitiesQuery` | Query | List all platformResourceDeclaredCapacities | +| `useCreatePlatformResourceDeclaredCapacityMutation` | Mutation | Create a platformResourceDeclaredCapacity | | `usePlatformResourceDefinitionsQuery` | Query | Resource definitions — templates for resource kinds declaring default spec and secret/config requirements | | `usePlatformResourceDefinitionQuery` | Query | Resource definitions — templates for resource kinds declaring default spec and secret/config requirements | | `useCreatePlatformResourceDefinitionMutation` | Mutation | Resource definitions — templates for resource kinds declaring default spec and secret/config requirements | @@ -237,18 +245,18 @@ function App() { | `useCreatePlatformResourceStatusCheckMutation` | Mutation | On-demand resource status checks — diagnostic snapshots from the runtime (K8s status, conditions, log tails) | | `useUpdatePlatformResourceStatusCheckMutation` | Mutation | On-demand resource status checks — diagnostic snapshots from the runtime (K8s status, conditions, log tails) | | `useDeletePlatformResourceStatusCheckMutation` | Mutation | On-demand resource status checks — diagnostic snapshots from the runtime (K8s status, conditions, log tails) | -| `usePlatformResourceUsageLogsQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `usePlatformResourceUsageLogQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `useCreatePlatformResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `useUpdatePlatformResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `useDeletePlatformResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | +| `usePlatformResourceUsageLogsQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `usePlatformResourceUsageLogQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `useCreatePlatformResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `useUpdatePlatformResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `useDeletePlatformResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | | `usePlatformResourceUsageSummariesQuery` | Query | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `usePlatformResourceUsageSummaryQuery` | Query | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `useCreatePlatformResourceUsageSummaryMutation` | Mutation | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `useUpdatePlatformResourceUsageSummaryMutation` | Mutation | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `useDeletePlatformResourceUsageSummaryMutation` | Mutation | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | -| `usePlatformResourceUtilizationDailiesQuery` | Query | List all platformResourceUtilizationDailies | -| `useCreatePlatformResourceUtilizationDailyMutation` | Mutation | Create a platformResourceUtilizationDaily | +| `usePlatformResourceUtilizationsQuery` | Query | List all platformResourceUtilizations | +| `useCreatePlatformResourceUtilizationMutation` | Mutation | Create a platformResourceUtilization | | `usePlatformResourcesHealthsQuery` | Query | List all platformResourcesHealths | | `usePlatformResourcesHealthQuery` | Query | Get one platformResourcesHealth | | `useCreatePlatformResourcesHealthMutation` | Mutation | Create a platformResourcesHealth | @@ -273,6 +281,8 @@ function App() { | `useCreateResourceMutation` | Mutation | Unified K8s resource declarations — stores desired state (spec) and observed state (status) for all resource kinds within a namespace | | `useUpdateResourceMutation` | Mutation | Unified K8s resource declarations — stores desired state (spec) and observed state (status) for all resource kinds within a namespace | | `useDeleteResourceMutation` | Mutation | Unified K8s resource declarations — stores desired state (spec) and observed state (status) for all resource kinds within a namespace | +| `useResourceDeclaredCapacitiesQuery` | Query | List all resourceDeclaredCapacities | +| `useCreateResourceDeclaredCapacityMutation` | Mutation | Create a resourceDeclaredCapacity | | `useResourceDefinitionsQuery` | Query | Resource definitions — templates for resource kinds declaring default spec and secret/config requirements | | `useResourceDefinitionQuery` | Query | Resource definitions — templates for resource kinds declaring default spec and secret/config requirements | | `useCreateResourceDefinitionMutation` | Mutation | Resource definitions — templates for resource kinds declaring default spec and secret/config requirements | @@ -293,18 +303,18 @@ function App() { | `useCreateResourceStatusCheckMutation` | Mutation | On-demand resource status checks — diagnostic snapshots from the runtime (K8s status, conditions, log tails) | | `useUpdateResourceStatusCheckMutation` | Mutation | On-demand resource status checks — diagnostic snapshots from the runtime (K8s status, conditions, log tails) | | `useDeleteResourceStatusCheckMutation` | Mutation | On-demand resource status checks — diagnostic snapshots from the runtime (K8s status, conditions, log tails) | -| `useResourceUsageLogsQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `useResourceUsageLogQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `useCreateResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `useUpdateResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | -| `useDeleteResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) | +| `useResourceUsageLogsQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `useResourceUsageLogQuery` | Query | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `useCreateResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `useUpdateResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | +| `useDeleteResourceUsageLogMutation` | Mutation | Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) | | `useResourceUsageSummariesQuery` | Query | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `useResourceUsageSummaryQuery` | Query | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `useCreateResourceUsageSummaryMutation` | Mutation | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `useUpdateResourceUsageSummaryMutation` | Mutation | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | | `useDeleteResourceUsageSummaryMutation` | Mutation | Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals | -| `useResourceUtilizationDailiesQuery` | Query | List all resourceUtilizationDailies | -| `useCreateResourceUtilizationDailyMutation` | Mutation | Create a resourceUtilizationDaily | +| `useResourceUtilizationsQuery` | Query | List all resourceUtilizations | +| `useCreateResourceUtilizationMutation` | Mutation | Create a resourceUtilization | | `useResourcesHealthsQuery` | Query | List all resourcesHealths | | `useResourcesHealthQuery` | Query | Get one resourcesHealth | | `useCreateResourcesHealthMutation` | Mutation | Create a resourcesHealth | @@ -380,21 +390,6 @@ const { mutate: create } = useCreateDbPresetMutation({ create({ active: '', commitId: '', definition: '', description: '', label: '', modulesHash: '', slug: '', storeId: '' }); ``` -### DeclaredCapacity - -```typescript -// List all declaredCapacities -const { data, isLoading } = useDeclaredCapacitiesQuery({ - selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }, -}); - -// Create a declaredCapacity -const { mutate: create } = useCreateDeclaredCapacityMutation({ - selection: { fields: { id: true } }, -}); -create({ cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }); -``` - ### FunctionApiBinding ```typescript @@ -668,6 +663,27 @@ const { mutate: create } = useCreateFunctionGraphStoreMutation({ create({ hash: '', name: '', scopeId: '' }); ``` +### FunctionInvocationAttempt + +```typescript +// List all functionInvocationAttempts +const { data, isLoading } = useFunctionInvocationAttemptsQuery({ + selection: { fields: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }, +}); + +// Get one functionInvocationAttempt +const { data: item } = useFunctionInvocationAttemptQuery({ + id: '', + selection: { fields: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }, +}); + +// Create a functionInvocationAttempt +const { mutate: create } = useCreateFunctionInvocationAttemptMutation({ + selection: { fields: { id: true } }, +}); +create({ actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }); +``` + ### FunctionInvocation ```typescript @@ -866,21 +882,6 @@ const { mutate: create } = useCreateNamespaceEventMutation({ create({ actorId: '', databaseId: '', eventType: '', message: '', metadata: '', namespaceId: '' }); ``` -### PlatformDeclaredCapacity - -```typescript -// List all platformDeclaredCapacities -const { data, isLoading } = usePlatformDeclaredCapacitiesQuery({ - selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }, -}); - -// Create a platformDeclaredCapacity -const { mutate: create } = useCreatePlatformDeclaredCapacityMutation({ - selection: { fields: { id: true } }, -}); -create({ cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }); -``` - ### PlatformFunctionApiBinding ```typescript @@ -907,20 +908,20 @@ create({ alias: '', apiId: '', config: '', functionDefinitio ```typescript // List all platformFunctionDefinitions const { data, isLoading } = usePlatformFunctionDefinitionsQuery({ - selection: { fields: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }, + selection: { fields: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }, }); // Get one platformFunctionDefinition const { data: item } = usePlatformFunctionDefinitionQuery({ id: '', - selection: { fields: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }, + selection: { fields: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }, }); // Create a platformFunctionDefinition const { mutate: create } = useCreatePlatformFunctionDefinitionMutation({ selection: { fields: { id: true } }, }); -create({ accessChannels: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }); +create({ accessChannels: '', billable: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }); ``` ### PlatformFunctionDeployment @@ -986,6 +987,27 @@ const { mutate: create } = useCreatePlatformFunctionExecutionLogMutation({ create({ actorId: '', invocationId: '', logLevel: '', message: '', metadata: '', taskIdentifier: '' }); ``` +### PlatformFunctionInvocationAttempt + +```typescript +// List all platformFunctionInvocationAttempts +const { data, isLoading } = usePlatformFunctionInvocationAttemptsQuery({ + selection: { fields: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }, +}); + +// Get one platformFunctionInvocationAttempt +const { data: item } = usePlatformFunctionInvocationAttemptQuery({ + id: '', + selection: { fields: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }, +}); + +// Create a platformFunctionInvocationAttempt +const { mutate: create } = useCreatePlatformFunctionInvocationAttemptMutation({ + selection: { fields: { id: true } }, +}); +create({ actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }); +``` + ### PlatformFunctionInvocation ```typescript @@ -1169,6 +1191,21 @@ const { mutate: create } = useCreatePlatformResourceMutation({ create({ annotations: '', cpuLimitMillicores: '', cpuRequestMillicores: '', createdBy: '', errorCount: '', installationId: '', integrations: '', kind: '', labels: '', lastError: '', lastHeartbeatAt: '', memoryLimitBytes: '', memoryRequestBytes: '', name: '', namespaceId: '', replicas: '', requiredConfigs: '', requiredSecrets: '', resourceDefinitionId: '', slug: '', spec: '', status: '', statusObserved: '', storageClass: '', storageSizeBytes: '', updatedBy: '' }); ``` +### PlatformResourceDeclaredCapacity + +```typescript +// List all platformResourceDeclaredCapacities +const { data, isLoading } = usePlatformResourceDeclaredCapacitiesQuery({ + selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }, +}); + +// Create a platformResourceDeclaredCapacity +const { mutate: create } = useCreatePlatformResourceDeclaredCapacityMutation({ + selection: { fields: { id: true } }, +}); +create({ cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }); +``` + ### PlatformResourceDefinition ```typescript @@ -1295,16 +1332,16 @@ const { mutate: create } = useCreatePlatformResourceUsageSummaryMutation({ create({ date: '', gbSeconds: '', maxCpuMillicores: '', maxMemoryBytes: '', namespaceId: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }); ``` -### PlatformResourceUtilizationDaily +### PlatformResourceUtilization ```typescript -// List all platformResourceUtilizationDailies -const { data, isLoading } = usePlatformResourceUtilizationDailiesQuery({ +// List all platformResourceUtilizations +const { data, isLoading } = usePlatformResourceUtilizationsQuery({ selection: { fields: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }, }); -// Create a platformResourceUtilizationDaily -const { mutate: create } = useCreatePlatformResourceUtilizationDailyMutation({ +// Create a platformResourceUtilization +const { mutate: create } = useCreatePlatformResourceUtilizationMutation({ selection: { fields: { id: true } }, }); create({ avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }); @@ -1424,6 +1461,21 @@ const { mutate: create } = useCreateResourceMutation({ create({ annotations: '', cpuLimitMillicores: '', cpuRequestMillicores: '', createdBy: '', databaseId: '', errorCount: '', installationId: '', integrations: '', kind: '', labels: '', lastError: '', lastHeartbeatAt: '', memoryLimitBytes: '', memoryRequestBytes: '', name: '', namespaceId: '', replicas: '', requiredConfigs: '', requiredSecrets: '', resourceDefinitionId: '', slug: '', spec: '', status: '', statusObserved: '', storageClass: '', storageSizeBytes: '', updatedBy: '' }); ``` +### ResourceDeclaredCapacity + +```typescript +// List all resourceDeclaredCapacities +const { data, isLoading } = useResourceDeclaredCapacitiesQuery({ + selection: { fields: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }, +}); + +// Create a resourceDeclaredCapacity +const { mutate: create } = useCreateResourceDeclaredCapacityMutation({ + selection: { fields: { id: true } }, +}); +create({ cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }); +``` + ### ResourceDefinition ```typescript @@ -1550,16 +1602,16 @@ const { mutate: create } = useCreateResourceUsageSummaryMutation({ create({ databaseId: '', date: '', gbSeconds: '', maxCpuMillicores: '', maxMemoryBytes: '', namespaceId: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }); ``` -### ResourceUtilizationDaily +### ResourceUtilization ```typescript -// List all resourceUtilizationDailies -const { data, isLoading } = useResourceUtilizationDailiesQuery({ +// List all resourceUtilizations +const { data, isLoading } = useResourceUtilizationsQuery({ selection: { fields: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }, }); -// Create a resourceUtilizationDaily -const { mutate: create } = useCreateResourceUtilizationDailyMutation({ +// Create a resourceUtilization +const { mutate: create } = useCreateResourceUtilizationMutation({ selection: { fields: { id: true } }, }); create({ avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }); diff --git a/sdk/constructive-react/src/compute/hooks/index.ts b/sdk/constructive-react/src/compute/hooks/index.ts index 8c100c8d3..325c29688 100644 --- a/sdk/constructive-react/src/compute/hooks/index.ts +++ b/sdk/constructive-react/src/compute/hooks/index.ts @@ -2,7 +2,7 @@ * GraphQL SDK * @generated by @constructive-io/graphql-codegen * - * Tables: DbPreset, DeclaredCapacity, FunctionApiBinding, FunctionDefinition, FunctionDeployment, FunctionDeploymentEvent, FunctionExecutionLog, FunctionGraphCommit, FunctionGraph, FunctionGraphExecution, FunctionGraphExecutionNodeState, FunctionGraphExecutionOutput, FunctionGraphObject, FunctionGraphRef, FunctionGraphStore, FunctionInvocation, GetAllTreeNodesRecord, InfraCommit, InfraGetAllTreeNodesRecord, InfraObject, InfraRef, InfraStore, IntegrationProvider, Namespace, NamespaceEvent, PlatformDeclaredCapacity, PlatformFunctionApiBinding, PlatformFunctionDefinition, PlatformFunctionDeployment, PlatformFunctionDeploymentEvent, PlatformFunctionExecutionLog, PlatformFunctionInvocation, PlatformInfraCommit, PlatformInfraGetAllTreeNodesRecord, PlatformInfraObject, PlatformInfraRef, PlatformInfraStore, PlatformNamespace, PlatformNamespaceEvent, PlatformResource, PlatformResourceDefinition, PlatformResourceEvent, PlatformResourceInstallation, PlatformResourceStatusCheck, PlatformResourceUsageLog, PlatformResourceUsageSummary, PlatformResourceUtilizationDaily, PlatformResourcesHealth, PlatformResourcesRequirementsState, PlatformResourcesResolvedRequirement, PlatformWebhookEndpoint, PlatformWebhookEvent, Resource, ResourceDefinition, ResourceEvent, ResourceInstallation, ResourceStatusCheck, ResourceUsageLog, ResourceUsageSummary, ResourceUtilizationDaily, ResourcesHealth, ResourcesRequirementsState, ResourcesResolvedRequirement, WebhookEndpoint, WebhookEvent + * Tables: DbPreset, FunctionApiBinding, FunctionDefinition, FunctionDeployment, FunctionDeploymentEvent, FunctionExecutionLog, FunctionGraphCommit, FunctionGraph, FunctionGraphExecution, FunctionGraphExecutionNodeState, FunctionGraphExecutionOutput, FunctionGraphObject, FunctionGraphRef, FunctionGraphStore, FunctionInvocationAttempt, FunctionInvocation, GetAllTreeNodesRecord, InfraCommit, InfraGetAllTreeNodesRecord, InfraObject, InfraRef, InfraStore, IntegrationProvider, Namespace, NamespaceEvent, PlatformFunctionApiBinding, PlatformFunctionDefinition, PlatformFunctionDeployment, PlatformFunctionDeploymentEvent, PlatformFunctionExecutionLog, PlatformFunctionInvocationAttempt, PlatformFunctionInvocation, PlatformInfraCommit, PlatformInfraGetAllTreeNodesRecord, PlatformInfraObject, PlatformInfraRef, PlatformInfraStore, PlatformNamespace, PlatformNamespaceEvent, PlatformResource, PlatformResourceDeclaredCapacity, PlatformResourceDefinition, PlatformResourceEvent, PlatformResourceInstallation, PlatformResourceStatusCheck, PlatformResourceUsageLog, PlatformResourceUsageSummary, PlatformResourceUtilization, PlatformResourcesHealth, PlatformResourcesRequirementsState, PlatformResourcesResolvedRequirement, PlatformWebhookEndpoint, PlatformWebhookEvent, Resource, ResourceDeclaredCapacity, ResourceDefinition, ResourceEvent, ResourceInstallation, ResourceStatusCheck, ResourceUsageLog, ResourceUsageSummary, ResourceUtilization, ResourcesHealth, ResourcesRequirementsState, ResourcesResolvedRequirement, WebhookEndpoint, WebhookEvent * * Usage: * diff --git a/sdk/constructive-react/src/compute/hooks/invalidation.ts b/sdk/constructive-react/src/compute/hooks/invalidation.ts index a2dde4674..bbd9940b4 100644 --- a/sdk/constructive-react/src/compute/hooks/invalidation.ts +++ b/sdk/constructive-react/src/compute/hooks/invalidation.ts @@ -16,7 +16,6 @@ import type { QueryClient } from '@tanstack/react-query'; import { dbPresetKeys, - declaredCapacityKeys, functionApiBindingKeys, functionDefinitionKeys, functionDeploymentKeys, @@ -30,6 +29,7 @@ import { functionGraphObjectKeys, functionGraphRefKeys, functionGraphStoreKeys, + functionInvocationAttemptKeys, functionInvocationKeys, getAllTreeNodesRecordKeys, infraCommitKeys, @@ -40,12 +40,12 @@ import { integrationProviderKeys, namespaceKeys, namespaceEventKeys, - platformDeclaredCapacityKeys, platformFunctionApiBindingKeys, platformFunctionDefinitionKeys, platformFunctionDeploymentKeys, platformFunctionDeploymentEventKeys, platformFunctionExecutionLogKeys, + platformFunctionInvocationAttemptKeys, platformFunctionInvocationKeys, platformInfraCommitKeys, platformInfraGetAllTreeNodesRecordKeys, @@ -55,26 +55,28 @@ import { platformNamespaceKeys, platformNamespaceEventKeys, platformResourceKeys, + platformResourceDeclaredCapacityKeys, platformResourceDefinitionKeys, platformResourceEventKeys, platformResourceInstallationKeys, platformResourceStatusCheckKeys, platformResourceUsageLogKeys, platformResourceUsageSummaryKeys, - platformResourceUtilizationDailyKeys, + platformResourceUtilizationKeys, platformResourcesHealthKeys, platformResourcesRequirementsStateKeys, platformResourcesResolvedRequirementKeys, platformWebhookEndpointKeys, platformWebhookEventKeys, resourceKeys, + resourceDeclaredCapacityKeys, resourceDefinitionKeys, resourceEventKeys, resourceInstallationKeys, resourceStatusCheckKeys, resourceUsageLogKeys, resourceUsageSummaryKeys, - resourceUtilizationDailyKeys, + resourceUtilizationKeys, resourcesHealthKeys, resourcesRequirementsStateKeys, resourcesResolvedRequirementKeys, @@ -115,23 +117,6 @@ export const invalidate = { queryKey: dbPresetKeys.detail(id), }), }, - /** Invalidate declaredCapacity queries */ declaredCapacity: { - /** Invalidate all declaredCapacity queries */ all: (queryClient: QueryClient) => - queryClient.invalidateQueries({ - queryKey: declaredCapacityKeys.all, - }), - /** Invalidate declaredCapacity list queries */ lists: (queryClient: QueryClient) => - queryClient.invalidateQueries({ - queryKey: declaredCapacityKeys.lists(), - }), - /** Invalidate a specific declaredCapacity */ detail: ( - queryClient: QueryClient, - id: string | number - ) => - queryClient.invalidateQueries({ - queryKey: declaredCapacityKeys.detail(id), - }), - }, /** Invalidate functionApiBinding queries */ functionApiBinding: { /** Invalidate all functionApiBinding queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -355,6 +340,23 @@ export const invalidate = { queryKey: functionGraphStoreKeys.detail(id), }), }, + /** Invalidate functionInvocationAttempt queries */ functionInvocationAttempt: { + /** Invalidate all functionInvocationAttempt queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: functionInvocationAttemptKeys.all, + }), + /** Invalidate functionInvocationAttempt list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: functionInvocationAttemptKeys.lists(), + }), + /** Invalidate a specific functionInvocationAttempt */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: functionInvocationAttemptKeys.detail(id), + }), + }, /** Invalidate functionInvocation queries */ functionInvocation: { /** Invalidate all functionInvocation queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -522,23 +524,6 @@ export const invalidate = { queryKey: namespaceEventKeys.detail(id), }), }, - /** Invalidate platformDeclaredCapacity queries */ platformDeclaredCapacity: { - /** Invalidate all platformDeclaredCapacity queries */ all: (queryClient: QueryClient) => - queryClient.invalidateQueries({ - queryKey: platformDeclaredCapacityKeys.all, - }), - /** Invalidate platformDeclaredCapacity list queries */ lists: (queryClient: QueryClient) => - queryClient.invalidateQueries({ - queryKey: platformDeclaredCapacityKeys.lists(), - }), - /** Invalidate a specific platformDeclaredCapacity */ detail: ( - queryClient: QueryClient, - id: string | number - ) => - queryClient.invalidateQueries({ - queryKey: platformDeclaredCapacityKeys.detail(id), - }), - }, /** Invalidate platformFunctionApiBinding queries */ platformFunctionApiBinding: { /** Invalidate all platformFunctionApiBinding queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -626,6 +611,27 @@ export const invalidate = { queryKey: platformFunctionExecutionLogKeys.detail(id), }), }, + /** Invalidate platformFunctionInvocationAttempt queries */ platformFunctionInvocationAttempt: { + /** Invalidate all platformFunctionInvocationAttempt queries */ all: ( + queryClient: QueryClient + ) => + queryClient.invalidateQueries({ + queryKey: platformFunctionInvocationAttemptKeys.all, + }), + /** Invalidate platformFunctionInvocationAttempt list queries */ lists: ( + queryClient: QueryClient + ) => + queryClient.invalidateQueries({ + queryKey: platformFunctionInvocationAttemptKeys.lists(), + }), + /** Invalidate a specific platformFunctionInvocationAttempt */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: platformFunctionInvocationAttemptKeys.detail(id), + }), + }, /** Invalidate platformFunctionInvocation queries */ platformFunctionInvocation: { /** Invalidate all platformFunctionInvocation queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -783,6 +789,27 @@ export const invalidate = { queryKey: platformResourceKeys.detail(id), }), }, + /** Invalidate platformResourceDeclaredCapacity queries */ platformResourceDeclaredCapacity: { + /** Invalidate all platformResourceDeclaredCapacity queries */ all: ( + queryClient: QueryClient + ) => + queryClient.invalidateQueries({ + queryKey: platformResourceDeclaredCapacityKeys.all, + }), + /** Invalidate platformResourceDeclaredCapacity list queries */ lists: ( + queryClient: QueryClient + ) => + queryClient.invalidateQueries({ + queryKey: platformResourceDeclaredCapacityKeys.lists(), + }), + /** Invalidate a specific platformResourceDeclaredCapacity */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: platformResourceDeclaredCapacityKeys.detail(id), + }), + }, /** Invalidate platformResourceDefinition queries */ platformResourceDefinition: { /** Invalidate all platformResourceDefinition queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -885,25 +912,21 @@ export const invalidate = { queryKey: platformResourceUsageSummaryKeys.detail(id), }), }, - /** Invalidate platformResourceUtilizationDaily queries */ platformResourceUtilizationDaily: { - /** Invalidate all platformResourceUtilizationDaily queries */ all: ( - queryClient: QueryClient - ) => + /** Invalidate platformResourceUtilization queries */ platformResourceUtilization: { + /** Invalidate all platformResourceUtilization queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ - queryKey: platformResourceUtilizationDailyKeys.all, + queryKey: platformResourceUtilizationKeys.all, }), - /** Invalidate platformResourceUtilizationDaily list queries */ lists: ( - queryClient: QueryClient - ) => + /** Invalidate platformResourceUtilization list queries */ lists: (queryClient: QueryClient) => queryClient.invalidateQueries({ - queryKey: platformResourceUtilizationDailyKeys.lists(), + queryKey: platformResourceUtilizationKeys.lists(), }), - /** Invalidate a specific platformResourceUtilizationDaily */ detail: ( + /** Invalidate a specific platformResourceUtilization */ detail: ( queryClient: QueryClient, id: string | number ) => queryClient.invalidateQueries({ - queryKey: platformResourceUtilizationDailyKeys.detail(id), + queryKey: platformResourceUtilizationKeys.detail(id), }), }, /** Invalidate platformResourcesHealth queries */ platformResourcesHealth: { @@ -1014,6 +1037,23 @@ export const invalidate = { queryKey: resourceKeys.detail(id), }), }, + /** Invalidate resourceDeclaredCapacity queries */ resourceDeclaredCapacity: { + /** Invalidate all resourceDeclaredCapacity queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: resourceDeclaredCapacityKeys.all, + }), + /** Invalidate resourceDeclaredCapacity list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: resourceDeclaredCapacityKeys.lists(), + }), + /** Invalidate a specific resourceDeclaredCapacity */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: resourceDeclaredCapacityKeys.detail(id), + }), + }, /** Invalidate resourceDefinition queries */ resourceDefinition: { /** Invalidate all resourceDefinition queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -1116,21 +1156,21 @@ export const invalidate = { queryKey: resourceUsageSummaryKeys.detail(id), }), }, - /** Invalidate resourceUtilizationDaily queries */ resourceUtilizationDaily: { - /** Invalidate all resourceUtilizationDaily queries */ all: (queryClient: QueryClient) => + /** Invalidate resourceUtilization queries */ resourceUtilization: { + /** Invalidate all resourceUtilization queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ - queryKey: resourceUtilizationDailyKeys.all, + queryKey: resourceUtilizationKeys.all, }), - /** Invalidate resourceUtilizationDaily list queries */ lists: (queryClient: QueryClient) => + /** Invalidate resourceUtilization list queries */ lists: (queryClient: QueryClient) => queryClient.invalidateQueries({ - queryKey: resourceUtilizationDailyKeys.lists(), + queryKey: resourceUtilizationKeys.lists(), }), - /** Invalidate a specific resourceUtilizationDaily */ detail: ( + /** Invalidate a specific resourceUtilization */ detail: ( queryClient: QueryClient, id: string | number ) => queryClient.invalidateQueries({ - queryKey: resourceUtilizationDailyKeys.detail(id), + queryKey: resourceUtilizationKeys.detail(id), }), }, /** Invalidate resourcesHealth queries */ resourcesHealth: { @@ -1236,14 +1276,6 @@ export const remove = { queryKey: dbPresetKeys.detail(id), }); }, - /** Remove declaredCapacity from cache */ declaredCapacity: ( - queryClient: QueryClient, - id: string | number - ) => { - queryClient.removeQueries({ - queryKey: declaredCapacityKeys.detail(id), - }); - }, /** Remove functionApiBinding from cache */ functionApiBinding: ( queryClient: QueryClient, id: string | number @@ -1348,6 +1380,14 @@ export const remove = { queryKey: functionGraphStoreKeys.detail(id), }); }, + /** Remove functionInvocationAttempt from cache */ functionInvocationAttempt: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: functionInvocationAttemptKeys.detail(id), + }); + }, /** Remove functionInvocation from cache */ functionInvocation: ( queryClient: QueryClient, id: string | number @@ -1422,14 +1462,6 @@ export const remove = { queryKey: namespaceEventKeys.detail(id), }); }, - /** Remove platformDeclaredCapacity from cache */ platformDeclaredCapacity: ( - queryClient: QueryClient, - id: string | number - ) => { - queryClient.removeQueries({ - queryKey: platformDeclaredCapacityKeys.detail(id), - }); - }, /** Remove platformFunctionApiBinding from cache */ platformFunctionApiBinding: ( queryClient: QueryClient, id: string | number @@ -1470,6 +1502,14 @@ export const remove = { queryKey: platformFunctionExecutionLogKeys.detail(id), }); }, + /** Remove platformFunctionInvocationAttempt from cache */ platformFunctionInvocationAttempt: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: platformFunctionInvocationAttemptKeys.detail(id), + }); + }, /** Remove platformFunctionInvocation from cache */ platformFunctionInvocation: ( queryClient: QueryClient, id: string | number @@ -1542,6 +1582,14 @@ export const remove = { queryKey: platformResourceKeys.detail(id), }); }, + /** Remove platformResourceDeclaredCapacity from cache */ platformResourceDeclaredCapacity: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: platformResourceDeclaredCapacityKeys.detail(id), + }); + }, /** Remove platformResourceDefinition from cache */ platformResourceDefinition: ( queryClient: QueryClient, id: string | number @@ -1590,12 +1638,12 @@ export const remove = { queryKey: platformResourceUsageSummaryKeys.detail(id), }); }, - /** Remove platformResourceUtilizationDaily from cache */ platformResourceUtilizationDaily: ( + /** Remove platformResourceUtilization from cache */ platformResourceUtilization: ( queryClient: QueryClient, id: string | number ) => { queryClient.removeQueries({ - queryKey: platformResourceUtilizationDailyKeys.detail(id), + queryKey: platformResourceUtilizationKeys.detail(id), }); }, /** Remove platformResourcesHealth from cache */ platformResourcesHealth: ( @@ -1641,6 +1689,14 @@ export const remove = { queryKey: resourceKeys.detail(id), }); }, + /** Remove resourceDeclaredCapacity from cache */ resourceDeclaredCapacity: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: resourceDeclaredCapacityKeys.detail(id), + }); + }, /** Remove resourceDefinition from cache */ resourceDefinition: ( queryClient: QueryClient, id: string | number @@ -1689,12 +1745,12 @@ export const remove = { queryKey: resourceUsageSummaryKeys.detail(id), }); }, - /** Remove resourceUtilizationDaily from cache */ resourceUtilizationDaily: ( + /** Remove resourceUtilization from cache */ resourceUtilization: ( queryClient: QueryClient, id: string | number ) => { queryClient.removeQueries({ - queryKey: resourceUtilizationDailyKeys.detail(id), + queryKey: resourceUtilizationKeys.detail(id), }); }, /** Remove resourcesHealth from cache */ resourcesHealth: ( diff --git a/sdk/constructive-react/src/compute/hooks/mutation-keys.ts b/sdk/constructive-react/src/compute/hooks/mutation-keys.ts index 3c6b2d5cc..4fcd77cc9 100644 --- a/sdk/constructive-react/src/compute/hooks/mutation-keys.ts +++ b/sdk/constructive-react/src/compute/hooks/mutation-keys.ts @@ -26,15 +26,6 @@ export const dbPresetMutationKeys = { /** Delete dbPreset mutation key */ delete: (id: string | number) => ['mutation', 'dbpreset', 'delete', id] as const, } as const; -export const declaredCapacityMutationKeys = { - /** All declaredCapacity mutation keys */ all: ['mutation', 'declaredcapacity'] as const, - /** Create declaredCapacity mutation key */ create: () => - ['mutation', 'declaredcapacity', 'create'] as const, - /** Update declaredCapacity mutation key */ update: (id: string | number) => - ['mutation', 'declaredcapacity', 'update', id] as const, - /** Delete declaredCapacity mutation key */ delete: (id: string | number) => - ['mutation', 'declaredcapacity', 'delete', id] as const, -} as const; export const functionApiBindingMutationKeys = { /** All functionApiBinding mutation keys */ all: ['mutation', 'functionapibinding'] as const, /** Create functionApiBinding mutation key */ create: () => @@ -164,6 +155,18 @@ export const functionGraphStoreMutationKeys = { /** Delete functionGraphStore mutation key */ delete: (id: string | number) => ['mutation', 'functiongraphstore', 'delete', id] as const, } as const; +export const functionInvocationAttemptMutationKeys = { + /** All functionInvocationAttempt mutation keys */ all: [ + 'mutation', + 'functioninvocationattempt', + ] as const, + /** Create functionInvocationAttempt mutation key */ create: () => + ['mutation', 'functioninvocationattempt', 'create'] as const, + /** Update functionInvocationAttempt mutation key */ update: (id: string | number) => + ['mutation', 'functioninvocationattempt', 'update', id] as const, + /** Delete functionInvocationAttempt mutation key */ delete: (id: string | number) => + ['mutation', 'functioninvocationattempt', 'delete', id] as const, +} as const; export const functionInvocationMutationKeys = { /** All functionInvocation mutation keys */ all: ['mutation', 'functioninvocation'] as const, /** Create functionInvocation mutation key */ create: () => @@ -257,18 +260,6 @@ export const namespaceEventMutationKeys = { /** Delete namespaceEvent mutation key */ delete: (id: string | number) => ['mutation', 'namespaceevent', 'delete', id] as const, } as const; -export const platformDeclaredCapacityMutationKeys = { - /** All platformDeclaredCapacity mutation keys */ all: [ - 'mutation', - 'platformdeclaredcapacity', - ] as const, - /** Create platformDeclaredCapacity mutation key */ create: () => - ['mutation', 'platformdeclaredcapacity', 'create'] as const, - /** Update platformDeclaredCapacity mutation key */ update: (id: string | number) => - ['mutation', 'platformdeclaredcapacity', 'update', id] as const, - /** Delete platformDeclaredCapacity mutation key */ delete: (id: string | number) => - ['mutation', 'platformdeclaredcapacity', 'delete', id] as const, -} as const; export const platformFunctionApiBindingMutationKeys = { /** All platformFunctionApiBinding mutation keys */ all: [ 'mutation', @@ -329,6 +320,18 @@ export const platformFunctionExecutionLogMutationKeys = { /** Delete platformFunctionExecutionLog mutation key */ delete: (id: string | number) => ['mutation', 'platformfunctionexecutionlog', 'delete', id] as const, } as const; +export const platformFunctionInvocationAttemptMutationKeys = { + /** All platformFunctionInvocationAttempt mutation keys */ all: [ + 'mutation', + 'platformfunctioninvocationattempt', + ] as const, + /** Create platformFunctionInvocationAttempt mutation key */ create: () => + ['mutation', 'platformfunctioninvocationattempt', 'create'] as const, + /** Update platformFunctionInvocationAttempt mutation key */ update: (id: string | number) => + ['mutation', 'platformfunctioninvocationattempt', 'update', id] as const, + /** Delete platformFunctionInvocationAttempt mutation key */ delete: (id: string | number) => + ['mutation', 'platformfunctioninvocationattempt', 'delete', id] as const, +} as const; export const platformFunctionInvocationMutationKeys = { /** All platformFunctionInvocation mutation keys */ all: [ 'mutation', @@ -419,6 +422,18 @@ export const platformResourceMutationKeys = { /** Delete platformResource mutation key */ delete: (id: string | number) => ['mutation', 'platformresource', 'delete', id] as const, } as const; +export const platformResourceDeclaredCapacityMutationKeys = { + /** All platformResourceDeclaredCapacity mutation keys */ all: [ + 'mutation', + 'platformresourcedeclaredcapacity', + ] as const, + /** Create platformResourceDeclaredCapacity mutation key */ create: () => + ['mutation', 'platformresourcedeclaredcapacity', 'create'] as const, + /** Update platformResourceDeclaredCapacity mutation key */ update: (id: string | number) => + ['mutation', 'platformresourcedeclaredcapacity', 'update', id] as const, + /** Delete platformResourceDeclaredCapacity mutation key */ delete: (id: string | number) => + ['mutation', 'platformresourcedeclaredcapacity', 'delete', id] as const, +} as const; export const platformResourceDefinitionMutationKeys = { /** All platformResourceDefinition mutation keys */ all: [ 'mutation', @@ -491,17 +506,17 @@ export const platformResourceUsageSummaryMutationKeys = { /** Delete platformResourceUsageSummary mutation key */ delete: (id: string | number) => ['mutation', 'platformresourceusagesummary', 'delete', id] as const, } as const; -export const platformResourceUtilizationDailyMutationKeys = { - /** All platformResourceUtilizationDaily mutation keys */ all: [ +export const platformResourceUtilizationMutationKeys = { + /** All platformResourceUtilization mutation keys */ all: [ 'mutation', - 'platformresourceutilizationdaily', + 'platformresourceutilization', ] as const, - /** Create platformResourceUtilizationDaily mutation key */ create: () => - ['mutation', 'platformresourceutilizationdaily', 'create'] as const, - /** Update platformResourceUtilizationDaily mutation key */ update: (id: string | number) => - ['mutation', 'platformresourceutilizationdaily', 'update', id] as const, - /** Delete platformResourceUtilizationDaily mutation key */ delete: (id: string | number) => - ['mutation', 'platformresourceutilizationdaily', 'delete', id] as const, + /** Create platformResourceUtilization mutation key */ create: () => + ['mutation', 'platformresourceutilization', 'create'] as const, + /** Update platformResourceUtilization mutation key */ update: (id: string | number) => + ['mutation', 'platformresourceutilization', 'update', id] as const, + /** Delete platformResourceUtilization mutation key */ delete: (id: string | number) => + ['mutation', 'platformresourceutilization', 'delete', id] as const, } as const; export const platformResourcesHealthMutationKeys = { /** All platformResourcesHealth mutation keys */ all: [ @@ -568,6 +583,18 @@ export const resourceMutationKeys = { /** Delete resource mutation key */ delete: (id: string | number) => ['mutation', 'resource', 'delete', id] as const, } as const; +export const resourceDeclaredCapacityMutationKeys = { + /** All resourceDeclaredCapacity mutation keys */ all: [ + 'mutation', + 'resourcedeclaredcapacity', + ] as const, + /** Create resourceDeclaredCapacity mutation key */ create: () => + ['mutation', 'resourcedeclaredcapacity', 'create'] as const, + /** Update resourceDeclaredCapacity mutation key */ update: (id: string | number) => + ['mutation', 'resourcedeclaredcapacity', 'update', id] as const, + /** Delete resourceDeclaredCapacity mutation key */ delete: (id: string | number) => + ['mutation', 'resourcedeclaredcapacity', 'delete', id] as const, +} as const; export const resourceDefinitionMutationKeys = { /** All resourceDefinition mutation keys */ all: ['mutation', 'resourcedefinition'] as const, /** Create resourceDefinition mutation key */ create: () => @@ -622,17 +649,14 @@ export const resourceUsageSummaryMutationKeys = { /** Delete resourceUsageSummary mutation key */ delete: (id: string | number) => ['mutation', 'resourceusagesummary', 'delete', id] as const, } as const; -export const resourceUtilizationDailyMutationKeys = { - /** All resourceUtilizationDaily mutation keys */ all: [ - 'mutation', - 'resourceutilizationdaily', - ] as const, - /** Create resourceUtilizationDaily mutation key */ create: () => - ['mutation', 'resourceutilizationdaily', 'create'] as const, - /** Update resourceUtilizationDaily mutation key */ update: (id: string | number) => - ['mutation', 'resourceutilizationdaily', 'update', id] as const, - /** Delete resourceUtilizationDaily mutation key */ delete: (id: string | number) => - ['mutation', 'resourceutilizationdaily', 'delete', id] as const, +export const resourceUtilizationMutationKeys = { + /** All resourceUtilization mutation keys */ all: ['mutation', 'resourceutilization'] as const, + /** Create resourceUtilization mutation key */ create: () => + ['mutation', 'resourceutilization', 'create'] as const, + /** Update resourceUtilization mutation key */ update: (id: string | number) => + ['mutation', 'resourceutilization', 'update', id] as const, + /** Delete resourceUtilization mutation key */ delete: (id: string | number) => + ['mutation', 'resourceutilization', 'delete', id] as const, } as const; export const resourcesHealthMutationKeys = { /** All resourcesHealth mutation keys */ all: ['mutation', 'resourceshealth'] as const, @@ -846,7 +870,6 @@ export const customMutationKeys = { */ export const mutationKeys = { dbPreset: dbPresetMutationKeys, - declaredCapacity: declaredCapacityMutationKeys, functionApiBinding: functionApiBindingMutationKeys, functionDefinition: functionDefinitionMutationKeys, functionDeployment: functionDeploymentMutationKeys, @@ -860,6 +883,7 @@ export const mutationKeys = { functionGraphObject: functionGraphObjectMutationKeys, functionGraphRef: functionGraphRefMutationKeys, functionGraphStore: functionGraphStoreMutationKeys, + functionInvocationAttempt: functionInvocationAttemptMutationKeys, functionInvocation: functionInvocationMutationKeys, getAllTreeNodesRecord: getAllTreeNodesRecordMutationKeys, infraCommit: infraCommitMutationKeys, @@ -870,12 +894,12 @@ export const mutationKeys = { integrationProvider: integrationProviderMutationKeys, namespace: namespaceMutationKeys, namespaceEvent: namespaceEventMutationKeys, - platformDeclaredCapacity: platformDeclaredCapacityMutationKeys, platformFunctionApiBinding: platformFunctionApiBindingMutationKeys, platformFunctionDefinition: platformFunctionDefinitionMutationKeys, platformFunctionDeployment: platformFunctionDeploymentMutationKeys, platformFunctionDeploymentEvent: platformFunctionDeploymentEventMutationKeys, platformFunctionExecutionLog: platformFunctionExecutionLogMutationKeys, + platformFunctionInvocationAttempt: platformFunctionInvocationAttemptMutationKeys, platformFunctionInvocation: platformFunctionInvocationMutationKeys, platformInfraCommit: platformInfraCommitMutationKeys, platformInfraGetAllTreeNodesRecord: platformInfraGetAllTreeNodesRecordMutationKeys, @@ -885,26 +909,28 @@ export const mutationKeys = { platformNamespace: platformNamespaceMutationKeys, platformNamespaceEvent: platformNamespaceEventMutationKeys, platformResource: platformResourceMutationKeys, + platformResourceDeclaredCapacity: platformResourceDeclaredCapacityMutationKeys, platformResourceDefinition: platformResourceDefinitionMutationKeys, platformResourceEvent: platformResourceEventMutationKeys, platformResourceInstallation: platformResourceInstallationMutationKeys, platformResourceStatusCheck: platformResourceStatusCheckMutationKeys, platformResourceUsageLog: platformResourceUsageLogMutationKeys, platformResourceUsageSummary: platformResourceUsageSummaryMutationKeys, - platformResourceUtilizationDaily: platformResourceUtilizationDailyMutationKeys, + platformResourceUtilization: platformResourceUtilizationMutationKeys, platformResourcesHealth: platformResourcesHealthMutationKeys, platformResourcesRequirementsState: platformResourcesRequirementsStateMutationKeys, platformResourcesResolvedRequirement: platformResourcesResolvedRequirementMutationKeys, platformWebhookEndpoint: platformWebhookEndpointMutationKeys, platformWebhookEvent: platformWebhookEventMutationKeys, resource: resourceMutationKeys, + resourceDeclaredCapacity: resourceDeclaredCapacityMutationKeys, resourceDefinition: resourceDefinitionMutationKeys, resourceEvent: resourceEventMutationKeys, resourceInstallation: resourceInstallationMutationKeys, resourceStatusCheck: resourceStatusCheckMutationKeys, resourceUsageLog: resourceUsageLogMutationKeys, resourceUsageSummary: resourceUsageSummaryMutationKeys, - resourceUtilizationDaily: resourceUtilizationDailyMutationKeys, + resourceUtilization: resourceUtilizationMutationKeys, resourcesHealth: resourcesHealthMutationKeys, resourcesRequirementsState: resourcesRequirementsStateMutationKeys, resourcesResolvedRequirement: resourcesResolvedRequirementMutationKeys, diff --git a/sdk/constructive-react/src/compute/hooks/mutations/index.ts b/sdk/constructive-react/src/compute/hooks/mutations/index.ts index 90244d650..206dbbb82 100644 --- a/sdk/constructive-react/src/compute/hooks/mutations/index.ts +++ b/sdk/constructive-react/src/compute/hooks/mutations/index.ts @@ -6,7 +6,6 @@ export * from './useCreateDbPresetMutation'; export * from './useUpdateDbPresetMutation'; export * from './useDeleteDbPresetMutation'; -export * from './useCreateDeclaredCapacityMutation'; export * from './useCreateFunctionApiBindingMutation'; export * from './useUpdateFunctionApiBindingMutation'; export * from './useDeleteFunctionApiBindingMutation'; @@ -46,6 +45,9 @@ export * from './useDeleteFunctionGraphRefMutation'; export * from './useCreateFunctionGraphStoreMutation'; export * from './useUpdateFunctionGraphStoreMutation'; export * from './useDeleteFunctionGraphStoreMutation'; +export * from './useCreateFunctionInvocationAttemptMutation'; +export * from './useUpdateFunctionInvocationAttemptMutation'; +export * from './useDeleteFunctionInvocationAttemptMutation'; export * from './useCreateFunctionInvocationMutation'; export * from './useUpdateFunctionInvocationMutation'; export * from './useDeleteFunctionInvocationMutation'; @@ -72,7 +74,6 @@ export * from './useDeleteNamespaceMutation'; export * from './useCreateNamespaceEventMutation'; export * from './useUpdateNamespaceEventMutation'; export * from './useDeleteNamespaceEventMutation'; -export * from './useCreatePlatformDeclaredCapacityMutation'; export * from './useCreatePlatformFunctionApiBindingMutation'; export * from './useUpdatePlatformFunctionApiBindingMutation'; export * from './useDeletePlatformFunctionApiBindingMutation'; @@ -88,6 +89,9 @@ export * from './useDeletePlatformFunctionDeploymentEventMutation'; export * from './useCreatePlatformFunctionExecutionLogMutation'; export * from './useUpdatePlatformFunctionExecutionLogMutation'; export * from './useDeletePlatformFunctionExecutionLogMutation'; +export * from './useCreatePlatformFunctionInvocationAttemptMutation'; +export * from './useUpdatePlatformFunctionInvocationAttemptMutation'; +export * from './useDeletePlatformFunctionInvocationAttemptMutation'; export * from './useCreatePlatformFunctionInvocationMutation'; export * from './useUpdatePlatformFunctionInvocationMutation'; export * from './useDeletePlatformFunctionInvocationMutation'; @@ -113,6 +117,7 @@ export * from './useDeletePlatformNamespaceEventMutation'; export * from './useCreatePlatformResourceMutation'; export * from './useUpdatePlatformResourceMutation'; export * from './useDeletePlatformResourceMutation'; +export * from './useCreatePlatformResourceDeclaredCapacityMutation'; export * from './useCreatePlatformResourceDefinitionMutation'; export * from './useUpdatePlatformResourceDefinitionMutation'; export * from './useDeletePlatformResourceDefinitionMutation'; @@ -131,7 +136,7 @@ export * from './useDeletePlatformResourceUsageLogMutation'; export * from './useCreatePlatformResourceUsageSummaryMutation'; export * from './useUpdatePlatformResourceUsageSummaryMutation'; export * from './useDeletePlatformResourceUsageSummaryMutation'; -export * from './useCreatePlatformResourceUtilizationDailyMutation'; +export * from './useCreatePlatformResourceUtilizationMutation'; export * from './useCreatePlatformResourcesHealthMutation'; export * from './useCreatePlatformResourcesRequirementsStateMutation'; export * from './useCreatePlatformResourcesResolvedRequirementMutation'; @@ -144,6 +149,7 @@ export * from './useDeletePlatformWebhookEventMutation'; export * from './useCreateResourceMutation'; export * from './useUpdateResourceMutation'; export * from './useDeleteResourceMutation'; +export * from './useCreateResourceDeclaredCapacityMutation'; export * from './useCreateResourceDefinitionMutation'; export * from './useUpdateResourceDefinitionMutation'; export * from './useDeleteResourceDefinitionMutation'; @@ -162,7 +168,7 @@ export * from './useDeleteResourceUsageLogMutation'; export * from './useCreateResourceUsageSummaryMutation'; export * from './useUpdateResourceUsageSummaryMutation'; export * from './useDeleteResourceUsageSummaryMutation'; -export * from './useCreateResourceUtilizationDailyMutation'; +export * from './useCreateResourceUtilizationMutation'; export * from './useCreateResourcesHealthMutation'; export * from './useCreateResourcesRequirementsStateMutation'; export * from './useCreateResourcesResolvedRequirementMutation'; diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreateDeclaredCapacityMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreateDeclaredCapacityMutation.ts deleted file mode 100644 index 3ada2ee36..000000000 --- a/sdk/constructive-react/src/compute/hooks/mutations/useCreateDeclaredCapacityMutation.ts +++ /dev/null @@ -1,91 +0,0 @@ -/** - * Create mutation hook for DeclaredCapacity - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useMutation, useQueryClient } from '@tanstack/react-query'; -import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildSelectionArgs } from '../selection'; -import type { SelectionConfig } from '../selection'; -import { declaredCapacityKeys } from '../query-keys'; -import { declaredCapacityMutationKeys } from '../mutation-keys'; -import type { - DeclaredCapacitySelect, - DeclaredCapacityWithRelations, - CreateDeclaredCapacityInput, -} from '../../orm/input-types'; -import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; -export type { - DeclaredCapacitySelect, - DeclaredCapacityWithRelations, - CreateDeclaredCapacityInput, -} from '../../orm/input-types'; -/** - * Mutation hook for creating a DeclaredCapacity - * - * @example - * ```tsx - * const { mutate, isPending } = useCreateDeclaredCapacityMutation({ - * selection: { fields: { id: true, name: true } }, - * }); - * - * mutate({ name: 'New item' }); - * ``` - */ -export function useCreateDeclaredCapacityMutation( - params: { - selection: { - fields: S & DeclaredCapacitySelect; - } & HookStrictSelect, DeclaredCapacitySelect>; - } & Omit< - UseMutationOptions< - { - createDeclaredCapacity: { - declaredCapacity: InferSelectResult; - }; - }, - Error, - CreateDeclaredCapacityInput['declaredCapacity'] - >, - 'mutationFn' - > -): UseMutationResult< - { - createDeclaredCapacity: { - declaredCapacity: InferSelectResult; - }; - }, - Error, - CreateDeclaredCapacityInput['declaredCapacity'] ->; -export function useCreateDeclaredCapacityMutation( - params: { - selection: SelectionConfig; - } & Omit< - UseMutationOptions, - 'mutationFn' - > -) { - const args = buildSelectionArgs(params.selection); - const { selection: _selection, ...mutationOptions } = params ?? {}; - void _selection; - const queryClient = useQueryClient(); - return useMutation({ - mutationKey: declaredCapacityMutationKeys.create(), - mutationFn: (data: CreateDeclaredCapacityInput['declaredCapacity']) => - getClient() - .declaredCapacity.create({ - data, - select: args.select, - }) - .unwrap(), - onSuccess: () => { - queryClient.invalidateQueries({ - queryKey: declaredCapacityKeys.lists(), - }); - }, - ...mutationOptions, - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreateFunctionInvocationAttemptMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreateFunctionInvocationAttemptMutation.ts new file mode 100644 index 000000000..b7fa2222f --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreateFunctionInvocationAttemptMutation.ts @@ -0,0 +1,97 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { functionInvocationAttemptKeys } from '../query-keys'; +import { functionInvocationAttemptMutationKeys } from '../mutation-keys'; +import type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, + CreateFunctionInvocationAttemptInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, + CreateFunctionInvocationAttemptInput, +} from '../../orm/input-types'; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateFunctionInvocationAttemptMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateFunctionInvocationAttemptMutation< + S extends FunctionInvocationAttemptSelect, +>( + params: { + selection: { + fields: S & FunctionInvocationAttemptSelect; + } & HookStrictSelect, FunctionInvocationAttemptSelect>; + } & Omit< + UseMutationOptions< + { + createFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }, + Error, + CreateFunctionInvocationAttemptInput['functionInvocationAttempt'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }, + Error, + CreateFunctionInvocationAttemptInput['functionInvocationAttempt'] +>; +export function useCreateFunctionInvocationAttemptMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + CreateFunctionInvocationAttemptInput['functionInvocationAttempt'] + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: functionInvocationAttemptMutationKeys.create(), + mutationFn: (data: CreateFunctionInvocationAttemptInput['functionInvocationAttempt']) => + getClient() + .functionInvocationAttempt.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: functionInvocationAttemptKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformDeclaredCapacityMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformDeclaredCapacityMutation.ts deleted file mode 100644 index 8064dd4bf..000000000 --- a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformDeclaredCapacityMutation.ts +++ /dev/null @@ -1,91 +0,0 @@ -/** - * Create mutation hook for PlatformDeclaredCapacity - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useMutation, useQueryClient } from '@tanstack/react-query'; -import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildSelectionArgs } from '../selection'; -import type { SelectionConfig } from '../selection'; -import { platformDeclaredCapacityKeys } from '../query-keys'; -import { platformDeclaredCapacityMutationKeys } from '../mutation-keys'; -import type { - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityWithRelations, - CreatePlatformDeclaredCapacityInput, -} from '../../orm/input-types'; -import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; -export type { - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityWithRelations, - CreatePlatformDeclaredCapacityInput, -} from '../../orm/input-types'; -/** - * Mutation hook for creating a PlatformDeclaredCapacity - * - * @example - * ```tsx - * const { mutate, isPending } = useCreatePlatformDeclaredCapacityMutation({ - * selection: { fields: { id: true, name: true } }, - * }); - * - * mutate({ name: 'New item' }); - * ``` - */ -export function useCreatePlatformDeclaredCapacityMutation( - params: { - selection: { - fields: S & PlatformDeclaredCapacitySelect; - } & HookStrictSelect, PlatformDeclaredCapacitySelect>; - } & Omit< - UseMutationOptions< - { - createPlatformDeclaredCapacity: { - platformDeclaredCapacity: InferSelectResult; - }; - }, - Error, - CreatePlatformDeclaredCapacityInput['platformDeclaredCapacity'] - >, - 'mutationFn' - > -): UseMutationResult< - { - createPlatformDeclaredCapacity: { - platformDeclaredCapacity: InferSelectResult; - }; - }, - Error, - CreatePlatformDeclaredCapacityInput['platformDeclaredCapacity'] ->; -export function useCreatePlatformDeclaredCapacityMutation( - params: { - selection: SelectionConfig; - } & Omit< - UseMutationOptions, - 'mutationFn' - > -) { - const args = buildSelectionArgs(params.selection); - const { selection: _selection, ...mutationOptions } = params ?? {}; - void _selection; - const queryClient = useQueryClient(); - return useMutation({ - mutationKey: platformDeclaredCapacityMutationKeys.create(), - mutationFn: (data: CreatePlatformDeclaredCapacityInput['platformDeclaredCapacity']) => - getClient() - .platformDeclaredCapacity.create({ - data, - select: args.select, - }) - .unwrap(), - onSuccess: () => { - queryClient.invalidateQueries({ - queryKey: platformDeclaredCapacityKeys.lists(), - }); - }, - ...mutationOptions, - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformFunctionInvocationAttemptMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformFunctionInvocationAttemptMutation.ts new file mode 100644 index 000000000..652e64ae7 --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformFunctionInvocationAttemptMutation.ts @@ -0,0 +1,105 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { platformFunctionInvocationAttemptKeys } from '../query-keys'; +import { platformFunctionInvocationAttemptMutationKeys } from '../mutation-keys'; +import type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, + CreatePlatformFunctionInvocationAttemptInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, + CreatePlatformFunctionInvocationAttemptInput, +} from '../../orm/input-types'; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { mutate, isPending } = useCreatePlatformFunctionInvocationAttemptMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreatePlatformFunctionInvocationAttemptMutation< + S extends PlatformFunctionInvocationAttemptSelect, +>( + params: { + selection: { + fields: S & PlatformFunctionInvocationAttemptSelect; + } & HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; + } & Omit< + UseMutationOptions< + { + createPlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }, + Error, + CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createPlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }, + Error, + CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt'] +>; +export function useCreatePlatformFunctionInvocationAttemptMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt'] + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: platformFunctionInvocationAttemptMutationKeys.create(), + mutationFn: ( + data: CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt'] + ) => + getClient() + .platformFunctionInvocationAttempt.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: platformFunctionInvocationAttemptKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceDeclaredCapacityMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceDeclaredCapacityMutation.ts new file mode 100644 index 000000000..020666b1c --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceDeclaredCapacityMutation.ts @@ -0,0 +1,105 @@ +/** + * Create mutation hook for PlatformResourceDeclaredCapacity + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { platformResourceDeclaredCapacityKeys } from '../query-keys'; +import { platformResourceDeclaredCapacityMutationKeys } from '../mutation-keys'; +import type { + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityWithRelations, + CreatePlatformResourceDeclaredCapacityInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityWithRelations, + CreatePlatformResourceDeclaredCapacityInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a PlatformResourceDeclaredCapacity + * + * @example + * ```tsx + * const { mutate, isPending } = useCreatePlatformResourceDeclaredCapacityMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreatePlatformResourceDeclaredCapacityMutation< + S extends PlatformResourceDeclaredCapacitySelect, +>( + params: { + selection: { + fields: S & PlatformResourceDeclaredCapacitySelect; + } & HookStrictSelect, PlatformResourceDeclaredCapacitySelect>; + } & Omit< + UseMutationOptions< + { + createPlatformResourceDeclaredCapacity: { + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + >; + }; + }, + Error, + CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createPlatformResourceDeclaredCapacity: { + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + >; + }; + }, + Error, + CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity'] +>; +export function useCreatePlatformResourceDeclaredCapacityMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity'] + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: platformResourceDeclaredCapacityMutationKeys.create(), + mutationFn: ( + data: CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity'] + ) => + getClient() + .platformResourceDeclaredCapacity.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: platformResourceDeclaredCapacityKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUsageLogMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUsageLogMutation.ts index 39b1d7ed8..bb7884318 100644 --- a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUsageLogMutation.ts +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUsageLogMutation.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -23,7 +23,7 @@ export type { CreatePlatformResourceUsageLogInput, } from '../../orm/input-types'; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationDailyMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationDailyMutation.ts deleted file mode 100644 index 906c834b1..000000000 --- a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationDailyMutation.ts +++ /dev/null @@ -1,105 +0,0 @@ -/** - * Create mutation hook for PlatformResourceUtilizationDaily - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useMutation, useQueryClient } from '@tanstack/react-query'; -import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildSelectionArgs } from '../selection'; -import type { SelectionConfig } from '../selection'; -import { platformResourceUtilizationDailyKeys } from '../query-keys'; -import { platformResourceUtilizationDailyMutationKeys } from '../mutation-keys'; -import type { - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyWithRelations, - CreatePlatformResourceUtilizationDailyInput, -} from '../../orm/input-types'; -import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; -export type { - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyWithRelations, - CreatePlatformResourceUtilizationDailyInput, -} from '../../orm/input-types'; -/** - * Mutation hook for creating a PlatformResourceUtilizationDaily - * - * @example - * ```tsx - * const { mutate, isPending } = useCreatePlatformResourceUtilizationDailyMutation({ - * selection: { fields: { id: true, name: true } }, - * }); - * - * mutate({ name: 'New item' }); - * ``` - */ -export function useCreatePlatformResourceUtilizationDailyMutation< - S extends PlatformResourceUtilizationDailySelect, ->( - params: { - selection: { - fields: S & PlatformResourceUtilizationDailySelect; - } & HookStrictSelect, PlatformResourceUtilizationDailySelect>; - } & Omit< - UseMutationOptions< - { - createPlatformResourceUtilizationDaily: { - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - >; - }; - }, - Error, - CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily'] - >, - 'mutationFn' - > -): UseMutationResult< - { - createPlatformResourceUtilizationDaily: { - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - >; - }; - }, - Error, - CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily'] ->; -export function useCreatePlatformResourceUtilizationDailyMutation( - params: { - selection: SelectionConfig; - } & Omit< - UseMutationOptions< - any, - Error, - CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily'] - >, - 'mutationFn' - > -) { - const args = buildSelectionArgs(params.selection); - const { selection: _selection, ...mutationOptions } = params ?? {}; - void _selection; - const queryClient = useQueryClient(); - return useMutation({ - mutationKey: platformResourceUtilizationDailyMutationKeys.create(), - mutationFn: ( - data: CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily'] - ) => - getClient() - .platformResourceUtilizationDaily.create({ - data, - select: args.select, - }) - .unwrap(), - onSuccess: () => { - queryClient.invalidateQueries({ - queryKey: platformResourceUtilizationDailyKeys.lists(), - }); - }, - ...mutationOptions, - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationMutation.ts new file mode 100644 index 000000000..c29fc2a56 --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreatePlatformResourceUtilizationMutation.ts @@ -0,0 +1,100 @@ +/** + * Create mutation hook for PlatformResourceUtilization + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { platformResourceUtilizationKeys } from '../query-keys'; +import { platformResourceUtilizationMutationKeys } from '../mutation-keys'; +import type { + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationWithRelations, + CreatePlatformResourceUtilizationInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationWithRelations, + CreatePlatformResourceUtilizationInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a PlatformResourceUtilization + * + * @example + * ```tsx + * const { mutate, isPending } = useCreatePlatformResourceUtilizationMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreatePlatformResourceUtilizationMutation< + S extends PlatformResourceUtilizationSelect, +>( + params: { + selection: { + fields: S & PlatformResourceUtilizationSelect; + } & HookStrictSelect, PlatformResourceUtilizationSelect>; + } & Omit< + UseMutationOptions< + { + createPlatformResourceUtilization: { + platformResourceUtilization: InferSelectResult< + PlatformResourceUtilizationWithRelations, + S + >; + }; + }, + Error, + CreatePlatformResourceUtilizationInput['platformResourceUtilization'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createPlatformResourceUtilization: { + platformResourceUtilization: InferSelectResult; + }; + }, + Error, + CreatePlatformResourceUtilizationInput['platformResourceUtilization'] +>; +export function useCreatePlatformResourceUtilizationMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + CreatePlatformResourceUtilizationInput['platformResourceUtilization'] + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: platformResourceUtilizationMutationKeys.create(), + mutationFn: (data: CreatePlatformResourceUtilizationInput['platformResourceUtilization']) => + getClient() + .platformResourceUtilization.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: platformResourceUtilizationKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceDeclaredCapacityMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceDeclaredCapacityMutation.ts new file mode 100644 index 000000000..ccb4c7b2c --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceDeclaredCapacityMutation.ts @@ -0,0 +1,91 @@ +/** + * Create mutation hook for ResourceDeclaredCapacity + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { resourceDeclaredCapacityKeys } from '../query-keys'; +import { resourceDeclaredCapacityMutationKeys } from '../mutation-keys'; +import type { + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityWithRelations, + CreateResourceDeclaredCapacityInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityWithRelations, + CreateResourceDeclaredCapacityInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a ResourceDeclaredCapacity + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateResourceDeclaredCapacityMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateResourceDeclaredCapacityMutation( + params: { + selection: { + fields: S & ResourceDeclaredCapacitySelect; + } & HookStrictSelect, ResourceDeclaredCapacitySelect>; + } & Omit< + UseMutationOptions< + { + createResourceDeclaredCapacity: { + resourceDeclaredCapacity: InferSelectResult; + }; + }, + Error, + CreateResourceDeclaredCapacityInput['resourceDeclaredCapacity'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createResourceDeclaredCapacity: { + resourceDeclaredCapacity: InferSelectResult; + }; + }, + Error, + CreateResourceDeclaredCapacityInput['resourceDeclaredCapacity'] +>; +export function useCreateResourceDeclaredCapacityMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: resourceDeclaredCapacityMutationKeys.create(), + mutationFn: (data: CreateResourceDeclaredCapacityInput['resourceDeclaredCapacity']) => + getClient() + .resourceDeclaredCapacity.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: resourceDeclaredCapacityKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUsageLogMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUsageLogMutation.ts index e1b48b73e..cb6d12ff7 100644 --- a/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUsageLogMutation.ts +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUsageLogMutation.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -23,7 +23,7 @@ export type { CreateResourceUsageLogInput, } from '../../orm/input-types'; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationDailyMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationDailyMutation.ts deleted file mode 100644 index a88343161..000000000 --- a/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationDailyMutation.ts +++ /dev/null @@ -1,91 +0,0 @@ -/** - * Create mutation hook for ResourceUtilizationDaily - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useMutation, useQueryClient } from '@tanstack/react-query'; -import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildSelectionArgs } from '../selection'; -import type { SelectionConfig } from '../selection'; -import { resourceUtilizationDailyKeys } from '../query-keys'; -import { resourceUtilizationDailyMutationKeys } from '../mutation-keys'; -import type { - ResourceUtilizationDailySelect, - ResourceUtilizationDailyWithRelations, - CreateResourceUtilizationDailyInput, -} from '../../orm/input-types'; -import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; -export type { - ResourceUtilizationDailySelect, - ResourceUtilizationDailyWithRelations, - CreateResourceUtilizationDailyInput, -} from '../../orm/input-types'; -/** - * Mutation hook for creating a ResourceUtilizationDaily - * - * @example - * ```tsx - * const { mutate, isPending } = useCreateResourceUtilizationDailyMutation({ - * selection: { fields: { id: true, name: true } }, - * }); - * - * mutate({ name: 'New item' }); - * ``` - */ -export function useCreateResourceUtilizationDailyMutation( - params: { - selection: { - fields: S & ResourceUtilizationDailySelect; - } & HookStrictSelect, ResourceUtilizationDailySelect>; - } & Omit< - UseMutationOptions< - { - createResourceUtilizationDaily: { - resourceUtilizationDaily: InferSelectResult; - }; - }, - Error, - CreateResourceUtilizationDailyInput['resourceUtilizationDaily'] - >, - 'mutationFn' - > -): UseMutationResult< - { - createResourceUtilizationDaily: { - resourceUtilizationDaily: InferSelectResult; - }; - }, - Error, - CreateResourceUtilizationDailyInput['resourceUtilizationDaily'] ->; -export function useCreateResourceUtilizationDailyMutation( - params: { - selection: SelectionConfig; - } & Omit< - UseMutationOptions, - 'mutationFn' - > -) { - const args = buildSelectionArgs(params.selection); - const { selection: _selection, ...mutationOptions } = params ?? {}; - void _selection; - const queryClient = useQueryClient(); - return useMutation({ - mutationKey: resourceUtilizationDailyMutationKeys.create(), - mutationFn: (data: CreateResourceUtilizationDailyInput['resourceUtilizationDaily']) => - getClient() - .resourceUtilizationDaily.create({ - data, - select: args.select, - }) - .unwrap(), - onSuccess: () => { - queryClient.invalidateQueries({ - queryKey: resourceUtilizationDailyKeys.lists(), - }); - }, - ...mutationOptions, - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationMutation.ts new file mode 100644 index 000000000..05250fd17 --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useCreateResourceUtilizationMutation.ts @@ -0,0 +1,91 @@ +/** + * Create mutation hook for ResourceUtilization + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { resourceUtilizationKeys } from '../query-keys'; +import { resourceUtilizationMutationKeys } from '../mutation-keys'; +import type { + ResourceUtilizationSelect, + ResourceUtilizationWithRelations, + CreateResourceUtilizationInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + ResourceUtilizationSelect, + ResourceUtilizationWithRelations, + CreateResourceUtilizationInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a ResourceUtilization + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateResourceUtilizationMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateResourceUtilizationMutation( + params: { + selection: { + fields: S & ResourceUtilizationSelect; + } & HookStrictSelect, ResourceUtilizationSelect>; + } & Omit< + UseMutationOptions< + { + createResourceUtilization: { + resourceUtilization: InferSelectResult; + }; + }, + Error, + CreateResourceUtilizationInput['resourceUtilization'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createResourceUtilization: { + resourceUtilization: InferSelectResult; + }; + }, + Error, + CreateResourceUtilizationInput['resourceUtilization'] +>; +export function useCreateResourceUtilizationMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: resourceUtilizationMutationKeys.create(), + mutationFn: (data: CreateResourceUtilizationInput['resourceUtilization']) => + getClient() + .resourceUtilization.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: resourceUtilizationKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useDeleteFunctionInvocationAttemptMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useDeleteFunctionInvocationAttemptMutation.ts new file mode 100644 index 000000000..5c208946c --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useDeleteFunctionInvocationAttemptMutation.ts @@ -0,0 +1,110 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { functionInvocationAttemptKeys } from '../query-keys'; +import { functionInvocationAttemptMutationKeys } from '../mutation-keys'; +import type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteFunctionInvocationAttemptMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteFunctionInvocationAttemptMutation< + S extends FunctionInvocationAttemptSelect, +>( + params: { + selection: { + fields: S & FunctionInvocationAttemptSelect; + } & HookStrictSelect, FunctionInvocationAttemptSelect>; + } & Omit< + UseMutationOptions< + { + deleteFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }, + Error, + { + id: string; + createdAt: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }, + Error, + { + id: string; + createdAt: string; + } +>; +export function useDeleteFunctionInvocationAttemptMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + createdAt: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: functionInvocationAttemptMutationKeys.all, + mutationFn: ({ id, createdAt }: { id: string; createdAt: string }) => + getClient() + .functionInvocationAttempt.delete({ + where: { + id, + createdAt, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: functionInvocationAttemptKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: functionInvocationAttemptKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformFunctionInvocationAttemptMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformFunctionInvocationAttemptMutation.ts new file mode 100644 index 000000000..048e2674a --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformFunctionInvocationAttemptMutation.ts @@ -0,0 +1,116 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { platformFunctionInvocationAttemptKeys } from '../query-keys'; +import { platformFunctionInvocationAttemptMutationKeys } from '../mutation-keys'; +import type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { mutate, isPending } = useDeletePlatformFunctionInvocationAttemptMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeletePlatformFunctionInvocationAttemptMutation< + S extends PlatformFunctionInvocationAttemptSelect, +>( + params: { + selection: { + fields: S & PlatformFunctionInvocationAttemptSelect; + } & HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; + } & Omit< + UseMutationOptions< + { + deletePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }, + Error, + { + id: string; + createdAt: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deletePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }, + Error, + { + id: string; + createdAt: string; + } +>; +export function useDeletePlatformFunctionInvocationAttemptMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + createdAt: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: platformFunctionInvocationAttemptMutationKeys.all, + mutationFn: ({ id, createdAt }: { id: string; createdAt: string }) => + getClient() + .platformFunctionInvocationAttempt.delete({ + where: { + id, + createdAt, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: platformFunctionInvocationAttemptKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: platformFunctionInvocationAttemptKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformResourceUsageLogMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformResourceUsageLogMutation.ts index 39bfec381..805abc882 100644 --- a/sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformResourceUsageLogMutation.ts +++ b/sdk/constructive-react/src/compute/hooks/mutations/useDeletePlatformResourceUsageLogMutation.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -21,7 +21,7 @@ export type { PlatformResourceUsageLogWithRelations, } from '../../orm/input-types'; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useDeleteResourceUsageLogMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useDeleteResourceUsageLogMutation.ts index c9948b46d..4404597e5 100644 --- a/sdk/constructive-react/src/compute/hooks/mutations/useDeleteResourceUsageLogMutation.ts +++ b/sdk/constructive-react/src/compute/hooks/mutations/useDeleteResourceUsageLogMutation.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -15,7 +15,7 @@ import type { ResourceUsageLogSelect, ResourceUsageLogWithRelations } from '../. import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; export type { ResourceUsageLogSelect, ResourceUsageLogWithRelations } from '../../orm/input-types'; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useUpdateFunctionInvocationAttemptMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useUpdateFunctionInvocationAttemptMutation.ts new file mode 100644 index 000000000..72cdffbca --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useUpdateFunctionInvocationAttemptMutation.ts @@ -0,0 +1,124 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { functionInvocationAttemptKeys } from '../query-keys'; +import { functionInvocationAttemptMutationKeys } from '../mutation-keys'; +import type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, + FunctionInvocationAttemptPatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, + FunctionInvocationAttemptPatch, +} from '../../orm/input-types'; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateFunctionInvocationAttemptMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', functionInvocationAttemptPatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateFunctionInvocationAttemptMutation< + S extends FunctionInvocationAttemptSelect, +>( + params: { + selection: { + fields: S & FunctionInvocationAttemptSelect; + } & HookStrictSelect, FunctionInvocationAttemptSelect>; + } & Omit< + UseMutationOptions< + { + updateFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }, + Error, + { + id: string; + createdAt: string; + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }, + Error, + { + id: string; + createdAt: string; + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; + } +>; +export function useUpdateFunctionInvocationAttemptMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + createdAt: string; + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: functionInvocationAttemptMutationKeys.all, + mutationFn: ({ + id, + createdAt, + functionInvocationAttemptPatch, + }: { + id: string; + createdAt: string; + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; + }) => + getClient() + .functionInvocationAttempt.update({ + where: { + id, + createdAt, + }, + data: functionInvocationAttemptPatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: functionInvocationAttemptKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: functionInvocationAttemptKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformFunctionInvocationAttemptMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformFunctionInvocationAttemptMutation.ts new file mode 100644 index 000000000..4d35d990b --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformFunctionInvocationAttemptMutation.ts @@ -0,0 +1,130 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { platformFunctionInvocationAttemptKeys } from '../query-keys'; +import { platformFunctionInvocationAttemptMutationKeys } from '../mutation-keys'; +import type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, + PlatformFunctionInvocationAttemptPatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, + PlatformFunctionInvocationAttemptPatch, +} from '../../orm/input-types'; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdatePlatformFunctionInvocationAttemptMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', platformFunctionInvocationAttemptPatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdatePlatformFunctionInvocationAttemptMutation< + S extends PlatformFunctionInvocationAttemptSelect, +>( + params: { + selection: { + fields: S & PlatformFunctionInvocationAttemptSelect; + } & HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; + } & Omit< + UseMutationOptions< + { + updatePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }, + Error, + { + id: string; + createdAt: string; + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updatePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }, + Error, + { + id: string; + createdAt: string; + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; + } +>; +export function useUpdatePlatformFunctionInvocationAttemptMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + createdAt: string; + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: platformFunctionInvocationAttemptMutationKeys.all, + mutationFn: ({ + id, + createdAt, + platformFunctionInvocationAttemptPatch, + }: { + id: string; + createdAt: string; + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; + }) => + getClient() + .platformFunctionInvocationAttempt.update({ + where: { + id, + createdAt, + }, + data: platformFunctionInvocationAttemptPatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: platformFunctionInvocationAttemptKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: platformFunctionInvocationAttemptKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformResourceUsageLogMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformResourceUsageLogMutation.ts index 48f83436c..c6a77dff6 100644 --- a/sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformResourceUsageLogMutation.ts +++ b/sdk/constructive-react/src/compute/hooks/mutations/useUpdatePlatformResourceUsageLogMutation.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -23,7 +23,7 @@ export type { PlatformResourceUsageLogPatch, } from '../../orm/input-types'; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx diff --git a/sdk/constructive-react/src/compute/hooks/mutations/useUpdateResourceUsageLogMutation.ts b/sdk/constructive-react/src/compute/hooks/mutations/useUpdateResourceUsageLogMutation.ts index ab186d534..093a08fbf 100644 --- a/sdk/constructive-react/src/compute/hooks/mutations/useUpdateResourceUsageLogMutation.ts +++ b/sdk/constructive-react/src/compute/hooks/mutations/useUpdateResourceUsageLogMutation.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -23,7 +23,7 @@ export type { ResourceUsageLogPatch, } from '../../orm/input-types'; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx diff --git a/sdk/constructive-react/src/compute/hooks/queries/index.ts b/sdk/constructive-react/src/compute/hooks/queries/index.ts index a3e83d9f1..d8346e382 100644 --- a/sdk/constructive-react/src/compute/hooks/queries/index.ts +++ b/sdk/constructive-react/src/compute/hooks/queries/index.ts @@ -5,7 +5,6 @@ */ export * from './useDbPresetsQuery'; export * from './useDbPresetQuery'; -export * from './useDeclaredCapacitiesQuery'; export * from './useFunctionApiBindingsQuery'; export * from './useFunctionApiBindingQuery'; export * from './useFunctionDefinitionsQuery'; @@ -32,6 +31,8 @@ export * from './useFunctionGraphRefsQuery'; export * from './useFunctionGraphRefQuery'; export * from './useFunctionGraphStoresQuery'; export * from './useFunctionGraphStoreQuery'; +export * from './useFunctionInvocationAttemptsQuery'; +export * from './useFunctionInvocationAttemptQuery'; export * from './useFunctionInvocationsQuery'; export * from './useFunctionInvocationQuery'; export * from './useGetAllTreeNodesQuery'; @@ -50,7 +51,6 @@ export * from './useNamespacesQuery'; export * from './useNamespaceQuery'; export * from './useNamespaceEventsQuery'; export * from './useNamespaceEventQuery'; -export * from './usePlatformDeclaredCapacitiesQuery'; export * from './usePlatformFunctionApiBindingsQuery'; export * from './usePlatformFunctionApiBindingQuery'; export * from './usePlatformFunctionDefinitionsQuery'; @@ -61,6 +61,8 @@ export * from './usePlatformFunctionDeploymentEventsQuery'; export * from './usePlatformFunctionDeploymentEventQuery'; export * from './usePlatformFunctionExecutionLogsQuery'; export * from './usePlatformFunctionExecutionLogQuery'; +export * from './usePlatformFunctionInvocationAttemptsQuery'; +export * from './usePlatformFunctionInvocationAttemptQuery'; export * from './usePlatformFunctionInvocationsQuery'; export * from './usePlatformFunctionInvocationQuery'; export * from './usePlatformInfraCommitsQuery'; @@ -78,6 +80,7 @@ export * from './usePlatformNamespaceEventsQuery'; export * from './usePlatformNamespaceEventQuery'; export * from './usePlatformResourcesQuery'; export * from './usePlatformResourceQuery'; +export * from './usePlatformResourceDeclaredCapacitiesQuery'; export * from './usePlatformResourceDefinitionsQuery'; export * from './usePlatformResourceDefinitionQuery'; export * from './usePlatformResourceEventsQuery'; @@ -90,7 +93,7 @@ export * from './usePlatformResourceUsageLogsQuery'; export * from './usePlatformResourceUsageLogQuery'; export * from './usePlatformResourceUsageSummariesQuery'; export * from './usePlatformResourceUsageSummaryQuery'; -export * from './usePlatformResourceUtilizationDailiesQuery'; +export * from './usePlatformResourceUtilizationsQuery'; export * from './usePlatformResourcesHealthsQuery'; export * from './usePlatformResourcesHealthQuery'; export * from './usePlatformResourcesRequirementsStatesQuery'; @@ -101,6 +104,7 @@ export * from './usePlatformWebhookEventsQuery'; export * from './usePlatformWebhookEventQuery'; export * from './useResourcesQuery'; export * from './useResourceQuery'; +export * from './useResourceDeclaredCapacitiesQuery'; export * from './useResourceDefinitionsQuery'; export * from './useResourceDefinitionQuery'; export * from './useResourceEventsQuery'; @@ -113,7 +117,7 @@ export * from './useResourceUsageLogsQuery'; export * from './useResourceUsageLogQuery'; export * from './useResourceUsageSummariesQuery'; export * from './useResourceUsageSummaryQuery'; -export * from './useResourceUtilizationDailiesQuery'; +export * from './useResourceUtilizationsQuery'; export * from './useResourcesHealthsQuery'; export * from './useResourcesHealthQuery'; export * from './useResourcesRequirementsStatesQuery'; diff --git a/sdk/constructive-react/src/compute/hooks/queries/useDeclaredCapacitiesQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useDeclaredCapacitiesQuery.ts deleted file mode 100644 index a50623fdb..000000000 --- a/sdk/constructive-react/src/compute/hooks/queries/useDeclaredCapacitiesQuery.ts +++ /dev/null @@ -1,163 +0,0 @@ -/** - * List query hook for DeclaredCapacity - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useQuery } from '@tanstack/react-query'; -import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildListSelectionArgs } from '../selection'; -import type { ListSelectionConfig } from '../selection'; -import { declaredCapacityKeys } from '../query-keys'; -import type { - DeclaredCapacitySelect, - DeclaredCapacityWithRelations, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy, -} from '../../orm/input-types'; -import type { - FindManyArgs, - InferSelectResult, - ConnectionResult, - HookStrictSelect, -} from '../../orm/select-types'; -export type { - DeclaredCapacitySelect, - DeclaredCapacityWithRelations, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy, -} from '../../orm/input-types'; -/** Query key factory - re-exported from query-keys.ts */ -export const declaredCapacitiesQueryKey = declaredCapacityKeys.list; -/** - * Query hook for fetching DeclaredCapacity list - * - * @example - * ```tsx - * const { data, isLoading } = useDeclaredCapacitiesQuery({ - * selection: { - * fields: { id: true, name: true }, - * where: { name: { equalTo: "example" } }, - * orderBy: ['CREATED_AT_DESC'], - * first: 10, - * }, - * }); - * ``` - */ -export function useDeclaredCapacitiesQuery< - S extends DeclaredCapacitySelect, - TData = { - declaredCapacities: ConnectionResult>; - }, ->( - params: { - selection: { - fields: S; - } & Omit, 'fields'> & - HookStrictSelect, DeclaredCapacitySelect>; - } & Omit< - UseQueryOptions< - { - declaredCapacities: ConnectionResult>; - }, - Error, - TData - >, - 'queryKey' | 'queryFn' - > -): UseQueryResult; -export function useDeclaredCapacitiesQuery( - params: { - selection: ListSelectionConfig< - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy - >; - } & Omit, 'queryKey' | 'queryFn'> -) { - const args = buildListSelectionArgs< - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy - >(params.selection); - const { selection: _selection, ...queryOptions } = params ?? {}; - void _selection; - return useQuery({ - queryKey: declaredCapacityKeys.list(args), - queryFn: () => getClient().declaredCapacity.findMany(args).unwrap(), - ...queryOptions, - }); -} -/** - * Fetch DeclaredCapacity list without React hooks - * - * @example - * ```ts - * const data = await fetchDeclaredCapacitiesQuery({ - * selection: { - * fields: { id: true }, - * first: 10, - * }, - * }); - * ``` - */ -export async function fetchDeclaredCapacitiesQuery(params: { - selection: { - fields: S; - } & Omit, 'fields'> & - HookStrictSelect, DeclaredCapacitySelect>; -}): Promise<{ - declaredCapacities: ConnectionResult>; -}>; -export async function fetchDeclaredCapacitiesQuery(params: { - selection: ListSelectionConfig< - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy - >; -}) { - const args = buildListSelectionArgs< - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy - >(params.selection); - return getClient().declaredCapacity.findMany(args).unwrap(); -} -/** - * Prefetch DeclaredCapacity list for SSR or cache warming - * - * @example - * ```ts - * await prefetchDeclaredCapacitiesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); - * ``` - */ -export async function prefetchDeclaredCapacitiesQuery( - queryClient: QueryClient, - params: { - selection: { - fields: S; - } & Omit, 'fields'> & - HookStrictSelect, DeclaredCapacitySelect>; - } -): Promise; -export async function prefetchDeclaredCapacitiesQuery( - queryClient: QueryClient, - params: { - selection: ListSelectionConfig< - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy - >; - } -): Promise { - const args = buildListSelectionArgs< - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy - >(params.selection); - await queryClient.prefetchQuery({ - queryKey: declaredCapacityKeys.list(args), - queryFn: () => getClient().declaredCapacity.findMany(args).unwrap(), - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptQuery.ts new file mode 100644 index 000000000..bd568c3ad --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptQuery.ts @@ -0,0 +1,151 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { functionInvocationAttemptKeys } from '../query-keys'; +import type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const functionInvocationAttemptQueryKey = functionInvocationAttemptKeys.detail; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { data, isLoading } = useFunctionInvocationAttemptQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useFunctionInvocationAttemptQuery< + S extends FunctionInvocationAttemptSelect, + TData = { + functionInvocationAttempt: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, FunctionInvocationAttemptSelect>; + } & Omit< + UseQueryOptions< + { + functionInvocationAttempt: InferSelectResult< + FunctionInvocationAttemptWithRelations, + S + > | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useFunctionInvocationAttemptQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: functionInvocationAttemptKeys.detail(params.id), + queryFn: () => + getClient() + .functionInvocationAttempt.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * const data = await fetchFunctionInvocationAttemptQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchFunctionInvocationAttemptQuery< + S extends FunctionInvocationAttemptSelect, +>(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, FunctionInvocationAttemptSelect>; +}): Promise<{ + functionInvocationAttempt: InferSelectResult | null; +}>; +export async function fetchFunctionInvocationAttemptQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .functionInvocationAttempt.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * await prefetchFunctionInvocationAttemptQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchFunctionInvocationAttemptQuery< + S extends FunctionInvocationAttemptSelect, +>( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, FunctionInvocationAttemptSelect>; + } +): Promise; +export async function prefetchFunctionInvocationAttemptQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: functionInvocationAttemptKeys.detail(params.id), + queryFn: () => + getClient() + .functionInvocationAttempt.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptsQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptsQuery.ts new file mode 100644 index 000000000..5834fdf92 --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/useFunctionInvocationAttemptsQuery.ts @@ -0,0 +1,182 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { functionInvocationAttemptKeys } from '../query-keys'; +import type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptWithRelations, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const functionInvocationAttemptsQueryKey = functionInvocationAttemptKeys.list; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { data, isLoading } = useFunctionInvocationAttemptsQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useFunctionInvocationAttemptsQuery< + S extends FunctionInvocationAttemptSelect, + TData = { + functionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }, +>( + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, FunctionInvocationAttemptSelect>; + } & Omit< + UseQueryOptions< + { + functionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useFunctionInvocationAttemptsQuery( + params: { + selection: ListSelectionConfig< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: functionInvocationAttemptKeys.list(args), + queryFn: () => getClient().functionInvocationAttempt.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * const data = await fetchFunctionInvocationAttemptsQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchFunctionInvocationAttemptsQuery< + S extends FunctionInvocationAttemptSelect, +>(params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, FunctionInvocationAttemptSelect>; +}): Promise<{ + functionInvocationAttempts: ConnectionResult< + InferSelectResult + >; +}>; +export async function fetchFunctionInvocationAttemptsQuery(params: { + selection: ListSelectionConfig< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + >; +}) { + const args = buildListSelectionArgs< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + >(params.selection); + return getClient().functionInvocationAttempt.findMany(args).unwrap(); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * await prefetchFunctionInvocationAttemptsQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchFunctionInvocationAttemptsQuery< + S extends FunctionInvocationAttemptSelect, +>( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, FunctionInvocationAttemptSelect>; + } +): Promise; +export async function prefetchFunctionInvocationAttemptsQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: functionInvocationAttemptKeys.list(args), + queryFn: () => getClient().functionInvocationAttempt.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformDeclaredCapacitiesQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformDeclaredCapacitiesQuery.ts deleted file mode 100644 index 5d8d11c11..000000000 --- a/sdk/constructive-react/src/compute/hooks/queries/usePlatformDeclaredCapacitiesQuery.ts +++ /dev/null @@ -1,182 +0,0 @@ -/** - * List query hook for PlatformDeclaredCapacity - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useQuery } from '@tanstack/react-query'; -import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildListSelectionArgs } from '../selection'; -import type { ListSelectionConfig } from '../selection'; -import { platformDeclaredCapacityKeys } from '../query-keys'; -import type { - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityWithRelations, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy, -} from '../../orm/input-types'; -import type { - FindManyArgs, - InferSelectResult, - ConnectionResult, - HookStrictSelect, -} from '../../orm/select-types'; -export type { - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityWithRelations, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy, -} from '../../orm/input-types'; -/** Query key factory - re-exported from query-keys.ts */ -export const platformDeclaredCapacitiesQueryKey = platformDeclaredCapacityKeys.list; -/** - * Query hook for fetching PlatformDeclaredCapacity list - * - * @example - * ```tsx - * const { data, isLoading } = usePlatformDeclaredCapacitiesQuery({ - * selection: { - * fields: { id: true, name: true }, - * where: { name: { equalTo: "example" } }, - * orderBy: ['CREATED_AT_DESC'], - * first: 10, - * }, - * }); - * ``` - */ -export function usePlatformDeclaredCapacitiesQuery< - S extends PlatformDeclaredCapacitySelect, - TData = { - platformDeclaredCapacities: ConnectionResult< - InferSelectResult - >; - }, ->( - params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig, - 'fields' - > & - HookStrictSelect, PlatformDeclaredCapacitySelect>; - } & Omit< - UseQueryOptions< - { - platformDeclaredCapacities: ConnectionResult< - InferSelectResult - >; - }, - Error, - TData - >, - 'queryKey' | 'queryFn' - > -): UseQueryResult; -export function usePlatformDeclaredCapacitiesQuery( - params: { - selection: ListSelectionConfig< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy - >; - } & Omit, 'queryKey' | 'queryFn'> -) { - const args = buildListSelectionArgs< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy - >(params.selection); - const { selection: _selection, ...queryOptions } = params ?? {}; - void _selection; - return useQuery({ - queryKey: platformDeclaredCapacityKeys.list(args), - queryFn: () => getClient().platformDeclaredCapacity.findMany(args).unwrap(), - ...queryOptions, - }); -} -/** - * Fetch PlatformDeclaredCapacity list without React hooks - * - * @example - * ```ts - * const data = await fetchPlatformDeclaredCapacitiesQuery({ - * selection: { - * fields: { id: true }, - * first: 10, - * }, - * }); - * ``` - */ -export async function fetchPlatformDeclaredCapacitiesQuery< - S extends PlatformDeclaredCapacitySelect, ->(params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig, - 'fields' - > & - HookStrictSelect, PlatformDeclaredCapacitySelect>; -}): Promise<{ - platformDeclaredCapacities: ConnectionResult< - InferSelectResult - >; -}>; -export async function fetchPlatformDeclaredCapacitiesQuery(params: { - selection: ListSelectionConfig< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy - >; -}) { - const args = buildListSelectionArgs< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy - >(params.selection); - return getClient().platformDeclaredCapacity.findMany(args).unwrap(); -} -/** - * Prefetch PlatformDeclaredCapacity list for SSR or cache warming - * - * @example - * ```ts - * await prefetchPlatformDeclaredCapacitiesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); - * ``` - */ -export async function prefetchPlatformDeclaredCapacitiesQuery< - S extends PlatformDeclaredCapacitySelect, ->( - queryClient: QueryClient, - params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig, - 'fields' - > & - HookStrictSelect, PlatformDeclaredCapacitySelect>; - } -): Promise; -export async function prefetchPlatformDeclaredCapacitiesQuery( - queryClient: QueryClient, - params: { - selection: ListSelectionConfig< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy - >; - } -): Promise { - const args = buildListSelectionArgs< - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy - >(params.selection); - await queryClient.prefetchQuery({ - queryKey: platformDeclaredCapacityKeys.list(args), - queryFn: () => getClient().platformDeclaredCapacity.findMany(args).unwrap(), - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptQuery.ts new file mode 100644 index 000000000..480490b66 --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptQuery.ts @@ -0,0 +1,158 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { platformFunctionInvocationAttemptKeys } from '../query-keys'; +import type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const platformFunctionInvocationAttemptQueryKey = + platformFunctionInvocationAttemptKeys.detail; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { data, isLoading } = usePlatformFunctionInvocationAttemptQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function usePlatformFunctionInvocationAttemptQuery< + S extends PlatformFunctionInvocationAttemptSelect, + TData = { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; + } & Omit< + UseQueryOptions< + { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function usePlatformFunctionInvocationAttemptQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: platformFunctionInvocationAttemptKeys.detail(params.id), + queryFn: () => + getClient() + .platformFunctionInvocationAttempt.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * const data = await fetchPlatformFunctionInvocationAttemptQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchPlatformFunctionInvocationAttemptQuery< + S extends PlatformFunctionInvocationAttemptSelect, +>(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; +}): Promise<{ + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; +}>; +export async function fetchPlatformFunctionInvocationAttemptQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .platformFunctionInvocationAttempt.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * await prefetchPlatformFunctionInvocationAttemptQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchPlatformFunctionInvocationAttemptQuery< + S extends PlatformFunctionInvocationAttemptSelect, +>( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; + } +): Promise; +export async function prefetchPlatformFunctionInvocationAttemptQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: platformFunctionInvocationAttemptKeys.detail(params.id), + queryFn: () => + getClient() + .platformFunctionInvocationAttempt.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptsQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptsQuery.ts new file mode 100644 index 000000000..c4af807cd --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/usePlatformFunctionInvocationAttemptsQuery.ts @@ -0,0 +1,195 @@ +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { platformFunctionInvocationAttemptKeys } from '../query-keys'; +import type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptWithRelations, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const platformFunctionInvocationAttemptsQueryKey = + platformFunctionInvocationAttemptKeys.list; +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```tsx + * const { data, isLoading } = usePlatformFunctionInvocationAttemptsQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function usePlatformFunctionInvocationAttemptsQuery< + S extends PlatformFunctionInvocationAttemptSelect, + TData = { + platformFunctionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }, +>( + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >, + 'fields' + > & + HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; + } & Omit< + UseQueryOptions< + { + platformFunctionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function usePlatformFunctionInvocationAttemptsQuery( + params: { + selection: ListSelectionConfig< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: platformFunctionInvocationAttemptKeys.list(args), + queryFn: () => getClient().platformFunctionInvocationAttempt.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * const data = await fetchPlatformFunctionInvocationAttemptsQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchPlatformFunctionInvocationAttemptsQuery< + S extends PlatformFunctionInvocationAttemptSelect, +>(params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >, + 'fields' + > & + HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; +}): Promise<{ + platformFunctionInvocationAttempts: ConnectionResult< + InferSelectResult + >; +}>; +export async function fetchPlatformFunctionInvocationAttemptsQuery(params: { + selection: ListSelectionConfig< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >; +}) { + const args = buildListSelectionArgs< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >(params.selection); + return getClient().platformFunctionInvocationAttempt.findMany(args).unwrap(); +} +/** + * Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail + * + * @example + * ```ts + * await prefetchPlatformFunctionInvocationAttemptsQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchPlatformFunctionInvocationAttemptsQuery< + S extends PlatformFunctionInvocationAttemptSelect, +>( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >, + 'fields' + > & + HookStrictSelect, PlatformFunctionInvocationAttemptSelect>; + } +): Promise; +export async function prefetchPlatformFunctionInvocationAttemptsQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: platformFunctionInvocationAttemptKeys.list(args), + queryFn: () => getClient().platformFunctionInvocationAttempt.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceDeclaredCapacitiesQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceDeclaredCapacitiesQuery.ts new file mode 100644 index 000000000..48df11dd9 --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceDeclaredCapacitiesQuery.ts @@ -0,0 +1,194 @@ +/** + * List query hook for PlatformResourceDeclaredCapacity + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { platformResourceDeclaredCapacityKeys } from '../query-keys'; +import type { + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityWithRelations, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityWithRelations, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const platformResourceDeclaredCapacitiesQueryKey = platformResourceDeclaredCapacityKeys.list; +/** + * Query hook for fetching PlatformResourceDeclaredCapacity list + * + * @example + * ```tsx + * const { data, isLoading } = usePlatformResourceDeclaredCapacitiesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function usePlatformResourceDeclaredCapacitiesQuery< + S extends PlatformResourceDeclaredCapacitySelect, + TData = { + platformResourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }, +>( + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >, + 'fields' + > & + HookStrictSelect, PlatformResourceDeclaredCapacitySelect>; + } & Omit< + UseQueryOptions< + { + platformResourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function usePlatformResourceDeclaredCapacitiesQuery( + params: { + selection: ListSelectionConfig< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: platformResourceDeclaredCapacityKeys.list(args), + queryFn: () => getClient().platformResourceDeclaredCapacity.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch PlatformResourceDeclaredCapacity list without React hooks + * + * @example + * ```ts + * const data = await fetchPlatformResourceDeclaredCapacitiesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchPlatformResourceDeclaredCapacitiesQuery< + S extends PlatformResourceDeclaredCapacitySelect, +>(params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >, + 'fields' + > & + HookStrictSelect, PlatformResourceDeclaredCapacitySelect>; +}): Promise<{ + platformResourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; +}>; +export async function fetchPlatformResourceDeclaredCapacitiesQuery(params: { + selection: ListSelectionConfig< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >; +}) { + const args = buildListSelectionArgs< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >(params.selection); + return getClient().platformResourceDeclaredCapacity.findMany(args).unwrap(); +} +/** + * Prefetch PlatformResourceDeclaredCapacity list for SSR or cache warming + * + * @example + * ```ts + * await prefetchPlatformResourceDeclaredCapacitiesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchPlatformResourceDeclaredCapacitiesQuery< + S extends PlatformResourceDeclaredCapacitySelect, +>( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >, + 'fields' + > & + HookStrictSelect, PlatformResourceDeclaredCapacitySelect>; + } +): Promise; +export async function prefetchPlatformResourceDeclaredCapacitiesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: platformResourceDeclaredCapacityKeys.list(args), + queryFn: () => getClient().platformResourceDeclaredCapacity.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogQuery.ts index a8fd7ce17..9676a774f 100644 --- a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogQuery.ts +++ b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogQuery.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -22,7 +22,7 @@ export type { /** Query key factory - re-exported from query-keys.ts */ export const platformResourceUsageLogQueryKey = platformResourceUsageLogKeys.detail; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx @@ -79,7 +79,7 @@ export function usePlatformResourceUsageLogQuery( }); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts @@ -112,7 +112,7 @@ export async function fetchPlatformResourceUsageLogQuery(params: { .unwrap(); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogsQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogsQuery.ts index 57b7f4e58..0bf8ad713 100644 --- a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogsQuery.ts +++ b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUsageLogsQuery.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -31,7 +31,7 @@ export type { /** Query key factory - re-exported from query-keys.ts */ export const platformResourceUsageLogsQueryKey = platformResourceUsageLogKeys.list; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx @@ -97,7 +97,7 @@ export function usePlatformResourceUsageLogsQuery( }); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts @@ -139,7 +139,7 @@ export async function fetchPlatformResourceUsageLogsQuery(params: { return getClient().platformResourceUsageLog.findMany(args).unwrap(); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationDailiesQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationDailiesQuery.ts deleted file mode 100644 index 78d3e1477..000000000 --- a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationDailiesQuery.ts +++ /dev/null @@ -1,194 +0,0 @@ -/** - * List query hook for PlatformResourceUtilizationDaily - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useQuery } from '@tanstack/react-query'; -import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildListSelectionArgs } from '../selection'; -import type { ListSelectionConfig } from '../selection'; -import { platformResourceUtilizationDailyKeys } from '../query-keys'; -import type { - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyWithRelations, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy, -} from '../../orm/input-types'; -import type { - FindManyArgs, - InferSelectResult, - ConnectionResult, - HookStrictSelect, -} from '../../orm/select-types'; -export type { - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyWithRelations, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy, -} from '../../orm/input-types'; -/** Query key factory - re-exported from query-keys.ts */ -export const platformResourceUtilizationDailiesQueryKey = platformResourceUtilizationDailyKeys.list; -/** - * Query hook for fetching PlatformResourceUtilizationDaily list - * - * @example - * ```tsx - * const { data, isLoading } = usePlatformResourceUtilizationDailiesQuery({ - * selection: { - * fields: { id: true, name: true }, - * where: { name: { equalTo: "example" } }, - * orderBy: ['CREATED_AT_DESC'], - * first: 10, - * }, - * }); - * ``` - */ -export function usePlatformResourceUtilizationDailiesQuery< - S extends PlatformResourceUtilizationDailySelect, - TData = { - platformResourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }, ->( - params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >, - 'fields' - > & - HookStrictSelect, PlatformResourceUtilizationDailySelect>; - } & Omit< - UseQueryOptions< - { - platformResourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }, - Error, - TData - >, - 'queryKey' | 'queryFn' - > -): UseQueryResult; -export function usePlatformResourceUtilizationDailiesQuery( - params: { - selection: ListSelectionConfig< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >; - } & Omit, 'queryKey' | 'queryFn'> -) { - const args = buildListSelectionArgs< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >(params.selection); - const { selection: _selection, ...queryOptions } = params ?? {}; - void _selection; - return useQuery({ - queryKey: platformResourceUtilizationDailyKeys.list(args), - queryFn: () => getClient().platformResourceUtilizationDaily.findMany(args).unwrap(), - ...queryOptions, - }); -} -/** - * Fetch PlatformResourceUtilizationDaily list without React hooks - * - * @example - * ```ts - * const data = await fetchPlatformResourceUtilizationDailiesQuery({ - * selection: { - * fields: { id: true }, - * first: 10, - * }, - * }); - * ``` - */ -export async function fetchPlatformResourceUtilizationDailiesQuery< - S extends PlatformResourceUtilizationDailySelect, ->(params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >, - 'fields' - > & - HookStrictSelect, PlatformResourceUtilizationDailySelect>; -}): Promise<{ - platformResourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; -}>; -export async function fetchPlatformResourceUtilizationDailiesQuery(params: { - selection: ListSelectionConfig< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >; -}) { - const args = buildListSelectionArgs< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >(params.selection); - return getClient().platformResourceUtilizationDaily.findMany(args).unwrap(); -} -/** - * Prefetch PlatformResourceUtilizationDaily list for SSR or cache warming - * - * @example - * ```ts - * await prefetchPlatformResourceUtilizationDailiesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); - * ``` - */ -export async function prefetchPlatformResourceUtilizationDailiesQuery< - S extends PlatformResourceUtilizationDailySelect, ->( - queryClient: QueryClient, - params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >, - 'fields' - > & - HookStrictSelect, PlatformResourceUtilizationDailySelect>; - } -): Promise; -export async function prefetchPlatformResourceUtilizationDailiesQuery( - queryClient: QueryClient, - params: { - selection: ListSelectionConfig< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >; - } -): Promise { - const args = buildListSelectionArgs< - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - >(params.selection); - await queryClient.prefetchQuery({ - queryKey: platformResourceUtilizationDailyKeys.list(args), - queryFn: () => getClient().platformResourceUtilizationDaily.findMany(args).unwrap(), - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationsQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationsQuery.ts new file mode 100644 index 000000000..cf2db270f --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/usePlatformResourceUtilizationsQuery.ts @@ -0,0 +1,182 @@ +/** + * List query hook for PlatformResourceUtilization + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { platformResourceUtilizationKeys } from '../query-keys'; +import type { + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationWithRelations, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationWithRelations, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const platformResourceUtilizationsQueryKey = platformResourceUtilizationKeys.list; +/** + * Query hook for fetching PlatformResourceUtilization list + * + * @example + * ```tsx + * const { data, isLoading } = usePlatformResourceUtilizationsQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function usePlatformResourceUtilizationsQuery< + S extends PlatformResourceUtilizationSelect, + TData = { + platformResourceUtilizations: ConnectionResult< + InferSelectResult + >; + }, +>( + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, PlatformResourceUtilizationSelect>; + } & Omit< + UseQueryOptions< + { + platformResourceUtilizations: ConnectionResult< + InferSelectResult + >; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function usePlatformResourceUtilizationsQuery( + params: { + selection: ListSelectionConfig< + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: platformResourceUtilizationKeys.list(args), + queryFn: () => getClient().platformResourceUtilization.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch PlatformResourceUtilization list without React hooks + * + * @example + * ```ts + * const data = await fetchPlatformResourceUtilizationsQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchPlatformResourceUtilizationsQuery< + S extends PlatformResourceUtilizationSelect, +>(params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, PlatformResourceUtilizationSelect>; +}): Promise<{ + platformResourceUtilizations: ConnectionResult< + InferSelectResult + >; +}>; +export async function fetchPlatformResourceUtilizationsQuery(params: { + selection: ListSelectionConfig< + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + >; +}) { + const args = buildListSelectionArgs< + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + >(params.selection); + return getClient().platformResourceUtilization.findMany(args).unwrap(); +} +/** + * Prefetch PlatformResourceUtilization list for SSR or cache warming + * + * @example + * ```ts + * await prefetchPlatformResourceUtilizationsQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchPlatformResourceUtilizationsQuery< + S extends PlatformResourceUtilizationSelect, +>( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, PlatformResourceUtilizationSelect>; + } +): Promise; +export async function prefetchPlatformResourceUtilizationsQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: platformResourceUtilizationKeys.list(args), + queryFn: () => getClient().platformResourceUtilization.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/queries/useResourceDeclaredCapacitiesQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useResourceDeclaredCapacitiesQuery.ts new file mode 100644 index 000000000..edcda11fe --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/useResourceDeclaredCapacitiesQuery.ts @@ -0,0 +1,182 @@ +/** + * List query hook for ResourceDeclaredCapacity + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { resourceDeclaredCapacityKeys } from '../query-keys'; +import type { + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityWithRelations, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityWithRelations, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const resourceDeclaredCapacitiesQueryKey = resourceDeclaredCapacityKeys.list; +/** + * Query hook for fetching ResourceDeclaredCapacity list + * + * @example + * ```tsx + * const { data, isLoading } = useResourceDeclaredCapacitiesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useResourceDeclaredCapacitiesQuery< + S extends ResourceDeclaredCapacitySelect, + TData = { + resourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }, +>( + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, ResourceDeclaredCapacitySelect>; + } & Omit< + UseQueryOptions< + { + resourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useResourceDeclaredCapacitiesQuery( + params: { + selection: ListSelectionConfig< + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: resourceDeclaredCapacityKeys.list(args), + queryFn: () => getClient().resourceDeclaredCapacity.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch ResourceDeclaredCapacity list without React hooks + * + * @example + * ```ts + * const data = await fetchResourceDeclaredCapacitiesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchResourceDeclaredCapacitiesQuery< + S extends ResourceDeclaredCapacitySelect, +>(params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, ResourceDeclaredCapacitySelect>; +}): Promise<{ + resourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; +}>; +export async function fetchResourceDeclaredCapacitiesQuery(params: { + selection: ListSelectionConfig< + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy + >; +}) { + const args = buildListSelectionArgs< + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy + >(params.selection); + return getClient().resourceDeclaredCapacity.findMany(args).unwrap(); +} +/** + * Prefetch ResourceDeclaredCapacity list for SSR or cache warming + * + * @example + * ```ts + * await prefetchResourceDeclaredCapacitiesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchResourceDeclaredCapacitiesQuery< + S extends ResourceDeclaredCapacitySelect, +>( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, ResourceDeclaredCapacitySelect>; + } +): Promise; +export async function prefetchResourceDeclaredCapacitiesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: resourceDeclaredCapacityKeys.list(args), + queryFn: () => getClient().resourceDeclaredCapacity.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogQuery.ts index 41d771957..a5e61f201 100644 --- a/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogQuery.ts +++ b/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogQuery.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -16,7 +16,7 @@ export type { ResourceUsageLogSelect, ResourceUsageLogWithRelations } from '../. /** Query key factory - re-exported from query-keys.ts */ export const resourceUsageLogQueryKey = resourceUsageLogKeys.detail; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx @@ -70,7 +70,7 @@ export function useResourceUsageLogQuery( }); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts @@ -101,7 +101,7 @@ export async function fetchResourceUsageLogQuery(params: { .unwrap(); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts diff --git a/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogsQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogsQuery.ts index a4fb6d718..1968faeb2 100644 --- a/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogsQuery.ts +++ b/sdk/constructive-react/src/compute/hooks/queries/useResourceUsageLogsQuery.ts @@ -1,5 +1,5 @@ /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * @generated by @constructive-io/graphql-codegen * DO NOT EDIT - changes will be overwritten */ @@ -31,7 +31,7 @@ export type { /** Query key factory - re-exported from query-keys.ts */ export const resourceUsageLogsQueryKey = resourceUsageLogKeys.list; /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```tsx @@ -90,7 +90,7 @@ export function useResourceUsageLogsQuery( }); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts @@ -125,7 +125,7 @@ export async function fetchResourceUsageLogsQuery(params: { return getClient().resourceUsageLog.findMany(args).unwrap(); } /** - * Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) + * Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) * * @example * ```ts diff --git a/sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationDailiesQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationDailiesQuery.ts deleted file mode 100644 index 68dd14478..000000000 --- a/sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationDailiesQuery.ts +++ /dev/null @@ -1,182 +0,0 @@ -/** - * List query hook for ResourceUtilizationDaily - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ - -import { useQuery } from '@tanstack/react-query'; -import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; -import { getClient } from '../client'; -import { buildListSelectionArgs } from '../selection'; -import type { ListSelectionConfig } from '../selection'; -import { resourceUtilizationDailyKeys } from '../query-keys'; -import type { - ResourceUtilizationDailySelect, - ResourceUtilizationDailyWithRelations, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy, -} from '../../orm/input-types'; -import type { - FindManyArgs, - InferSelectResult, - ConnectionResult, - HookStrictSelect, -} from '../../orm/select-types'; -export type { - ResourceUtilizationDailySelect, - ResourceUtilizationDailyWithRelations, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy, -} from '../../orm/input-types'; -/** Query key factory - re-exported from query-keys.ts */ -export const resourceUtilizationDailiesQueryKey = resourceUtilizationDailyKeys.list; -/** - * Query hook for fetching ResourceUtilizationDaily list - * - * @example - * ```tsx - * const { data, isLoading } = useResourceUtilizationDailiesQuery({ - * selection: { - * fields: { id: true, name: true }, - * where: { name: { equalTo: "example" } }, - * orderBy: ['CREATED_AT_DESC'], - * first: 10, - * }, - * }); - * ``` - */ -export function useResourceUtilizationDailiesQuery< - S extends ResourceUtilizationDailySelect, - TData = { - resourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }, ->( - params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig, - 'fields' - > & - HookStrictSelect, ResourceUtilizationDailySelect>; - } & Omit< - UseQueryOptions< - { - resourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }, - Error, - TData - >, - 'queryKey' | 'queryFn' - > -): UseQueryResult; -export function useResourceUtilizationDailiesQuery( - params: { - selection: ListSelectionConfig< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy - >; - } & Omit, 'queryKey' | 'queryFn'> -) { - const args = buildListSelectionArgs< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy - >(params.selection); - const { selection: _selection, ...queryOptions } = params ?? {}; - void _selection; - return useQuery({ - queryKey: resourceUtilizationDailyKeys.list(args), - queryFn: () => getClient().resourceUtilizationDaily.findMany(args).unwrap(), - ...queryOptions, - }); -} -/** - * Fetch ResourceUtilizationDaily list without React hooks - * - * @example - * ```ts - * const data = await fetchResourceUtilizationDailiesQuery({ - * selection: { - * fields: { id: true }, - * first: 10, - * }, - * }); - * ``` - */ -export async function fetchResourceUtilizationDailiesQuery< - S extends ResourceUtilizationDailySelect, ->(params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig, - 'fields' - > & - HookStrictSelect, ResourceUtilizationDailySelect>; -}): Promise<{ - resourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; -}>; -export async function fetchResourceUtilizationDailiesQuery(params: { - selection: ListSelectionConfig< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy - >; -}) { - const args = buildListSelectionArgs< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy - >(params.selection); - return getClient().resourceUtilizationDaily.findMany(args).unwrap(); -} -/** - * Prefetch ResourceUtilizationDaily list for SSR or cache warming - * - * @example - * ```ts - * await prefetchResourceUtilizationDailiesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); - * ``` - */ -export async function prefetchResourceUtilizationDailiesQuery< - S extends ResourceUtilizationDailySelect, ->( - queryClient: QueryClient, - params: { - selection: { - fields: S; - } & Omit< - ListSelectionConfig, - 'fields' - > & - HookStrictSelect, ResourceUtilizationDailySelect>; - } -): Promise; -export async function prefetchResourceUtilizationDailiesQuery( - queryClient: QueryClient, - params: { - selection: ListSelectionConfig< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy - >; - } -): Promise { - const args = buildListSelectionArgs< - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy - >(params.selection); - await queryClient.prefetchQuery({ - queryKey: resourceUtilizationDailyKeys.list(args), - queryFn: () => getClient().resourceUtilizationDaily.findMany(args).unwrap(), - }); -} diff --git a/sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationsQuery.ts b/sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationsQuery.ts new file mode 100644 index 000000000..3b67a2368 --- /dev/null +++ b/sdk/constructive-react/src/compute/hooks/queries/useResourceUtilizationsQuery.ts @@ -0,0 +1,174 @@ +/** + * List query hook for ResourceUtilization + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { resourceUtilizationKeys } from '../query-keys'; +import type { + ResourceUtilizationSelect, + ResourceUtilizationWithRelations, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + ResourceUtilizationSelect, + ResourceUtilizationWithRelations, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const resourceUtilizationsQueryKey = resourceUtilizationKeys.list; +/** + * Query hook for fetching ResourceUtilization list + * + * @example + * ```tsx + * const { data, isLoading } = useResourceUtilizationsQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useResourceUtilizationsQuery< + S extends ResourceUtilizationSelect, + TData = { + resourceUtilizations: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, ResourceUtilizationSelect>; + } & Omit< + UseQueryOptions< + { + resourceUtilizations: ConnectionResult< + InferSelectResult + >; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useResourceUtilizationsQuery( + params: { + selection: ListSelectionConfig< + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: resourceUtilizationKeys.list(args), + queryFn: () => getClient().resourceUtilization.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch ResourceUtilization list without React hooks + * + * @example + * ```ts + * const data = await fetchResourceUtilizationsQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchResourceUtilizationsQuery(params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, ResourceUtilizationSelect>; +}): Promise<{ + resourceUtilizations: ConnectionResult>; +}>; +export async function fetchResourceUtilizationsQuery(params: { + selection: ListSelectionConfig< + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy + >; +}) { + const args = buildListSelectionArgs< + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy + >(params.selection); + return getClient().resourceUtilization.findMany(args).unwrap(); +} +/** + * Prefetch ResourceUtilization list for SSR or cache warming + * + * @example + * ```ts + * await prefetchResourceUtilizationsQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchResourceUtilizationsQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit< + ListSelectionConfig, + 'fields' + > & + HookStrictSelect, ResourceUtilizationSelect>; + } +): Promise; +export async function prefetchResourceUtilizationsQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: resourceUtilizationKeys.list(args), + queryFn: () => getClient().resourceUtilization.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/compute/hooks/query-keys.ts b/sdk/constructive-react/src/compute/hooks/query-keys.ts index 94831a8d3..deb13ac5a 100644 --- a/sdk/constructive-react/src/compute/hooks/query-keys.ts +++ b/sdk/constructive-react/src/compute/hooks/query-keys.ts @@ -28,15 +28,6 @@ export const dbPresetKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...dbPresetKeys.details(), id] as const, } as const; -export const declaredCapacityKeys = { - /** All declaredCapacity queries */ all: ['declaredcapacity'] as const, - /** List query keys */ lists: () => [...declaredCapacityKeys.all, 'list'] as const, - /** List query key with variables */ list: (variables?: object) => - [...declaredCapacityKeys.lists(), variables] as const, - /** Detail query keys */ details: () => [...declaredCapacityKeys.all, 'detail'] as const, - /** Detail query key for specific item */ detail: (id: string | number) => - [...declaredCapacityKeys.details(), id] as const, -} as const; export const functionApiBindingKeys = { /** All functionApiBinding queries */ all: ['functionapibinding'] as const, /** List query keys */ lists: () => [...functionApiBindingKeys.all, 'list'] as const, @@ -158,6 +149,15 @@ export const functionGraphStoreKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...functionGraphStoreKeys.details(), id] as const, } as const; +export const functionInvocationAttemptKeys = { + /** All functionInvocationAttempt queries */ all: ['functioninvocationattempt'] as const, + /** List query keys */ lists: () => [...functionInvocationAttemptKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...functionInvocationAttemptKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...functionInvocationAttemptKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...functionInvocationAttemptKeys.details(), id] as const, +} as const; export const functionInvocationKeys = { /** All functionInvocation queries */ all: ['functioninvocation'] as const, /** List query keys */ lists: () => [...functionInvocationKeys.all, 'list'] as const, @@ -249,15 +249,6 @@ export const namespaceEventKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...namespaceEventKeys.details(), id] as const, } as const; -export const platformDeclaredCapacityKeys = { - /** All platformDeclaredCapacity queries */ all: ['platformdeclaredcapacity'] as const, - /** List query keys */ lists: () => [...platformDeclaredCapacityKeys.all, 'list'] as const, - /** List query key with variables */ list: (variables?: object) => - [...platformDeclaredCapacityKeys.lists(), variables] as const, - /** Detail query keys */ details: () => [...platformDeclaredCapacityKeys.all, 'detail'] as const, - /** Detail query key for specific item */ detail: (id: string | number) => - [...platformDeclaredCapacityKeys.details(), id] as const, -} as const; export const platformFunctionApiBindingKeys = { /** All platformFunctionApiBinding queries */ all: ['platformfunctionapibinding'] as const, /** List query keys */ lists: () => [...platformFunctionApiBindingKeys.all, 'list'] as const, @@ -310,6 +301,19 @@ export const platformFunctionExecutionLogKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...platformFunctionExecutionLogKeys.details(), id] as const, } as const; +export const platformFunctionInvocationAttemptKeys = { + /** All platformFunctionInvocationAttempt queries */ all: [ + 'platformfunctioninvocationattempt', + ] as const, + /** List query keys */ lists: () => + [...platformFunctionInvocationAttemptKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...platformFunctionInvocationAttemptKeys.lists(), variables] as const, + /** Detail query keys */ details: () => + [...platformFunctionInvocationAttemptKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...platformFunctionInvocationAttemptKeys.details(), id] as const, +} as const; export const platformFunctionInvocationKeys = { /** All platformFunctionInvocation queries */ all: ['platformfunctioninvocation'] as const, /** List query keys */ lists: () => [...platformFunctionInvocationKeys.all, 'list'] as const, @@ -396,6 +400,19 @@ export const platformResourceKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...platformResourceKeys.details(), id] as const, } as const; +export const platformResourceDeclaredCapacityKeys = { + /** All platformResourceDeclaredCapacity queries */ all: [ + 'platformresourcedeclaredcapacity', + ] as const, + /** List query keys */ lists: () => + [...platformResourceDeclaredCapacityKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...platformResourceDeclaredCapacityKeys.lists(), variables] as const, + /** Detail query keys */ details: () => + [...platformResourceDeclaredCapacityKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...platformResourceDeclaredCapacityKeys.details(), id] as const, +} as const; export const platformResourceDefinitionKeys = { /** All platformResourceDefinition queries */ all: ['platformresourcedefinition'] as const, /** List query keys */ lists: () => [...platformResourceDefinitionKeys.all, 'list'] as const, @@ -454,18 +471,15 @@ export const platformResourceUsageSummaryKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...platformResourceUsageSummaryKeys.details(), id] as const, } as const; -export const platformResourceUtilizationDailyKeys = { - /** All platformResourceUtilizationDaily queries */ all: [ - 'platformresourceutilizationdaily', - ] as const, - /** List query keys */ lists: () => - [...platformResourceUtilizationDailyKeys.all, 'list'] as const, +export const platformResourceUtilizationKeys = { + /** All platformResourceUtilization queries */ all: ['platformresourceutilization'] as const, + /** List query keys */ lists: () => [...platformResourceUtilizationKeys.all, 'list'] as const, /** List query key with variables */ list: (variables?: object) => - [...platformResourceUtilizationDailyKeys.lists(), variables] as const, + [...platformResourceUtilizationKeys.lists(), variables] as const, /** Detail query keys */ details: () => - [...platformResourceUtilizationDailyKeys.all, 'detail'] as const, + [...platformResourceUtilizationKeys.all, 'detail'] as const, /** Detail query key for specific item */ detail: (id: string | number) => - [...platformResourceUtilizationDailyKeys.details(), id] as const, + [...platformResourceUtilizationKeys.details(), id] as const, } as const; export const platformResourcesHealthKeys = { /** All platformResourcesHealth queries */ all: ['platformresourceshealth'] as const, @@ -529,6 +543,15 @@ export const resourceKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...resourceKeys.details(), id] as const, } as const; +export const resourceDeclaredCapacityKeys = { + /** All resourceDeclaredCapacity queries */ all: ['resourcedeclaredcapacity'] as const, + /** List query keys */ lists: () => [...resourceDeclaredCapacityKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...resourceDeclaredCapacityKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...resourceDeclaredCapacityKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...resourceDeclaredCapacityKeys.details(), id] as const, +} as const; export const resourceDefinitionKeys = { /** All resourceDefinition queries */ all: ['resourcedefinition'] as const, /** List query keys */ lists: () => [...resourceDefinitionKeys.all, 'list'] as const, @@ -583,14 +606,14 @@ export const resourceUsageSummaryKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...resourceUsageSummaryKeys.details(), id] as const, } as const; -export const resourceUtilizationDailyKeys = { - /** All resourceUtilizationDaily queries */ all: ['resourceutilizationdaily'] as const, - /** List query keys */ lists: () => [...resourceUtilizationDailyKeys.all, 'list'] as const, +export const resourceUtilizationKeys = { + /** All resourceUtilization queries */ all: ['resourceutilization'] as const, + /** List query keys */ lists: () => [...resourceUtilizationKeys.all, 'list'] as const, /** List query key with variables */ list: (variables?: object) => - [...resourceUtilizationDailyKeys.lists(), variables] as const, - /** Detail query keys */ details: () => [...resourceUtilizationDailyKeys.all, 'detail'] as const, + [...resourceUtilizationKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...resourceUtilizationKeys.all, 'detail'] as const, /** Detail query key for specific item */ detail: (id: string | number) => - [...resourceUtilizationDailyKeys.details(), id] as const, + [...resourceUtilizationKeys.details(), id] as const, } as const; export const resourcesHealthKeys = { /** All resourcesHealth queries */ all: ['resourceshealth'] as const, @@ -672,7 +695,6 @@ export const customQueryKeys = { */ export const queryKeys = { dbPreset: dbPresetKeys, - declaredCapacity: declaredCapacityKeys, functionApiBinding: functionApiBindingKeys, functionDefinition: functionDefinitionKeys, functionDeployment: functionDeploymentKeys, @@ -686,6 +708,7 @@ export const queryKeys = { functionGraphObject: functionGraphObjectKeys, functionGraphRef: functionGraphRefKeys, functionGraphStore: functionGraphStoreKeys, + functionInvocationAttempt: functionInvocationAttemptKeys, functionInvocation: functionInvocationKeys, getAllTreeNodesRecord: getAllTreeNodesRecordKeys, infraCommit: infraCommitKeys, @@ -696,12 +719,12 @@ export const queryKeys = { integrationProvider: integrationProviderKeys, namespace: namespaceKeys, namespaceEvent: namespaceEventKeys, - platformDeclaredCapacity: platformDeclaredCapacityKeys, platformFunctionApiBinding: platformFunctionApiBindingKeys, platformFunctionDefinition: platformFunctionDefinitionKeys, platformFunctionDeployment: platformFunctionDeploymentKeys, platformFunctionDeploymentEvent: platformFunctionDeploymentEventKeys, platformFunctionExecutionLog: platformFunctionExecutionLogKeys, + platformFunctionInvocationAttempt: platformFunctionInvocationAttemptKeys, platformFunctionInvocation: platformFunctionInvocationKeys, platformInfraCommit: platformInfraCommitKeys, platformInfraGetAllTreeNodesRecord: platformInfraGetAllTreeNodesRecordKeys, @@ -711,26 +734,28 @@ export const queryKeys = { platformNamespace: platformNamespaceKeys, platformNamespaceEvent: platformNamespaceEventKeys, platformResource: platformResourceKeys, + platformResourceDeclaredCapacity: platformResourceDeclaredCapacityKeys, platformResourceDefinition: platformResourceDefinitionKeys, platformResourceEvent: platformResourceEventKeys, platformResourceInstallation: platformResourceInstallationKeys, platformResourceStatusCheck: platformResourceStatusCheckKeys, platformResourceUsageLog: platformResourceUsageLogKeys, platformResourceUsageSummary: platformResourceUsageSummaryKeys, - platformResourceUtilizationDaily: platformResourceUtilizationDailyKeys, + platformResourceUtilization: platformResourceUtilizationKeys, platformResourcesHealth: platformResourcesHealthKeys, platformResourcesRequirementsState: platformResourcesRequirementsStateKeys, platformResourcesResolvedRequirement: platformResourcesResolvedRequirementKeys, platformWebhookEndpoint: platformWebhookEndpointKeys, platformWebhookEvent: platformWebhookEventKeys, resource: resourceKeys, + resourceDeclaredCapacity: resourceDeclaredCapacityKeys, resourceDefinition: resourceDefinitionKeys, resourceEvent: resourceEventKeys, resourceInstallation: resourceInstallationKeys, resourceStatusCheck: resourceStatusCheckKeys, resourceUsageLog: resourceUsageLogKeys, resourceUsageSummary: resourceUsageSummaryKeys, - resourceUtilizationDaily: resourceUtilizationDailyKeys, + resourceUtilization: resourceUtilizationKeys, resourcesHealth: resourcesHealthKeys, resourcesRequirementsState: resourcesRequirementsStateKeys, resourcesResolvedRequirement: resourcesResolvedRequirementKeys, diff --git a/sdk/constructive-react/src/compute/orm/README.md b/sdk/constructive-react/src/compute/orm/README.md index 1da2b6a29..c8d23ccd1 100644 --- a/sdk/constructive-react/src/compute/orm/README.md +++ b/sdk/constructive-react/src/compute/orm/README.md @@ -22,7 +22,6 @@ const db = createClient({ | Model | Operations | |-------|------------| | `dbPreset` | findMany, findOne, create, update, delete | -| `declaredCapacity` | findMany, findOne, create, update, delete | | `functionApiBinding` | findMany, findOne, create, update, delete | | `functionDefinition` | findMany, findOne, create, update, delete | | `functionDeployment` | findMany, findOne, create, update, delete | @@ -36,6 +35,7 @@ const db = createClient({ | `functionGraphObject` | findMany, findOne, create, update, delete | | `functionGraphRef` | findMany, findOne, create, update, delete | | `functionGraphStore` | findMany, findOne, create, update, delete | +| `functionInvocationAttempt` | findMany, findOne, create, update, delete | | `functionInvocation` | findMany, findOne, create, update, delete | | `getAllTreeNodesRecord` | findMany, findOne, create, update, delete | | `infraCommit` | findMany, findOne, create, update, delete | @@ -46,12 +46,12 @@ const db = createClient({ | `integrationProvider` | findMany, findOne, create, update, delete | | `namespace` | findMany, findOne, create, update, delete | | `namespaceEvent` | findMany, findOne, create, update, delete | -| `platformDeclaredCapacity` | findMany, findOne, create, update, delete | | `platformFunctionApiBinding` | findMany, findOne, create, update, delete | | `platformFunctionDefinition` | findMany, findOne, create, update, delete | | `platformFunctionDeployment` | findMany, findOne, create, update, delete | | `platformFunctionDeploymentEvent` | findMany, findOne, create, update, delete | | `platformFunctionExecutionLog` | findMany, findOne, create, update, delete | +| `platformFunctionInvocationAttempt` | findMany, findOne, create, update, delete | | `platformFunctionInvocation` | findMany, findOne, create, update, delete | | `platformInfraCommit` | findMany, findOne, create, update, delete | | `platformInfraGetAllTreeNodesRecord` | findMany, findOne, create, update, delete | @@ -61,26 +61,28 @@ const db = createClient({ | `platformNamespace` | findMany, findOne, create, update, delete | | `platformNamespaceEvent` | findMany, findOne, create, update, delete | | `platformResource` | findMany, findOne, create, update, delete | +| `platformResourceDeclaredCapacity` | findMany, findOne, create, update, delete | | `platformResourceDefinition` | findMany, findOne, create, update, delete | | `platformResourceEvent` | findMany, findOne, create, update, delete | | `platformResourceInstallation` | findMany, findOne, create, update, delete | | `platformResourceStatusCheck` | findMany, findOne, create, update, delete | | `platformResourceUsageLog` | findMany, findOne, create, update, delete | | `platformResourceUsageSummary` | findMany, findOne, create, update, delete | -| `platformResourceUtilizationDaily` | findMany, findOne, create, update, delete | +| `platformResourceUtilization` | findMany, findOne, create, update, delete | | `platformResourcesHealth` | findMany, findOne, create, update, delete | | `platformResourcesRequirementsState` | findMany, findOne, create, update, delete | | `platformResourcesResolvedRequirement` | findMany, findOne, create, update, delete | | `platformWebhookEndpoint` | findMany, findOne, create, update, delete | | `platformWebhookEvent` | findMany, findOne, create, update, delete | | `resource` | findMany, findOne, create, update, delete | +| `resourceDeclaredCapacity` | findMany, findOne, create, update, delete | | `resourceDefinition` | findMany, findOne, create, update, delete | | `resourceEvent` | findMany, findOne, create, update, delete | | `resourceInstallation` | findMany, findOne, create, update, delete | | `resourceStatusCheck` | findMany, findOne, create, update, delete | | `resourceUsageLog` | findMany, findOne, create, update, delete | | `resourceUsageSummary` | findMany, findOne, create, update, delete | -| `resourceUtilizationDaily` | findMany, findOne, create, update, delete | +| `resourceUtilization` | findMany, findOne, create, update, delete | | `resourcesHealth` | findMany, findOne, create, update, delete | | `resourcesRequirementsState` | findMany, findOne, create, update, delete | | `resourcesResolvedRequirement` | findMany, findOne, create, update, delete | @@ -128,47 +130,6 @@ const updated = await db.dbPreset.update({ where: { id: '' }, data: { acti const deleted = await db.dbPreset.delete({ where: { id: '' } }).execute(); ``` -### `db.declaredCapacity` - -CRUD operations for DeclaredCapacity records. - -**Fields:** - -| Field | Type | Editable | -|-------|------|----------| -| `cpuLimitMillicores` | BigInt | Yes | -| `cpuRequestMillicores` | BigInt | Yes | -| `installationId` | UUID | Yes | -| `isTransient` | Boolean | Yes | -| `kind` | String | Yes | -| `memoryLimitBytes` | BigInt | Yes | -| `memoryRequestBytes` | BigInt | Yes | -| `namespaceId` | UUID | Yes | -| `podCountMax` | Int | Yes | -| `podCountMin` | Int | Yes | -| `source` | String | Yes | -| `sourceId` | UUID | Yes | -| `storageSizeBytes` | BigInt | Yes | - -**Operations:** - -```typescript -// List all declaredCapacity records -const items = await db.declaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Get one by id -const item = await db.declaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Create -const created = await db.declaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); - -// Update -const updated = await db.declaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); - -// Delete -const deleted = await db.declaredCapacity.delete({ where: { id: '' } }).execute(); -``` - ### `db.functionApiBinding` CRUD operations for FunctionApiBinding records. @@ -709,6 +670,47 @@ const updated = await db.functionGraphStore.update({ where: { id: '' }, da const deleted = await db.functionGraphStore.delete({ where: { id: '' } }).execute(); ``` +### `db.functionInvocationAttempt` + +CRUD operations for FunctionInvocationAttempt records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `attempt` | Int | Yes | +| `createdAt` | Datetime | No | +| `databaseId` | UUID | Yes | +| `durationMs` | Int | Yes | +| `error` | String | Yes | +| `errorDetail` | JSON | Yes | +| `id` | UUID | No | +| `invocationCreatedAt` | Datetime | Yes | +| `invocationId` | UUID | Yes | +| `startedAt` | Datetime | Yes | +| `success` | Boolean | Yes | +| `taskIdentifier` | String | Yes | + +**Operations:** + +```typescript +// List all functionInvocationAttempt records +const items = await db.functionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Get one by id +const item = await db.functionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Create +const created = await db.functionInvocationAttempt.create({ data: { actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.functionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.functionInvocationAttempt.delete({ where: { id: '' } }).execute(); +``` + ### `db.functionInvocation` CRUD operations for FunctionInvocation records. @@ -1071,47 +1073,6 @@ const updated = await db.namespaceEvent.update({ where: { id: '' }, data: const deleted = await db.namespaceEvent.delete({ where: { id: '' } }).execute(); ``` -### `db.platformDeclaredCapacity` - -CRUD operations for PlatformDeclaredCapacity records. - -**Fields:** - -| Field | Type | Editable | -|-------|------|----------| -| `cpuLimitMillicores` | BigInt | Yes | -| `cpuRequestMillicores` | BigInt | Yes | -| `installationId` | UUID | Yes | -| `isTransient` | Boolean | Yes | -| `kind` | String | Yes | -| `memoryLimitBytes` | BigInt | Yes | -| `memoryRequestBytes` | BigInt | Yes | -| `namespaceId` | UUID | Yes | -| `podCountMax` | Int | Yes | -| `podCountMin` | Int | Yes | -| `source` | String | Yes | -| `sourceId` | UUID | Yes | -| `storageSizeBytes` | BigInt | Yes | - -**Operations:** - -```typescript -// List all platformDeclaredCapacity records -const items = await db.platformDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Get one by id -const item = await db.platformDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Create -const created = await db.platformDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); - -// Update -const updated = await db.platformDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); - -// Delete -const deleted = await db.platformDeclaredCapacity.delete({ where: { id: '' } }).execute(); -``` - ### `db.platformFunctionApiBinding` CRUD operations for PlatformFunctionApiBinding records. @@ -1154,6 +1115,7 @@ CRUD operations for PlatformFunctionDefinition records. | Field | Type | Editable | |-------|------|----------| | `accessChannels` | String | Yes | +| `billable` | Boolean | Yes | | `category` | String | Yes | | `concurrency` | Int | Yes | | `cpuLimitMillicores` | BigInt | Yes | @@ -1189,6 +1151,7 @@ CRUD operations for PlatformFunctionDefinition records. | `runtime` | String | Yes | | `scaleMax` | Int | Yes | | `scaleMin` | Int | Yes | +| `system` | Boolean | Yes | | `targetFunction` | String | Yes | | `targetSchema` | String | Yes | | `taskIdentifier` | String | Yes | @@ -1200,13 +1163,13 @@ CRUD operations for PlatformFunctionDefinition records. ```typescript // List all platformFunctionDefinition records -const items = await db.platformFunctionDefinition.findMany({ select: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); +const items = await db.platformFunctionDefinition.findMany({ select: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); // Get one by id -const item = await db.platformFunctionDefinition.findOne({ id: '', select: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); +const item = await db.platformFunctionDefinition.findOne({ id: '', select: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); // Create -const created = await db.platformFunctionDefinition.create({ data: { accessChannels: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute(); +const created = await db.platformFunctionDefinition.create({ data: { accessChannels: '', billable: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionDefinition.update({ where: { id: '' }, data: { accessChannels: '' }, select: { id: true } }).execute(); @@ -1335,6 +1298,46 @@ const updated = await db.platformFunctionExecutionLog.update({ where: { id: '' } }).execute(); ``` +### `db.platformFunctionInvocationAttempt` + +CRUD operations for PlatformFunctionInvocationAttempt records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `attempt` | Int | Yes | +| `createdAt` | Datetime | No | +| `durationMs` | Int | Yes | +| `error` | String | Yes | +| `errorDetail` | JSON | Yes | +| `id` | UUID | No | +| `invocationCreatedAt` | Datetime | Yes | +| `invocationId` | UUID | Yes | +| `startedAt` | Datetime | Yes | +| `success` | Boolean | Yes | +| `taskIdentifier` | String | Yes | + +**Operations:** + +```typescript +// List all platformFunctionInvocationAttempt records +const items = await db.platformFunctionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Get one by id +const item = await db.platformFunctionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Create +const created = await db.platformFunctionInvocationAttempt.create({ data: { actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.platformFunctionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.platformFunctionInvocationAttempt.delete({ where: { id: '' } }).execute(); +``` + ### `db.platformFunctionInvocation` CRUD operations for PlatformFunctionInvocation records. @@ -1681,6 +1684,47 @@ const updated = await db.platformResource.update({ where: { id: '' }, data const deleted = await db.platformResource.delete({ where: { id: '' } }).execute(); ``` +### `db.platformResourceDeclaredCapacity` + +CRUD operations for PlatformResourceDeclaredCapacity records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `cpuLimitMillicores` | BigInt | Yes | +| `cpuRequestMillicores` | BigInt | Yes | +| `installationId` | UUID | Yes | +| `isTransient` | Boolean | Yes | +| `kind` | String | Yes | +| `memoryLimitBytes` | BigInt | Yes | +| `memoryRequestBytes` | BigInt | Yes | +| `namespaceId` | UUID | Yes | +| `podCountMax` | Int | Yes | +| `podCountMin` | Int | Yes | +| `source` | String | Yes | +| `sourceId` | UUID | Yes | +| `storageSizeBytes` | BigInt | Yes | + +**Operations:** + +```typescript +// List all platformResourceDeclaredCapacity records +const items = await db.platformResourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Get one by id +const item = await db.platformResourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Create +const created = await db.platformResourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.platformResourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.platformResourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); +``` + ### `db.platformResourceDefinition` CRUD operations for PlatformResourceDefinition records. @@ -1911,9 +1955,9 @@ const updated = await db.platformResourceUsageSummary.update({ where: { id: '' } }).execute(); ``` -### `db.platformResourceUtilizationDaily` +### `db.platformResourceUtilization` -CRUD operations for PlatformResourceUtilizationDaily records. +CRUD operations for PlatformResourceUtilization records. **Fields:** @@ -1942,20 +1986,20 @@ CRUD operations for PlatformResourceUtilizationDaily records. **Operations:** ```typescript -// List all platformResourceUtilizationDaily records -const items = await db.platformResourceUtilizationDaily.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +// List all platformResourceUtilization records +const items = await db.platformResourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id -const item = await db.platformResourceUtilizationDaily.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +const item = await db.platformResourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create -const created = await db.platformResourceUtilizationDaily.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); +const created = await db.platformResourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update -const updated = await db.platformResourceUtilizationDaily.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); +const updated = await db.platformResourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete -const deleted = await db.platformResourceUtilizationDaily.delete({ where: { id: '' } }).execute(); +const deleted = await db.platformResourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourcesHealth` @@ -2228,6 +2272,47 @@ const updated = await db.resource.update({ where: { id: '' }, data: { anno const deleted = await db.resource.delete({ where: { id: '' } }).execute(); ``` +### `db.resourceDeclaredCapacity` + +CRUD operations for ResourceDeclaredCapacity records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `cpuLimitMillicores` | BigInt | Yes | +| `cpuRequestMillicores` | BigInt | Yes | +| `installationId` | UUID | Yes | +| `isTransient` | Boolean | Yes | +| `kind` | String | Yes | +| `memoryLimitBytes` | BigInt | Yes | +| `memoryRequestBytes` | BigInt | Yes | +| `namespaceId` | UUID | Yes | +| `podCountMax` | Int | Yes | +| `podCountMin` | Int | Yes | +| `source` | String | Yes | +| `sourceId` | UUID | Yes | +| `storageSizeBytes` | BigInt | Yes | + +**Operations:** + +```typescript +// List all resourceDeclaredCapacity records +const items = await db.resourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Get one by id +const item = await db.resourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Create +const created = await db.resourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.resourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.resourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); +``` + ### `db.resourceDefinition` CRUD operations for ResourceDefinition records. @@ -2464,9 +2549,9 @@ const updated = await db.resourceUsageSummary.update({ where: { id: '' }, const deleted = await db.resourceUsageSummary.delete({ where: { id: '' } }).execute(); ``` -### `db.resourceUtilizationDaily` +### `db.resourceUtilization` -CRUD operations for ResourceUtilizationDaily records. +CRUD operations for ResourceUtilization records. **Fields:** @@ -2495,20 +2580,20 @@ CRUD operations for ResourceUtilizationDaily records. **Operations:** ```typescript -// List all resourceUtilizationDaily records -const items = await db.resourceUtilizationDaily.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +// List all resourceUtilization records +const items = await db.resourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id -const item = await db.resourceUtilizationDaily.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +const item = await db.resourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create -const created = await db.resourceUtilizationDaily.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); +const created = await db.resourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update -const updated = await db.resourceUtilizationDaily.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); +const updated = await db.resourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete -const deleted = await db.resourceUtilizationDaily.delete({ where: { id: '' } }).execute(); +const deleted = await db.resourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.resourcesHealth` @@ -2980,7 +3065,7 @@ platformResourceInstallationsInstall | `input` | PlatformResourceInstallationsInstallInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsRollback` @@ -2995,7 +3080,7 @@ platformResourceInstallationsRollback | `input` | PlatformResourceInstallationsRollbackInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUninstall` @@ -3010,7 +3095,7 @@ platformResourceInstallationsUninstall | `input` | PlatformResourceInstallationsUninstallInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUpgrade` @@ -3025,7 +3110,7 @@ platformResourceInstallationsUpgrade | `input` | PlatformResourceInstallationsUpgradeInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.provisionBucket` @@ -3058,7 +3143,7 @@ resourceInstallationsInstall | `input` | ResourceInstallationsInstallInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.resourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsRollback` @@ -3073,7 +3158,7 @@ resourceInstallationsRollback | `input` | ResourceInstallationsRollbackInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUninstall` @@ -3088,7 +3173,7 @@ resourceInstallationsUninstall | `input` | ResourceInstallationsUninstallInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUpgrade` @@ -3103,7 +3188,7 @@ resourceInstallationsUpgrade | `input` | ResourceInstallationsUpgradeInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.saveGraph` diff --git a/sdk/constructive-react/src/compute/orm/index.ts b/sdk/constructive-react/src/compute/orm/index.ts index 979783107..933b08ed3 100644 --- a/sdk/constructive-react/src/compute/orm/index.ts +++ b/sdk/constructive-react/src/compute/orm/index.ts @@ -6,7 +6,6 @@ import { OrmClient } from './client'; import type { OrmClientConfig } from './client'; import { DbPresetModel } from './models/dbPreset'; -import { DeclaredCapacityModel } from './models/declaredCapacity'; import { FunctionApiBindingModel } from './models/functionApiBinding'; import { FunctionDefinitionModel } from './models/functionDefinition'; import { FunctionDeploymentModel } from './models/functionDeployment'; @@ -20,6 +19,7 @@ import { FunctionGraphExecutionOutputModel } from './models/functionGraphExecuti import { FunctionGraphObjectModel } from './models/functionGraphObject'; import { FunctionGraphRefModel } from './models/functionGraphRef'; import { FunctionGraphStoreModel } from './models/functionGraphStore'; +import { FunctionInvocationAttemptModel } from './models/functionInvocationAttempt'; import { FunctionInvocationModel } from './models/functionInvocation'; import { GetAllTreeNodesRecordModel } from './models/getAllTreeNodesRecord'; import { InfraCommitModel } from './models/infraCommit'; @@ -30,12 +30,12 @@ import { InfraStoreModel } from './models/infraStore'; import { IntegrationProviderModel } from './models/integrationProvider'; import { NamespaceModel } from './models/namespace'; import { NamespaceEventModel } from './models/namespaceEvent'; -import { PlatformDeclaredCapacityModel } from './models/platformDeclaredCapacity'; import { PlatformFunctionApiBindingModel } from './models/platformFunctionApiBinding'; import { PlatformFunctionDefinitionModel } from './models/platformFunctionDefinition'; import { PlatformFunctionDeploymentModel } from './models/platformFunctionDeployment'; import { PlatformFunctionDeploymentEventModel } from './models/platformFunctionDeploymentEvent'; import { PlatformFunctionExecutionLogModel } from './models/platformFunctionExecutionLog'; +import { PlatformFunctionInvocationAttemptModel } from './models/platformFunctionInvocationAttempt'; import { PlatformFunctionInvocationModel } from './models/platformFunctionInvocation'; import { PlatformInfraCommitModel } from './models/platformInfraCommit'; import { PlatformInfraGetAllTreeNodesRecordModel } from './models/platformInfraGetAllTreeNodesRecord'; @@ -45,26 +45,28 @@ import { PlatformInfraStoreModel } from './models/platformInfraStore'; import { PlatformNamespaceModel } from './models/platformNamespace'; import { PlatformNamespaceEventModel } from './models/platformNamespaceEvent'; import { PlatformResourceModel } from './models/platformResource'; +import { PlatformResourceDeclaredCapacityModel } from './models/platformResourceDeclaredCapacity'; import { PlatformResourceDefinitionModel } from './models/platformResourceDefinition'; import { PlatformResourceEventModel } from './models/platformResourceEvent'; import { PlatformResourceInstallationModel } from './models/platformResourceInstallation'; import { PlatformResourceStatusCheckModel } from './models/platformResourceStatusCheck'; import { PlatformResourceUsageLogModel } from './models/platformResourceUsageLog'; import { PlatformResourceUsageSummaryModel } from './models/platformResourceUsageSummary'; -import { PlatformResourceUtilizationDailyModel } from './models/platformResourceUtilizationDaily'; +import { PlatformResourceUtilizationModel } from './models/platformResourceUtilization'; import { PlatformResourcesHealthModel } from './models/platformResourcesHealth'; import { PlatformResourcesRequirementsStateModel } from './models/platformResourcesRequirementsState'; import { PlatformResourcesResolvedRequirementModel } from './models/platformResourcesResolvedRequirement'; import { PlatformWebhookEndpointModel } from './models/platformWebhookEndpoint'; import { PlatformWebhookEventModel } from './models/platformWebhookEvent'; import { ResourceModel } from './models/resource'; +import { ResourceDeclaredCapacityModel } from './models/resourceDeclaredCapacity'; import { ResourceDefinitionModel } from './models/resourceDefinition'; import { ResourceEventModel } from './models/resourceEvent'; import { ResourceInstallationModel } from './models/resourceInstallation'; import { ResourceStatusCheckModel } from './models/resourceStatusCheck'; import { ResourceUsageLogModel } from './models/resourceUsageLog'; import { ResourceUsageSummaryModel } from './models/resourceUsageSummary'; -import { ResourceUtilizationDailyModel } from './models/resourceUtilizationDaily'; +import { ResourceUtilizationModel } from './models/resourceUtilization'; import { ResourcesHealthModel } from './models/resourcesHealth'; import { ResourcesRequirementsStateModel } from './models/resourcesRequirementsState'; import { ResourcesResolvedRequirementModel } from './models/resourcesResolvedRequirement'; @@ -106,7 +108,6 @@ export function createClient(config: OrmClientConfig) { const client = new OrmClient(config); return { dbPreset: new DbPresetModel(client), - declaredCapacity: new DeclaredCapacityModel(client), functionApiBinding: new FunctionApiBindingModel(client), functionDefinition: new FunctionDefinitionModel(client), functionDeployment: new FunctionDeploymentModel(client), @@ -120,6 +121,7 @@ export function createClient(config: OrmClientConfig) { functionGraphObject: new FunctionGraphObjectModel(client), functionGraphRef: new FunctionGraphRefModel(client), functionGraphStore: new FunctionGraphStoreModel(client), + functionInvocationAttempt: new FunctionInvocationAttemptModel(client), functionInvocation: new FunctionInvocationModel(client), getAllTreeNodesRecord: new GetAllTreeNodesRecordModel(client), infraCommit: new InfraCommitModel(client), @@ -130,12 +132,12 @@ export function createClient(config: OrmClientConfig) { integrationProvider: new IntegrationProviderModel(client), namespace: new NamespaceModel(client), namespaceEvent: new NamespaceEventModel(client), - platformDeclaredCapacity: new PlatformDeclaredCapacityModel(client), platformFunctionApiBinding: new PlatformFunctionApiBindingModel(client), platformFunctionDefinition: new PlatformFunctionDefinitionModel(client), platformFunctionDeployment: new PlatformFunctionDeploymentModel(client), platformFunctionDeploymentEvent: new PlatformFunctionDeploymentEventModel(client), platformFunctionExecutionLog: new PlatformFunctionExecutionLogModel(client), + platformFunctionInvocationAttempt: new PlatformFunctionInvocationAttemptModel(client), platformFunctionInvocation: new PlatformFunctionInvocationModel(client), platformInfraCommit: new PlatformInfraCommitModel(client), platformInfraGetAllTreeNodesRecord: new PlatformInfraGetAllTreeNodesRecordModel(client), @@ -145,26 +147,28 @@ export function createClient(config: OrmClientConfig) { platformNamespace: new PlatformNamespaceModel(client), platformNamespaceEvent: new PlatformNamespaceEventModel(client), platformResource: new PlatformResourceModel(client), + platformResourceDeclaredCapacity: new PlatformResourceDeclaredCapacityModel(client), platformResourceDefinition: new PlatformResourceDefinitionModel(client), platformResourceEvent: new PlatformResourceEventModel(client), platformResourceInstallation: new PlatformResourceInstallationModel(client), platformResourceStatusCheck: new PlatformResourceStatusCheckModel(client), platformResourceUsageLog: new PlatformResourceUsageLogModel(client), platformResourceUsageSummary: new PlatformResourceUsageSummaryModel(client), - platformResourceUtilizationDaily: new PlatformResourceUtilizationDailyModel(client), + platformResourceUtilization: new PlatformResourceUtilizationModel(client), platformResourcesHealth: new PlatformResourcesHealthModel(client), platformResourcesRequirementsState: new PlatformResourcesRequirementsStateModel(client), platformResourcesResolvedRequirement: new PlatformResourcesResolvedRequirementModel(client), platformWebhookEndpoint: new PlatformWebhookEndpointModel(client), platformWebhookEvent: new PlatformWebhookEventModel(client), resource: new ResourceModel(client), + resourceDeclaredCapacity: new ResourceDeclaredCapacityModel(client), resourceDefinition: new ResourceDefinitionModel(client), resourceEvent: new ResourceEventModel(client), resourceInstallation: new ResourceInstallationModel(client), resourceStatusCheck: new ResourceStatusCheckModel(client), resourceUsageLog: new ResourceUsageLogModel(client), resourceUsageSummary: new ResourceUsageSummaryModel(client), - resourceUtilizationDaily: new ResourceUtilizationDailyModel(client), + resourceUtilization: new ResourceUtilizationModel(client), resourcesHealth: new ResourcesHealthModel(client), resourcesRequirementsState: new ResourcesRequirementsStateModel(client), resourcesResolvedRequirement: new ResourcesResolvedRequirementModel(client), diff --git a/sdk/constructive-react/src/compute/orm/input-types.ts b/sdk/constructive-react/src/compute/orm/input-types.ts index 676843824..6ff018412 100644 --- a/sdk/constructive-react/src/compute/orm/input-types.ts +++ b/sdk/constructive-react/src/compute/orm/input-types.ts @@ -260,21 +260,6 @@ export interface DbPreset { /** Timestamp of last modification */ updatedAt?: string | null; } -export interface DeclaredCapacity { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} /** Join table binding function definitions to API endpoints with per-binding alias and config */ export interface FunctionApiBinding { /** Binding alias (e.g. default, staging, production) */ @@ -365,7 +350,7 @@ export interface FunctionDefinition { targetFunction?: string | null; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string | null; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ + /** Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) */ taskIdentifier?: string | null; /** Knative request timeout in seconds */ timeoutSeconds?: number | null; @@ -659,6 +644,35 @@ export interface FunctionGraphStore { /** Opaque store partition key for the global tier */ scopeId?: string | null; } +/** Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail */ +export interface FunctionInvocationAttempt { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string | null; + /** 1-based attempt number for this invocation */ + attempt?: number | null; + /** When the attempt result was recorded (partition key) */ + createdAt?: string | null; + /** Database that owns this resource (database-scoped isolation) */ + databaseId?: string | null; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number | null; + /** Error message when the attempt failed */ + error?: string | null; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record | null; + /** Unique attempt identifier */ + id: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string | null; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string | null; + /** When the attempt began executing */ + startedAt?: string | null; + /** Whether this attempt completed successfully */ + success?: boolean | null; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string | null; +} /** Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. */ export interface FunctionInvocation { /** Who triggered the invocation (NULL for system/cron) */ @@ -677,7 +691,7 @@ export interface FunctionInvocation { definitionScope?: string | null; /** Wall-clock execution time in milliseconds */ durationMs?: number | null; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string | null; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string | null; @@ -697,7 +711,7 @@ export interface FunctionInvocation { result?: Record | null; /** When execution started */ startedAt?: string | null; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string | null; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string | null; @@ -841,21 +855,6 @@ export interface NamespaceEvent { /** Namespace this event belongs to */ namespaceId?: string | null; } -export interface PlatformDeclaredCapacity { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} /** Join table binding function definitions to API endpoints with per-binding alias and config */ export interface PlatformFunctionApiBinding { /** Binding alias (e.g. default, staging, production) */ @@ -872,6 +871,8 @@ export interface PlatformFunctionApiBinding { export interface PlatformFunctionDefinition { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[] | null; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean | null; /** Function task category (e.g. email, embed, chunk, custom) */ category?: string | null; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -940,11 +941,13 @@ export interface PlatformFunctionDefinition { scaleMax?: number | null; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number | null; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean | null; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string | null; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string | null; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ + /** Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) */ taskIdentifier?: string | null; /** Knative request timeout in seconds */ timeoutSeconds?: number | null; @@ -1030,6 +1033,33 @@ export interface PlatformFunctionExecutionLog { /** Function routing key (NULL for generic job logs) */ taskIdentifier?: string | null; } +/** Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail */ +export interface PlatformFunctionInvocationAttempt { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string | null; + /** 1-based attempt number for this invocation */ + attempt?: number | null; + /** When the attempt result was recorded (partition key) */ + createdAt?: string | null; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number | null; + /** Error message when the attempt failed */ + error?: string | null; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record | null; + /** Unique attempt identifier */ + id: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string | null; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string | null; + /** When the attempt began executing */ + startedAt?: string | null; + /** Whether this attempt completed successfully */ + success?: boolean | null; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string | null; +} /** Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. */ export interface PlatformFunctionInvocation { /** Who triggered the invocation (NULL for system/cron) */ @@ -1046,7 +1076,7 @@ export interface PlatformFunctionInvocation { definitionScope?: string | null; /** Wall-clock execution time in milliseconds */ durationMs?: number | null; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string | null; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string | null; @@ -1066,7 +1096,7 @@ export interface PlatformFunctionInvocation { result?: Record | null; /** When execution started */ startedAt?: string | null; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string | null; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string | null; @@ -1195,7 +1225,7 @@ export interface PlatformResource { installationId?: string | null; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string | null; /** Key/value pairs for selecting and filtering resources */ labels?: Record | null; @@ -1234,6 +1264,21 @@ export interface PlatformResource { updatedAt?: string | null; updatedBy?: string | null; } +export interface PlatformResourceDeclaredCapacity { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} /** Resource definitions — templates for resource kinds declaring default spec and secret/config requirements */ export interface PlatformResourceDefinition { /** Freeform metadata for tooling and operational notes */ @@ -1247,7 +1292,7 @@ export interface PlatformResourceDefinition { id: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string | null; /** Key/value pairs for selecting and filtering definitions */ labels?: Record | null; @@ -1324,7 +1369,7 @@ export interface PlatformResourceStatusCheck { /** Check lifecycle: pending, running, completed, failed */ status?: string | null; } -/** Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) */ +/** Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) */ export interface PlatformResourceUsageLog { /** CPU gauge in millicores at sample time (NULL when unknown) */ cpuMillicores?: string | null; @@ -1342,7 +1387,7 @@ export interface PlatformResourceUsageLog { resourceId?: string | null; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string | null; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string | null; } /** Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals */ @@ -1366,7 +1411,7 @@ export interface PlatformResourceUsageSummary { /** Number of raw samples aggregated into this summary */ sampleCount?: number | null; } -export interface PlatformResourceUtilizationDaily { +export interface PlatformResourceUtilization { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -1507,7 +1552,7 @@ export interface Resource { installationId?: string | null; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string | null; /** Key/value pairs for selecting and filtering resources */ labels?: Record | null; @@ -1546,6 +1591,21 @@ export interface Resource { updatedAt?: string | null; updatedBy?: string | null; } +export interface ResourceDeclaredCapacity { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} /** Resource definitions — templates for resource kinds declaring default spec and secret/config requirements */ export interface ResourceDefinition { /** Freeform metadata for tooling and operational notes */ @@ -1561,7 +1621,7 @@ export interface ResourceDefinition { id: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string | null; /** Key/value pairs for selecting and filtering definitions */ labels?: Record | null; @@ -1644,7 +1704,7 @@ export interface ResourceStatusCheck { /** Check lifecycle: pending, running, completed, failed */ status?: string | null; } -/** Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) */ +/** Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) */ export interface ResourceUsageLog { /** CPU gauge in millicores at sample time (NULL when unknown) */ cpuMillicores?: string | null; @@ -1664,7 +1724,7 @@ export interface ResourceUsageLog { resourceId?: string | null; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string | null; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string | null; } /** Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals */ @@ -1690,7 +1750,7 @@ export interface ResourceUsageSummary { /** Number of raw samples aggregated into this summary */ sampleCount?: number | null; } -export interface ResourceUtilizationDaily { +export interface ResourceUtilization { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -1831,7 +1891,6 @@ export interface PageInfo { } // ============ Entity Relation Types ============ export interface DbPresetRelations {} -export interface DeclaredCapacityRelations {} export interface FunctionApiBindingRelations { functionDefinition?: FunctionDefinition | null; functionInvocationsByApiBindingId?: ConnectionResult; @@ -1858,6 +1917,7 @@ export interface FunctionGraphExecutionOutputRelations {} export interface FunctionGraphObjectRelations {} export interface FunctionGraphRefRelations {} export interface FunctionGraphStoreRelations {} +export interface FunctionInvocationAttemptRelations {} export interface FunctionInvocationRelations { apiBinding?: FunctionApiBinding | null; } @@ -1876,7 +1936,6 @@ export interface NamespaceRelations { webhookEndpoints?: ConnectionResult; } export interface NamespaceEventRelations {} -export interface PlatformDeclaredCapacityRelations {} export interface PlatformFunctionApiBindingRelations { functionDefinition?: PlatformFunctionDefinition | null; platformFunctionInvocationsByApiBindingId?: ConnectionResult; @@ -1891,6 +1950,7 @@ export interface PlatformFunctionDeploymentRelations { } export interface PlatformFunctionDeploymentEventRelations {} export interface PlatformFunctionExecutionLogRelations {} +export interface PlatformFunctionInvocationAttemptRelations {} export interface PlatformFunctionInvocationRelations { apiBinding?: PlatformFunctionApiBinding | null; } @@ -1913,6 +1973,7 @@ export interface PlatformResourceRelations { resourceDefinition?: PlatformResourceDefinition | null; platformResourceStatusChecksByResourceId?: ConnectionResult; } +export interface PlatformResourceDeclaredCapacityRelations {} export interface PlatformResourceDefinitionRelations { namespace?: PlatformNamespace | null; platformResourcesByResourceDefinitionId?: ConnectionResult; @@ -1927,7 +1988,7 @@ export interface PlatformResourceStatusCheckRelations { } export interface PlatformResourceUsageLogRelations {} export interface PlatformResourceUsageSummaryRelations {} -export interface PlatformResourceUtilizationDailyRelations {} +export interface PlatformResourceUtilizationRelations {} export interface PlatformResourcesHealthRelations {} export interface PlatformResourcesRequirementsStateRelations {} export interface PlatformResourcesResolvedRequirementRelations {} @@ -1945,6 +2006,7 @@ export interface ResourceRelations { resourceDefinition?: ResourceDefinition | null; resourceStatusChecks?: ConnectionResult; } +export interface ResourceDeclaredCapacityRelations {} export interface ResourceDefinitionRelations { namespace?: Namespace | null; resources?: ConnectionResult; @@ -1959,7 +2021,7 @@ export interface ResourceStatusCheckRelations { } export interface ResourceUsageLogRelations {} export interface ResourceUsageSummaryRelations {} -export interface ResourceUtilizationDailyRelations {} +export interface ResourceUtilizationRelations {} export interface ResourcesHealthRelations {} export interface ResourcesRequirementsStateRelations {} export interface ResourcesResolvedRequirementRelations {} @@ -1973,7 +2035,6 @@ export interface WebhookEventRelations { } // ============ Entity Types With Relations ============ export type DbPresetWithRelations = DbPreset & DbPresetRelations; -export type DeclaredCapacityWithRelations = DeclaredCapacity & DeclaredCapacityRelations; export type FunctionApiBindingWithRelations = FunctionApiBinding & FunctionApiBindingRelations; export type FunctionDefinitionWithRelations = FunctionDefinition & FunctionDefinitionRelations; export type FunctionDeploymentWithRelations = FunctionDeployment & FunctionDeploymentRelations; @@ -1992,6 +2053,8 @@ export type FunctionGraphExecutionOutputWithRelations = FunctionGraphExecutionOu export type FunctionGraphObjectWithRelations = FunctionGraphObject & FunctionGraphObjectRelations; export type FunctionGraphRefWithRelations = FunctionGraphRef & FunctionGraphRefRelations; export type FunctionGraphStoreWithRelations = FunctionGraphStore & FunctionGraphStoreRelations; +export type FunctionInvocationAttemptWithRelations = FunctionInvocationAttempt & + FunctionInvocationAttemptRelations; export type FunctionInvocationWithRelations = FunctionInvocation & FunctionInvocationRelations; export type GetAllTreeNodesRecordWithRelations = GetAllTreeNodesRecord & GetAllTreeNodesRecordRelations; @@ -2004,8 +2067,6 @@ export type InfraStoreWithRelations = InfraStore & InfraStoreRelations; export type IntegrationProviderWithRelations = IntegrationProvider & IntegrationProviderRelations; export type NamespaceWithRelations = Namespace & NamespaceRelations; export type NamespaceEventWithRelations = NamespaceEvent & NamespaceEventRelations; -export type PlatformDeclaredCapacityWithRelations = PlatformDeclaredCapacity & - PlatformDeclaredCapacityRelations; export type PlatformFunctionApiBindingWithRelations = PlatformFunctionApiBinding & PlatformFunctionApiBindingRelations; export type PlatformFunctionDefinitionWithRelations = PlatformFunctionDefinition & @@ -2016,6 +2077,8 @@ export type PlatformFunctionDeploymentEventWithRelations = PlatformFunctionDeplo PlatformFunctionDeploymentEventRelations; export type PlatformFunctionExecutionLogWithRelations = PlatformFunctionExecutionLog & PlatformFunctionExecutionLogRelations; +export type PlatformFunctionInvocationAttemptWithRelations = PlatformFunctionInvocationAttempt & + PlatformFunctionInvocationAttemptRelations; export type PlatformFunctionInvocationWithRelations = PlatformFunctionInvocation & PlatformFunctionInvocationRelations; export type PlatformInfraCommitWithRelations = PlatformInfraCommit & PlatformInfraCommitRelations; @@ -2028,6 +2091,8 @@ export type PlatformNamespaceWithRelations = PlatformNamespace & PlatformNamespa export type PlatformNamespaceEventWithRelations = PlatformNamespaceEvent & PlatformNamespaceEventRelations; export type PlatformResourceWithRelations = PlatformResource & PlatformResourceRelations; +export type PlatformResourceDeclaredCapacityWithRelations = PlatformResourceDeclaredCapacity & + PlatformResourceDeclaredCapacityRelations; export type PlatformResourceDefinitionWithRelations = PlatformResourceDefinition & PlatformResourceDefinitionRelations; export type PlatformResourceEventWithRelations = PlatformResourceEvent & @@ -2040,8 +2105,8 @@ export type PlatformResourceUsageLogWithRelations = PlatformResourceUsageLog & PlatformResourceUsageLogRelations; export type PlatformResourceUsageSummaryWithRelations = PlatformResourceUsageSummary & PlatformResourceUsageSummaryRelations; -export type PlatformResourceUtilizationDailyWithRelations = PlatformResourceUtilizationDaily & - PlatformResourceUtilizationDailyRelations; +export type PlatformResourceUtilizationWithRelations = PlatformResourceUtilization & + PlatformResourceUtilizationRelations; export type PlatformResourcesHealthWithRelations = PlatformResourcesHealth & PlatformResourcesHealthRelations; export type PlatformResourcesRequirementsStateWithRelations = PlatformResourcesRequirementsState & @@ -2053,6 +2118,8 @@ export type PlatformWebhookEndpointWithRelations = PlatformWebhookEndpoint & export type PlatformWebhookEventWithRelations = PlatformWebhookEvent & PlatformWebhookEventRelations; export type ResourceWithRelations = Resource & ResourceRelations; +export type ResourceDeclaredCapacityWithRelations = ResourceDeclaredCapacity & + ResourceDeclaredCapacityRelations; export type ResourceDefinitionWithRelations = ResourceDefinition & ResourceDefinitionRelations; export type ResourceEventWithRelations = ResourceEvent & ResourceEventRelations; export type ResourceInstallationWithRelations = ResourceInstallation & @@ -2061,8 +2128,7 @@ export type ResourceStatusCheckWithRelations = ResourceStatusCheck & ResourceSta export type ResourceUsageLogWithRelations = ResourceUsageLog & ResourceUsageLogRelations; export type ResourceUsageSummaryWithRelations = ResourceUsageSummary & ResourceUsageSummaryRelations; -export type ResourceUtilizationDailyWithRelations = ResourceUtilizationDaily & - ResourceUtilizationDailyRelations; +export type ResourceUtilizationWithRelations = ResourceUtilization & ResourceUtilizationRelations; export type ResourcesHealthWithRelations = ResourcesHealth & ResourcesHealthRelations; export type ResourcesRequirementsStateWithRelations = ResourcesRequirementsState & ResourcesRequirementsStateRelations; @@ -2084,21 +2150,6 @@ export type DbPresetSelect = { storeId?: boolean; updatedAt?: boolean; }; -export type DeclaredCapacitySelect = { - cpuLimitMillicores?: boolean; - cpuRequestMillicores?: boolean; - installationId?: boolean; - isTransient?: boolean; - kind?: boolean; - memoryLimitBytes?: boolean; - memoryRequestBytes?: boolean; - namespaceId?: boolean; - podCountMax?: boolean; - podCountMin?: boolean; - source?: boolean; - sourceId?: boolean; - storageSizeBytes?: boolean; -}; export type FunctionApiBindingSelect = { alias?: boolean; apiId?: boolean; @@ -2340,6 +2391,21 @@ export type FunctionGraphStoreSelect = { name?: boolean; scopeId?: boolean; }; +export type FunctionInvocationAttemptSelect = { + actorId?: boolean; + attempt?: boolean; + createdAt?: boolean; + databaseId?: boolean; + durationMs?: boolean; + error?: boolean; + errorDetail?: boolean; + id?: boolean; + invocationCreatedAt?: boolean; + invocationId?: boolean; + startedAt?: boolean; + success?: boolean; + taskIdentifier?: boolean; +}; export type FunctionInvocationSelect = { actorId?: boolean; apiBindingId?: boolean; @@ -2475,21 +2541,6 @@ export type NamespaceEventSelect = { metadata?: boolean; namespaceId?: boolean; }; -export type PlatformDeclaredCapacitySelect = { - cpuLimitMillicores?: boolean; - cpuRequestMillicores?: boolean; - installationId?: boolean; - isTransient?: boolean; - kind?: boolean; - memoryLimitBytes?: boolean; - memoryRequestBytes?: boolean; - namespaceId?: boolean; - podCountMax?: boolean; - podCountMin?: boolean; - source?: boolean; - sourceId?: boolean; - storageSizeBytes?: boolean; -}; export type PlatformFunctionApiBindingSelect = { alias?: boolean; apiId?: boolean; @@ -2508,6 +2559,7 @@ export type PlatformFunctionApiBindingSelect = { }; export type PlatformFunctionDefinitionSelect = { accessChannels?: boolean; + billable?: boolean; category?: boolean; concurrency?: boolean; cpuLimitMillicores?: boolean; @@ -2543,6 +2595,7 @@ export type PlatformFunctionDefinitionSelect = { runtime?: boolean; scaleMax?: boolean; scaleMin?: boolean; + system?: boolean; targetFunction?: boolean; targetSchema?: boolean; taskIdentifier?: boolean; @@ -2610,6 +2663,20 @@ export type PlatformFunctionExecutionLogSelect = { metadata?: boolean; taskIdentifier?: boolean; }; +export type PlatformFunctionInvocationAttemptSelect = { + actorId?: boolean; + attempt?: boolean; + createdAt?: boolean; + durationMs?: boolean; + error?: boolean; + errorDetail?: boolean; + id?: boolean; + invocationCreatedAt?: boolean; + invocationId?: boolean; + startedAt?: boolean; + success?: boolean; + taskIdentifier?: boolean; +}; export type PlatformFunctionInvocationSelect = { actorId?: boolean; apiBindingId?: boolean; @@ -2770,6 +2837,21 @@ export type PlatformResourceSelect = { orderBy?: PlatformResourceStatusCheckOrderBy[]; }; }; +export type PlatformResourceDeclaredCapacitySelect = { + cpuLimitMillicores?: boolean; + cpuRequestMillicores?: boolean; + installationId?: boolean; + isTransient?: boolean; + kind?: boolean; + memoryLimitBytes?: boolean; + memoryRequestBytes?: boolean; + namespaceId?: boolean; + podCountMax?: boolean; + podCountMin?: boolean; + source?: boolean; + sourceId?: boolean; + storageSizeBytes?: boolean; +}; export type PlatformResourceDefinitionSelect = { annotations?: boolean; createdAt?: boolean; @@ -2865,7 +2947,7 @@ export type PlatformResourceUsageSummarySelect = { runtimeSeconds?: boolean; sampleCount?: boolean; }; -export type PlatformResourceUtilizationDailySelect = { +export type PlatformResourceUtilizationSelect = { avgMemoryBytes?: boolean; cpuLimitMillicores?: boolean; cpuPeakUtilization?: boolean; @@ -3030,6 +3112,21 @@ export type ResourceSelect = { orderBy?: ResourceStatusCheckOrderBy[]; }; }; +export type ResourceDeclaredCapacitySelect = { + cpuLimitMillicores?: boolean; + cpuRequestMillicores?: boolean; + installationId?: boolean; + isTransient?: boolean; + kind?: boolean; + memoryLimitBytes?: boolean; + memoryRequestBytes?: boolean; + namespaceId?: boolean; + podCountMax?: boolean; + podCountMin?: boolean; + source?: boolean; + sourceId?: boolean; + storageSizeBytes?: boolean; +}; export type ResourceDefinitionSelect = { annotations?: boolean; createdAt?: boolean; @@ -3131,7 +3228,7 @@ export type ResourceUsageSummarySelect = { runtimeSeconds?: boolean; sampleCount?: boolean; }; -export type ResourceUtilizationDailySelect = { +export type ResourceUtilizationSelect = { avgMemoryBytes?: boolean; cpuLimitMillicores?: boolean; cpuPeakUtilization?: boolean; @@ -3283,40 +3380,6 @@ export interface DbPresetFilter { /** Filter by the object’s `updatedAt` field. */ updatedAt?: DatetimeFilter; } -export interface DeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: DeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: DeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: DeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} export interface FunctionApiBindingFilter { /** Filter by the object’s `alias` field. */ alias?: StringFilter; @@ -3795,6 +3858,40 @@ export interface FunctionGraphStoreFilter { /** Filter by the object’s `scopeId` field. */ scopeId?: UUIDFilter; } +export interface FunctionInvocationAttemptFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: FunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} export interface FunctionInvocationFilter { /** Filter by the object’s `actorId` field. */ actorId?: UUIDFilter; @@ -4049,40 +4146,6 @@ export interface NamespaceEventFilter { /** Checks for any expressions in this list. */ or?: NamespaceEventFilter[]; } -export interface PlatformDeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: PlatformDeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} export interface PlatformFunctionApiBindingFilter { /** Filter by the object’s `alias` field. */ alias?: StringFilter; @@ -4112,6 +4175,8 @@ export interface PlatformFunctionDefinitionFilter { accessChannels?: StringListFilter; /** Checks for all expressions in this list. */ and?: PlatformFunctionDefinitionFilter[]; + /** Filter by the object’s `billable` field. */ + billable?: BooleanFilter; /** Filter by the object’s `category` field. */ category?: StringFilter; /** Filter by the object’s `concurrency` field. */ @@ -4194,6 +4259,8 @@ export interface PlatformFunctionDefinitionFilter { scaleMax?: IntFilter; /** Filter by the object’s `scaleMin` field. */ scaleMin?: IntFilter; + /** Filter by the object’s `system` field. */ + system?: BooleanFilter; /** Filter by the object’s `targetFunction` field. */ targetFunction?: StringFilter; /** Filter by the object’s `targetSchema` field. */ @@ -4305,20 +4372,52 @@ export interface PlatformFunctionExecutionLogFilter { /** Filter by the object’s `taskIdentifier` field. */ taskIdentifier?: StringFilter; } -export interface PlatformFunctionInvocationFilter { +export interface PlatformFunctionInvocationAttemptFilter { /** Filter by the object’s `actorId` field. */ actorId?: UUIDFilter; /** Checks for all expressions in this list. */ - and?: PlatformFunctionInvocationFilter[]; - /** Filter by the object’s `apiBinding` relation. */ - apiBinding?: PlatformFunctionApiBindingFilter; - /** A related `apiBinding` exists. */ - apiBindingExists?: boolean; - /** Filter by the object’s `apiBindingId` field. */ - apiBindingId?: UUIDFilter; - /** Filter by the object’s `channel` field. */ - channel?: StringFilter; - /** Filter by the object’s `completedAt` field. */ + and?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformFunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} +export interface PlatformFunctionInvocationFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: PlatformFunctionInvocationFilter[]; + /** Filter by the object’s `apiBinding` relation. */ + apiBinding?: PlatformFunctionApiBindingFilter; + /** A related `apiBinding` exists. */ + apiBindingExists?: boolean; + /** Filter by the object’s `apiBindingId` field. */ + apiBindingId?: UUIDFilter; + /** Filter by the object’s `channel` field. */ + channel?: StringFilter; + /** Filter by the object’s `completedAt` field. */ completedAt?: DatetimeFilter; /** Filter by the object’s `createdAt` field. */ createdAt?: DatetimeFilter; @@ -4594,6 +4693,40 @@ export interface PlatformResourceFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +export interface PlatformResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} export interface PlatformResourceDefinitionFilter { /** Checks for all expressions in this list. */ and?: PlatformResourceDefinitionFilter[]; @@ -4776,9 +4909,9 @@ export interface PlatformResourceUsageSummaryFilter { /** Filter by the object’s `sampleCount` field. */ sampleCount?: IntFilter; } -export interface PlatformResourceUtilizationDailyFilter { +export interface PlatformResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: PlatformResourceUtilizationDailyFilter[]; + and?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -4810,9 +4943,9 @@ export interface PlatformResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: PlatformResourceUtilizationDailyFilter; + not?: PlatformResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: PlatformResourceUtilizationDailyFilter[]; + or?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -5090,6 +5223,40 @@ export interface ResourceFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +export interface ResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: ResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} export interface ResourceDefinitionFilter { /** Checks for all expressions in this list. */ and?: ResourceDefinitionFilter[]; @@ -5284,9 +5451,9 @@ export interface ResourceUsageSummaryFilter { /** Filter by the object’s `sampleCount` field. */ sampleCount?: IntFilter; } -export interface ResourceUtilizationDailyFilter { +export interface ResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: ResourceUtilizationDailyFilter[]; + and?: ResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -5318,9 +5485,9 @@ export interface ResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: ResourceUtilizationDailyFilter; + not?: ResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: ResourceUtilizationDailyFilter[]; + or?: ResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -5553,34 +5720,6 @@ export type DbPresetOrderBy = | 'STORE_ID_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC'; -export type DeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; export type FunctionApiBindingOrderBy = | 'ALIAS_ASC' | 'ALIAS_DESC' @@ -5985,6 +6124,36 @@ export type FunctionGraphStoreOrderBy = | 'PRIMARY_KEY_DESC' | 'SCOPE_ID_ASC' | 'SCOPE_ID_DESC'; +export type FunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; export type FunctionInvocationOrderBy = | 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' @@ -6189,34 +6358,6 @@ export type NamespaceEventOrderBy = | 'NATURAL' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC'; -export type PlatformDeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; export type PlatformFunctionApiBindingOrderBy = | 'ALIAS_ASC' | 'ALIAS_DESC' @@ -6234,6 +6375,8 @@ export type PlatformFunctionApiBindingOrderBy = export type PlatformFunctionDefinitionOrderBy = | 'ACCESS_CHANNELS_ASC' | 'ACCESS_CHANNELS_DESC' + | 'BILLABLE_ASC' + | 'BILLABLE_DESC' | 'CATEGORY_ASC' | 'CATEGORY_DESC' | 'CONCURRENCY_ASC' @@ -6307,6 +6450,8 @@ export type PlatformFunctionDefinitionOrderBy = | 'SCALE_MAX_DESC' | 'SCALE_MIN_ASC' | 'SCALE_MIN_DESC' + | 'SYSTEM_ASC' + | 'SYSTEM_DESC' | 'TARGET_FUNCTION_ASC' | 'TARGET_FUNCTION_DESC' | 'TARGET_SCHEMA_ASC' @@ -6403,6 +6548,34 @@ export type PlatformFunctionExecutionLogOrderBy = | 'PRIMARY_KEY_DESC' | 'TASK_IDENTIFIER_ASC' | 'TASK_IDENTIFIER_DESC'; +export type PlatformFunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; export type PlatformFunctionInvocationOrderBy = | 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' @@ -6627,6 +6800,34 @@ export type PlatformResourceOrderBy = | 'UPDATED_AT_DESC' | 'UPDATED_BY_ASC' | 'UPDATED_BY_DESC'; +export type PlatformResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; export type PlatformResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' @@ -6775,7 +6976,7 @@ export type PlatformResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -export type PlatformResourceUtilizationDailyOrderBy = +export type PlatformResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -7037,6 +7238,34 @@ export type ResourceOrderBy = | 'UPDATED_AT_DESC' | 'UPDATED_BY_ASC' | 'UPDATED_BY_DESC'; +export type ResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; export type ResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' @@ -7197,7 +7426,7 @@ export type ResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -export type ResourceUtilizationDailyOrderBy = +export type ResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -7407,72 +7636,30 @@ export interface CreateDbPresetInput { dbPreset: { active?: boolean; commitId?: string; - definition: Record; - description?: string; - label?: string; - modulesHash?: string; - slug: string; - storeId?: string; - }; -} -export interface DbPresetPatch { - active?: boolean | null; - commitId?: string | null; - definition?: Record | null; - description?: string | null; - label?: string | null; - modulesHash?: string | null; - slug?: string | null; - storeId?: string | null; -} -export interface UpdateDbPresetInput { - clientMutationId?: string; - id: string; - dbPresetPatch: DbPresetPatch; -} -export interface DeleteDbPresetInput { - clientMutationId?: string; - id: string; -} -export interface CreateDeclaredCapacityInput { - clientMutationId?: string; - declaredCapacity: { - cpuLimitMillicores?: string; - cpuRequestMillicores?: string; - installationId: string; - isTransient?: boolean; - kind?: string; - memoryLimitBytes?: string; - memoryRequestBytes?: string; - namespaceId: string; - podCountMax?: number; - podCountMin?: number; - source?: string; - sourceId: string; - storageSizeBytes?: string; - }; -} -export interface DeclaredCapacityPatch { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; + definition: Record; + description?: string; + label?: string; + modulesHash?: string; + slug: string; + storeId?: string; + }; +} +export interface DbPresetPatch { + active?: boolean | null; + commitId?: string | null; + definition?: Record | null; + description?: string | null; + label?: string | null; + modulesHash?: string | null; + slug?: string | null; + storeId?: string | null; } -export interface UpdateDeclaredCapacityInput { +export interface UpdateDbPresetInput { clientMutationId?: string; id: string; - declaredCapacityPatch: DeclaredCapacityPatch; + dbPresetPatch: DbPresetPatch; } -export interface DeleteDeclaredCapacityInput { +export interface DeleteDbPresetInput { clientMutationId?: string; id: string; } @@ -7536,7 +7723,6 @@ export interface CreateFunctionDefinitionInput { scaleMin?: number; targetFunction?: string; targetSchema?: string; - taskIdentifier: string; timeoutSeconds?: number; volatile?: boolean; }; @@ -7575,7 +7761,6 @@ export interface FunctionDefinitionPatch { scaleMin?: number | null; targetFunction?: string | null; targetSchema?: string | null; - taskIdentifier?: string | null; timeoutSeconds?: number | null; volatile?: boolean | null; } @@ -7978,6 +8163,44 @@ export interface DeleteFunctionGraphStoreInput { clientMutationId?: string; id: string; } +export interface CreateFunctionInvocationAttemptInput { + clientMutationId?: string; + functionInvocationAttempt: { + actorId?: string; + attempt: number; + databaseId: string; + durationMs?: number; + error?: string; + errorDetail?: Record; + invocationCreatedAt: string; + invocationId: string; + startedAt?: string; + success: boolean; + taskIdentifier: string; + }; +} +export interface FunctionInvocationAttemptPatch { + actorId?: string | null; + attempt?: number | null; + databaseId?: string | null; + durationMs?: number | null; + error?: string | null; + errorDetail?: Record | null; + invocationCreatedAt?: string | null; + invocationId?: string | null; + startedAt?: string | null; + success?: boolean | null; + taskIdentifier?: string | null; +} +export interface UpdateFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; +} +export interface DeleteFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; +} export interface CreateFunctionInvocationInput { clientMutationId?: string; functionInvocation: { @@ -8271,48 +8494,6 @@ export interface DeleteNamespaceEventInput { clientMutationId?: string; id: string; } -export interface CreatePlatformDeclaredCapacityInput { - clientMutationId?: string; - platformDeclaredCapacity: { - cpuLimitMillicores?: string; - cpuRequestMillicores?: string; - installationId: string; - isTransient?: boolean; - kind?: string; - memoryLimitBytes?: string; - memoryRequestBytes?: string; - namespaceId: string; - podCountMax?: number; - podCountMin?: number; - source?: string; - sourceId: string; - storageSizeBytes?: string; - }; -} -export interface PlatformDeclaredCapacityPatch { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} -export interface UpdatePlatformDeclaredCapacityInput { - clientMutationId?: string; - id: string; - platformDeclaredCapacityPatch: PlatformDeclaredCapacityPatch; -} -export interface DeletePlatformDeclaredCapacityInput { - clientMutationId?: string; - id: string; -} export interface CreatePlatformFunctionApiBindingInput { clientMutationId?: string; platformFunctionApiBinding: { @@ -8341,6 +8522,7 @@ export interface CreatePlatformFunctionDefinitionInput { clientMutationId?: string; platformFunctionDefinition: { accessChannels?: string[]; + billable?: boolean; category: string; concurrency?: number; description?: string; @@ -8370,15 +8552,16 @@ export interface CreatePlatformFunctionDefinitionInput { runtime?: string; scaleMax?: number; scaleMin?: number; + system?: boolean; targetFunction?: string; targetSchema?: string; - taskIdentifier: string; timeoutSeconds?: number; volatile?: boolean; }; } export interface PlatformFunctionDefinitionPatch { accessChannels?: string[] | null; + billable?: boolean | null; category?: string | null; concurrency?: number | null; description?: string | null; @@ -8408,9 +8591,9 @@ export interface PlatformFunctionDefinitionPatch { runtime?: string | null; scaleMax?: number | null; scaleMin?: number | null; + system?: boolean | null; targetFunction?: string | null; targetSchema?: string | null; - taskIdentifier?: string | null; timeoutSeconds?: number | null; volatile?: boolean | null; } @@ -8529,6 +8712,42 @@ export interface DeletePlatformFunctionExecutionLogInput { clientMutationId?: string; id: string; } +export interface CreatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + platformFunctionInvocationAttempt: { + actorId?: string; + attempt: number; + durationMs?: number; + error?: string; + errorDetail?: Record; + invocationCreatedAt: string; + invocationId: string; + startedAt?: string; + success: boolean; + taskIdentifier: string; + }; +} +export interface PlatformFunctionInvocationAttemptPatch { + actorId?: string | null; + attempt?: number | null; + durationMs?: number | null; + error?: string | null; + errorDetail?: Record | null; + invocationCreatedAt?: string | null; + invocationId?: string | null; + startedAt?: string | null; + success?: boolean | null; + taskIdentifier?: string | null; +} +export interface UpdatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; +} +export interface DeletePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; +} export interface CreatePlatformFunctionInvocationInput { clientMutationId?: string; platformFunctionInvocation: { @@ -8815,6 +9034,48 @@ export interface DeletePlatformResourceInput { clientMutationId?: string; id: string; } +export interface CreatePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + platformResourceDeclaredCapacity: { + cpuLimitMillicores?: string; + cpuRequestMillicores?: string; + installationId: string; + isTransient?: boolean; + kind?: string; + memoryLimitBytes?: string; + memoryRequestBytes?: string; + namespaceId: string; + podCountMax?: number; + podCountMin?: number; + source?: string; + sourceId: string; + storageSizeBytes?: string; + }; +} +export interface PlatformResourceDeclaredCapacityPatch { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} +export interface UpdatePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; + platformResourceDeclaredCapacityPatch: PlatformResourceDeclaredCapacityPatch; +} +export interface DeletePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; +} export interface CreatePlatformResourceDefinitionInput { clientMutationId?: string; platformResourceDefinition: { @@ -9013,9 +9274,9 @@ export interface DeletePlatformResourceUsageSummaryInput { clientMutationId?: string; id: string; } -export interface CreatePlatformResourceUtilizationDailyInput { +export interface CreatePlatformResourceUtilizationInput { clientMutationId?: string; - platformResourceUtilizationDaily: { + platformResourceUtilization: { avgMemoryBytes?: string; cpuLimitMillicores?: string; cpuPeakUtilization?: string; @@ -9037,7 +9298,7 @@ export interface CreatePlatformResourceUtilizationDailyInput { sampleCount?: number; }; } -export interface PlatformResourceUtilizationDailyPatch { +export interface PlatformResourceUtilizationPatch { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -9058,12 +9319,12 @@ export interface PlatformResourceUtilizationDailyPatch { runtimeSeconds?: string | null; sampleCount?: number | null; } -export interface UpdatePlatformResourceUtilizationDailyInput { +export interface UpdatePlatformResourceUtilizationInput { clientMutationId?: string; id: string; - platformResourceUtilizationDailyPatch: PlatformResourceUtilizationDailyPatch; + platformResourceUtilizationPatch: PlatformResourceUtilizationPatch; } -export interface DeletePlatformResourceUtilizationDailyInput { +export interface DeletePlatformResourceUtilizationInput { clientMutationId?: string; id: string; } @@ -9329,6 +9590,48 @@ export interface DeleteResourceInput { clientMutationId?: string; id: string; } +export interface CreateResourceDeclaredCapacityInput { + clientMutationId?: string; + resourceDeclaredCapacity: { + cpuLimitMillicores?: string; + cpuRequestMillicores?: string; + installationId: string; + isTransient?: boolean; + kind?: string; + memoryLimitBytes?: string; + memoryRequestBytes?: string; + namespaceId: string; + podCountMax?: number; + podCountMin?: number; + source?: string; + sourceId: string; + storageSizeBytes?: string; + }; +} +export interface ResourceDeclaredCapacityPatch { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} +export interface UpdateResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; + resourceDeclaredCapacityPatch: ResourceDeclaredCapacityPatch; +} +export interface DeleteResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; +} export interface CreateResourceDefinitionInput { clientMutationId?: string; resourceDefinition: { @@ -9539,9 +9842,9 @@ export interface DeleteResourceUsageSummaryInput { clientMutationId?: string; id: string; } -export interface CreateResourceUtilizationDailyInput { +export interface CreateResourceUtilizationInput { clientMutationId?: string; - resourceUtilizationDaily: { + resourceUtilization: { avgMemoryBytes?: string; cpuLimitMillicores?: string; cpuPeakUtilization?: string; @@ -9563,7 +9866,7 @@ export interface CreateResourceUtilizationDailyInput { sampleCount?: number; }; } -export interface ResourceUtilizationDailyPatch { +export interface ResourceUtilizationPatch { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -9584,12 +9887,12 @@ export interface ResourceUtilizationDailyPatch { runtimeSeconds?: string | null; sampleCount?: number | null; } -export interface UpdateResourceUtilizationDailyInput { +export interface UpdateResourceUtilizationInput { clientMutationId?: string; id: string; - resourceUtilizationDailyPatch: ResourceUtilizationDailyPatch; + resourceUtilizationPatch: ResourceUtilizationPatch; } -export interface DeleteResourceUtilizationDailyInput { +export interface DeleteResourceUtilizationInput { clientMutationId?: string; id: string; } @@ -9986,24 +10289,24 @@ export interface PlatformInfraSetDataAtPathInput { } export interface PlatformResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: Record; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: Record; + slug?: string; } export interface PlatformResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: Record; + newParams?: Record; + targetInstallationId?: string; } export interface ProvisionBucketInput { /** The logical bucket key (e.g., "public", "private") */ @@ -10016,24 +10319,24 @@ export interface ProvisionBucketInput { } export interface ResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: Record; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: Record; + slug?: string; } export interface ResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: Record; + newParams?: Record; + targetInstallationId?: string; } export interface SaveGraphInput { clientMutationId?: string; @@ -10483,8 +10786,6 @@ export interface FunctionDefinitionInput { targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -10756,6 +11057,35 @@ export interface FunctionGraphStoreInput { /** Opaque store partition key for the global tier */ scopeId: string; } +/** An input for mutations affecting `FunctionInvocationAttempt` */ +export interface FunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Database that owns this resource (database-scoped isolation) */ + databaseId: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} /** An input for mutations affecting `FunctionInvocation` */ export interface FunctionInvocationInput { /** Who triggered the invocation (NULL for system/cron) */ @@ -10774,7 +11104,7 @@ export interface FunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -10794,7 +11124,7 @@ export interface FunctionInvocationInput { result?: Record; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -10946,6 +11276,8 @@ export interface PlatformFunctionApiBindingInput { export interface PlatformFunctionDefinitionInput { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[]; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean; /** Function task category (e.g. email, embed, chunk, custom) */ category: string; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -11006,12 +11338,12 @@ export interface PlatformFunctionDefinitionInput { scaleMax?: number; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -11096,6 +11428,33 @@ export interface PlatformFunctionExecutionLogInput { /** Function routing key (NULL for generic job logs) */ taskIdentifier?: string; } +/** An input for mutations affecting `PlatformFunctionInvocationAttempt` */ +export interface PlatformFunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} /** An input for mutations affecting `PlatformFunctionInvocation` */ export interface PlatformFunctionInvocationInput { /** Who triggered the invocation (NULL for system/cron) */ @@ -11112,7 +11471,7 @@ export interface PlatformFunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -11132,7 +11491,7 @@ export interface PlatformFunctionInvocationInput { result?: Record; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -11253,7 +11612,7 @@ export interface PlatformResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: Record; @@ -11295,7 +11654,7 @@ export interface PlatformResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: Record; @@ -11409,7 +11768,7 @@ export interface PlatformResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** An input for mutations affecting `PlatformResourceUsageSummary` */ @@ -11496,7 +11855,7 @@ export interface ResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: Record; @@ -11540,7 +11899,7 @@ export interface ResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: Record; @@ -11643,7 +12002,7 @@ export interface ResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** An input for mutations affecting `ResourceUsageSummary` */ @@ -11925,6 +12284,8 @@ export interface PlatformFunctionDefinitionFilter { accessChannels?: StringListFilter; /** Checks for all expressions in this list. */ and?: PlatformFunctionDefinitionFilter[]; + /** Filter by the object’s `billable` field. */ + billable?: BooleanFilter; /** Filter by the object’s `category` field. */ category?: StringFilter; /** Filter by the object’s `concurrency` field. */ @@ -12007,6 +12368,8 @@ export interface PlatformFunctionDefinitionFilter { scaleMax?: IntFilter; /** Filter by the object’s `scaleMin` field. */ scaleMin?: IntFilter; + /** Filter by the object’s `system` field. */ + system?: BooleanFilter; /** Filter by the object’s `targetFunction` field. */ targetFunction?: StringFilter; /** Filter by the object’s `targetSchema` field. */ @@ -14069,6 +14432,51 @@ export type DeleteFunctionGraphStorePayloadSelect = { select: FunctionGraphStoreEdgeSelect; }; }; +export interface CreateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was created by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type CreateFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; +export interface UpdateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was updated by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type UpdateFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; +export interface DeleteFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was deleted by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type DeleteFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; export interface CreateFunctionInvocationPayload { clientMutationId?: string | null; /** The `FunctionInvocation` that was created by this mutation. */ @@ -14654,6 +15062,51 @@ export type DeletePlatformFunctionExecutionLogPayloadSelect = { select: PlatformFunctionExecutionLogEdgeSelect; }; }; +export interface CreatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was created by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type CreatePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; +export interface UpdatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was updated by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type UpdatePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; +export interface DeletePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was deleted by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type DeletePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; export interface CreatePlatformFunctionInvocationPayload { clientMutationId?: string | null; /** The `PlatformFunctionInvocation` that was created by this mutation. */ @@ -15947,6 +16400,18 @@ export type FunctionGraphStoreEdgeSelect = { select: FunctionGraphStoreSelect; }; }; +/** A `FunctionInvocationAttempt` edge in the connection. */ +export interface FunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `FunctionInvocationAttempt` at the end of the edge. */ + node?: FunctionInvocationAttempt | null; +} +export type FunctionInvocationAttemptEdgeSelect = { + cursor?: boolean; + node?: { + select: FunctionInvocationAttemptSelect; + }; +}; /** A `FunctionInvocation` edge in the connection. */ export interface FunctionInvocationEdge { cursor?: string | null; @@ -16103,6 +16568,18 @@ export type PlatformFunctionExecutionLogEdgeSelect = { select: PlatformFunctionExecutionLogSelect; }; }; +/** A `PlatformFunctionInvocationAttempt` edge in the connection. */ +export interface PlatformFunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `PlatformFunctionInvocationAttempt` at the end of the edge. */ + node?: PlatformFunctionInvocationAttempt | null; +} +export type PlatformFunctionInvocationAttemptEdgeSelect = { + cursor?: boolean; + node?: { + select: PlatformFunctionInvocationAttemptSelect; + }; +}; /** A `PlatformFunctionInvocation` edge in the connection. */ export interface PlatformFunctionInvocationEdge { cursor?: string | null; diff --git a/sdk/constructive-react/src/compute/orm/models/declaredCapacity.ts b/sdk/constructive-react/src/compute/orm/models/declaredCapacity.ts deleted file mode 100644 index 69304243f..000000000 --- a/sdk/constructive-react/src/compute/orm/models/declaredCapacity.ts +++ /dev/null @@ -1,134 +0,0 @@ -/** - * DeclaredCapacity model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - DeclaredCapacity, - DeclaredCapacityWithRelations, - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy, - CreateDeclaredCapacityInput, - UpdateDeclaredCapacityInput, - DeclaredCapacityPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class DeclaredCapacityModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - declaredCapacities: ConnectionResult>; - }> { - const { document, variables } = buildFindManyDocument( - 'DeclaredCapacity', - 'declaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'DeclaredCapacityFilter', - 'DeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'DeclaredCapacity', - fieldName: 'declaredCapacities', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - declaredCapacity: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'DeclaredCapacity', - 'declaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'DeclaredCapacityFilter', - 'DeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'DeclaredCapacity', - fieldName: 'declaredCapacity', - document, - variables, - transform: (data: { - declaredCapacities?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - declaredCapacity: data.declaredCapacities?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createDeclaredCapacity: { - declaredCapacity: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'DeclaredCapacity', - 'createDeclaredCapacity', - 'declaredCapacity', - args.select, - args.data, - 'CreateDeclaredCapacityInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'DeclaredCapacity', - fieldName: 'createDeclaredCapacity', - document, - variables, - }); - } -} diff --git a/sdk/constructive-react/src/compute/orm/models/functionInvocationAttempt.ts b/sdk/constructive-react/src/compute/orm/models/functionInvocationAttempt.ts new file mode 100644 index 000000000..710ddec0b --- /dev/null +++ b/sdk/constructive-react/src/compute/orm/models/functionInvocationAttempt.ts @@ -0,0 +1,252 @@ +/** + * FunctionInvocationAttempt model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + FunctionInvocationAttempt, + FunctionInvocationAttemptWithRelations, + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy, + CreateFunctionInvocationAttemptInput, + UpdateFunctionInvocationAttemptInput, + FunctionInvocationAttemptPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class FunctionInvocationAttemptModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempts', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempt: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempt', + document, + variables, + transform: (data: { + functionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + functionInvocationAttempt: data.functionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempt: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempt', + document, + variables, + transform: (data: { + functionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + functionInvocationAttempt: data.functionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'FunctionInvocationAttempt', + 'createFunctionInvocationAttempt', + 'functionInvocationAttempt', + args.select, + args.data, + 'CreateFunctionInvocationAttemptInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'createFunctionInvocationAttempt', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + createdAt: string; + }, + FunctionInvocationAttemptPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'FunctionInvocationAttempt', + 'updateFunctionInvocationAttempt', + 'functionInvocationAttempt', + args.select, + args.where.id, + args.data, + 'UpdateFunctionInvocationAttemptInput', + 'id', + 'functionInvocationAttemptPatch', + connectionFieldsMap, + { + createdAt: args.where.createdAt, + } + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'updateFunctionInvocationAttempt', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + createdAt: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'FunctionInvocationAttempt', + 'deleteFunctionInvocationAttempt', + 'functionInvocationAttempt', + { + id: args.where.id, + createdAt: args.where.createdAt, + }, + 'DeleteFunctionInvocationAttemptInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'deleteFunctionInvocationAttempt', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/compute/orm/models/index.ts b/sdk/constructive-react/src/compute/orm/models/index.ts index 3f21b469c..c06f5f3db 100644 --- a/sdk/constructive-react/src/compute/orm/models/index.ts +++ b/sdk/constructive-react/src/compute/orm/models/index.ts @@ -4,7 +4,6 @@ * DO NOT EDIT - changes will be overwritten */ export { DbPresetModel } from './dbPreset'; -export { DeclaredCapacityModel } from './declaredCapacity'; export { FunctionApiBindingModel } from './functionApiBinding'; export { FunctionDefinitionModel } from './functionDefinition'; export { FunctionDeploymentModel } from './functionDeployment'; @@ -18,6 +17,7 @@ export { FunctionGraphExecutionOutputModel } from './functionGraphExecutionOutpu export { FunctionGraphObjectModel } from './functionGraphObject'; export { FunctionGraphRefModel } from './functionGraphRef'; export { FunctionGraphStoreModel } from './functionGraphStore'; +export { FunctionInvocationAttemptModel } from './functionInvocationAttempt'; export { FunctionInvocationModel } from './functionInvocation'; export { GetAllTreeNodesRecordModel } from './getAllTreeNodesRecord'; export { InfraCommitModel } from './infraCommit'; @@ -28,12 +28,12 @@ export { InfraStoreModel } from './infraStore'; export { IntegrationProviderModel } from './integrationProvider'; export { NamespaceModel } from './namespace'; export { NamespaceEventModel } from './namespaceEvent'; -export { PlatformDeclaredCapacityModel } from './platformDeclaredCapacity'; export { PlatformFunctionApiBindingModel } from './platformFunctionApiBinding'; export { PlatformFunctionDefinitionModel } from './platformFunctionDefinition'; export { PlatformFunctionDeploymentModel } from './platformFunctionDeployment'; export { PlatformFunctionDeploymentEventModel } from './platformFunctionDeploymentEvent'; export { PlatformFunctionExecutionLogModel } from './platformFunctionExecutionLog'; +export { PlatformFunctionInvocationAttemptModel } from './platformFunctionInvocationAttempt'; export { PlatformFunctionInvocationModel } from './platformFunctionInvocation'; export { PlatformInfraCommitModel } from './platformInfraCommit'; export { PlatformInfraGetAllTreeNodesRecordModel } from './platformInfraGetAllTreeNodesRecord'; @@ -43,26 +43,28 @@ export { PlatformInfraStoreModel } from './platformInfraStore'; export { PlatformNamespaceModel } from './platformNamespace'; export { PlatformNamespaceEventModel } from './platformNamespaceEvent'; export { PlatformResourceModel } from './platformResource'; +export { PlatformResourceDeclaredCapacityModel } from './platformResourceDeclaredCapacity'; export { PlatformResourceDefinitionModel } from './platformResourceDefinition'; export { PlatformResourceEventModel } from './platformResourceEvent'; export { PlatformResourceInstallationModel } from './platformResourceInstallation'; export { PlatformResourceStatusCheckModel } from './platformResourceStatusCheck'; export { PlatformResourceUsageLogModel } from './platformResourceUsageLog'; export { PlatformResourceUsageSummaryModel } from './platformResourceUsageSummary'; -export { PlatformResourceUtilizationDailyModel } from './platformResourceUtilizationDaily'; +export { PlatformResourceUtilizationModel } from './platformResourceUtilization'; export { PlatformResourcesHealthModel } from './platformResourcesHealth'; export { PlatformResourcesRequirementsStateModel } from './platformResourcesRequirementsState'; export { PlatformResourcesResolvedRequirementModel } from './platformResourcesResolvedRequirement'; export { PlatformWebhookEndpointModel } from './platformWebhookEndpoint'; export { PlatformWebhookEventModel } from './platformWebhookEvent'; export { ResourceModel } from './resource'; +export { ResourceDeclaredCapacityModel } from './resourceDeclaredCapacity'; export { ResourceDefinitionModel } from './resourceDefinition'; export { ResourceEventModel } from './resourceEvent'; export { ResourceInstallationModel } from './resourceInstallation'; export { ResourceStatusCheckModel } from './resourceStatusCheck'; export { ResourceUsageLogModel } from './resourceUsageLog'; export { ResourceUsageSummaryModel } from './resourceUsageSummary'; -export { ResourceUtilizationDailyModel } from './resourceUtilizationDaily'; +export { ResourceUtilizationModel } from './resourceUtilization'; export { ResourcesHealthModel } from './resourcesHealth'; export { ResourcesRequirementsStateModel } from './resourcesRequirementsState'; export { ResourcesResolvedRequirementModel } from './resourcesResolvedRequirement'; diff --git a/sdk/constructive-react/src/compute/orm/models/platformDeclaredCapacity.ts b/sdk/constructive-react/src/compute/orm/models/platformDeclaredCapacity.ts deleted file mode 100644 index 0edf75c4d..000000000 --- a/sdk/constructive-react/src/compute/orm/models/platformDeclaredCapacity.ts +++ /dev/null @@ -1,136 +0,0 @@ -/** - * PlatformDeclaredCapacity model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - PlatformDeclaredCapacity, - PlatformDeclaredCapacityWithRelations, - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy, - CreatePlatformDeclaredCapacityInput, - UpdatePlatformDeclaredCapacityInput, - PlatformDeclaredCapacityPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class PlatformDeclaredCapacityModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformDeclaredCapacities: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'PlatformDeclaredCapacity', - 'platformDeclaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'PlatformDeclaredCapacityFilter', - 'PlatformDeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'platformDeclaredCapacities', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformDeclaredCapacity: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'PlatformDeclaredCapacity', - 'platformDeclaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'PlatformDeclaredCapacityFilter', - 'PlatformDeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'platformDeclaredCapacity', - document, - variables, - transform: (data: { - platformDeclaredCapacities?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - platformDeclaredCapacity: data.platformDeclaredCapacities?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createPlatformDeclaredCapacity: { - platformDeclaredCapacity: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'PlatformDeclaredCapacity', - 'createPlatformDeclaredCapacity', - 'platformDeclaredCapacity', - args.select, - args.data, - 'CreatePlatformDeclaredCapacityInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'createPlatformDeclaredCapacity', - document, - variables, - }); - } -} diff --git a/sdk/constructive-react/src/compute/orm/models/platformFunctionInvocationAttempt.ts b/sdk/constructive-react/src/compute/orm/models/platformFunctionInvocationAttempt.ts new file mode 100644 index 000000000..a1db7bbe0 --- /dev/null +++ b/sdk/constructive-react/src/compute/orm/models/platformFunctionInvocationAttempt.ts @@ -0,0 +1,280 @@ +/** + * PlatformFunctionInvocationAttempt model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformFunctionInvocationAttempt, + PlatformFunctionInvocationAttemptWithRelations, + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy, + CreatePlatformFunctionInvocationAttemptInput, + UpdatePlatformFunctionInvocationAttemptInput, + PlatformFunctionInvocationAttemptPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformFunctionInvocationAttemptModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempts', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempt', + document, + variables, + transform: (data: { + platformFunctionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformFunctionInvocationAttempt: + data.platformFunctionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempt', + document, + variables, + transform: (data: { + platformFunctionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformFunctionInvocationAttempt: + data.platformFunctionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs< + S, + CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt'] + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformFunctionInvocationAttempt', + 'createPlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + args.select, + args.data, + 'CreatePlatformFunctionInvocationAttemptInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'createPlatformFunctionInvocationAttempt', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + createdAt: string; + }, + PlatformFunctionInvocationAttemptPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updatePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'PlatformFunctionInvocationAttempt', + 'updatePlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + args.select, + args.where.id, + args.data, + 'UpdatePlatformFunctionInvocationAttemptInput', + 'id', + 'platformFunctionInvocationAttemptPatch', + connectionFieldsMap, + { + createdAt: args.where.createdAt, + } + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'updatePlatformFunctionInvocationAttempt', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + createdAt: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deletePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'PlatformFunctionInvocationAttempt', + 'deletePlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + { + id: args.where.id, + createdAt: args.where.createdAt, + }, + 'DeletePlatformFunctionInvocationAttemptInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'deletePlatformFunctionInvocationAttempt', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/compute/orm/models/platformResourceDeclaredCapacity.ts b/sdk/constructive-react/src/compute/orm/models/platformResourceDeclaredCapacity.ts new file mode 100644 index 000000000..66a88f859 --- /dev/null +++ b/sdk/constructive-react/src/compute/orm/models/platformResourceDeclaredCapacity.ts @@ -0,0 +1,154 @@ +/** + * PlatformResourceDeclaredCapacity model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformResourceDeclaredCapacity, + PlatformResourceDeclaredCapacityWithRelations, + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy, + CreatePlatformResourceDeclaredCapacityInput, + UpdatePlatformResourceDeclaredCapacityInput, + PlatformResourceDeclaredCapacityPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformResourceDeclaredCapacityModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformResourceDeclaredCapacityFilter', + 'PlatformResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'platformResourceDeclaredCapacities', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformResourceDeclaredCapacityFilter', + 'PlatformResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'platformResourceDeclaredCapacity', + document, + variables, + transform: (data: { + platformResourceDeclaredCapacities?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformResourceDeclaredCapacity: + data.platformResourceDeclaredCapacities?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs< + S, + CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity'] + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformResourceDeclaredCapacity: { + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + >; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformResourceDeclaredCapacity', + 'createPlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacity', + args.select, + args.data, + 'CreatePlatformResourceDeclaredCapacityInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'createPlatformResourceDeclaredCapacity', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/compute/orm/models/platformResourceUtilization.ts b/sdk/constructive-react/src/compute/orm/models/platformResourceUtilization.ts new file mode 100644 index 000000000..040d38000 --- /dev/null +++ b/sdk/constructive-react/src/compute/orm/models/platformResourceUtilization.ts @@ -0,0 +1,143 @@ +/** + * PlatformResourceUtilization model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformResourceUtilization, + PlatformResourceUtilizationWithRelations, + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy, + CreatePlatformResourceUtilizationInput, + UpdatePlatformResourceUtilizationInput, + PlatformResourceUtilizationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformResourceUtilizationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceUtilizations: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformResourceUtilization', + 'platformResourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformResourceUtilizationFilter', + 'PlatformResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceUtilization', + fieldName: 'platformResourceUtilizations', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceUtilization: InferSelectResult< + PlatformResourceUtilizationWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformResourceUtilization', + 'platformResourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformResourceUtilizationFilter', + 'PlatformResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceUtilization', + fieldName: 'platformResourceUtilization', + document, + variables, + transform: (data: { + platformResourceUtilizations?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformResourceUtilization: data.platformResourceUtilizations?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformResourceUtilization: { + platformResourceUtilization: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformResourceUtilization', + 'createPlatformResourceUtilization', + 'platformResourceUtilization', + args.select, + args.data, + 'CreatePlatformResourceUtilizationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformResourceUtilization', + fieldName: 'createPlatformResourceUtilization', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/compute/orm/models/platformResourceUtilizationDaily.ts b/sdk/constructive-react/src/compute/orm/models/platformResourceUtilizationDaily.ts deleted file mode 100644 index e142f1f50..000000000 --- a/sdk/constructive-react/src/compute/orm/models/platformResourceUtilizationDaily.ts +++ /dev/null @@ -1,154 +0,0 @@ -/** - * PlatformResourceUtilizationDaily model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - PlatformResourceUtilizationDaily, - PlatformResourceUtilizationDailyWithRelations, - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy, - CreatePlatformResourceUtilizationDailyInput, - UpdatePlatformResourceUtilizationDailyInput, - PlatformResourceUtilizationDailyPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class PlatformResourceUtilizationDailyModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformResourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'PlatformResourceUtilizationDaily', - 'platformResourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'PlatformResourceUtilizationDailyFilter', - 'PlatformResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'platformResourceUtilizationDailies', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - > | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'PlatformResourceUtilizationDaily', - 'platformResourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'PlatformResourceUtilizationDailyFilter', - 'PlatformResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'platformResourceUtilizationDaily', - document, - variables, - transform: (data: { - platformResourceUtilizationDailies?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - platformResourceUtilizationDaily: - data.platformResourceUtilizationDailies?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs< - S, - CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily'] - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createPlatformResourceUtilizationDaily: { - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - >; - }; - }> { - const { document, variables } = buildCreateDocument( - 'PlatformResourceUtilizationDaily', - 'createPlatformResourceUtilizationDaily', - 'platformResourceUtilizationDaily', - args.select, - args.data, - 'CreatePlatformResourceUtilizationDailyInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'createPlatformResourceUtilizationDaily', - document, - variables, - }); - } -} diff --git a/sdk/constructive-react/src/compute/orm/models/resourceDeclaredCapacity.ts b/sdk/constructive-react/src/compute/orm/models/resourceDeclaredCapacity.ts new file mode 100644 index 000000000..6340979a9 --- /dev/null +++ b/sdk/constructive-react/src/compute/orm/models/resourceDeclaredCapacity.ts @@ -0,0 +1,136 @@ +/** + * ResourceDeclaredCapacity model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ResourceDeclaredCapacity, + ResourceDeclaredCapacityWithRelations, + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy, + CreateResourceDeclaredCapacityInput, + UpdateResourceDeclaredCapacityInput, + ResourceDeclaredCapacityPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ResourceDeclaredCapacityModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'ResourceDeclaredCapacity', + 'resourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ResourceDeclaredCapacityFilter', + 'ResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'resourceDeclaredCapacities', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceDeclaredCapacity: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ResourceDeclaredCapacity', + 'resourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ResourceDeclaredCapacityFilter', + 'ResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'resourceDeclaredCapacity', + document, + variables, + transform: (data: { + resourceDeclaredCapacities?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + resourceDeclaredCapacity: data.resourceDeclaredCapacities?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createResourceDeclaredCapacity: { + resourceDeclaredCapacity: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ResourceDeclaredCapacity', + 'createResourceDeclaredCapacity', + 'resourceDeclaredCapacity', + args.select, + args.data, + 'CreateResourceDeclaredCapacityInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'createResourceDeclaredCapacity', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/compute/orm/models/resourceUtilization.ts b/sdk/constructive-react/src/compute/orm/models/resourceUtilization.ts new file mode 100644 index 000000000..362048600 --- /dev/null +++ b/sdk/constructive-react/src/compute/orm/models/resourceUtilization.ts @@ -0,0 +1,134 @@ +/** + * ResourceUtilization model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ResourceUtilization, + ResourceUtilizationWithRelations, + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy, + CreateResourceUtilizationInput, + UpdateResourceUtilizationInput, + ResourceUtilizationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ResourceUtilizationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceUtilizations: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'ResourceUtilization', + 'resourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ResourceUtilizationFilter', + 'ResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceUtilization', + fieldName: 'resourceUtilizations', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceUtilization: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ResourceUtilization', + 'resourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ResourceUtilizationFilter', + 'ResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceUtilization', + fieldName: 'resourceUtilization', + document, + variables, + transform: (data: { + resourceUtilizations?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + resourceUtilization: data.resourceUtilizations?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createResourceUtilization: { + resourceUtilization: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ResourceUtilization', + 'createResourceUtilization', + 'resourceUtilization', + args.select, + args.data, + 'CreateResourceUtilizationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ResourceUtilization', + fieldName: 'createResourceUtilization', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/compute/orm/models/resourceUtilizationDaily.ts b/sdk/constructive-react/src/compute/orm/models/resourceUtilizationDaily.ts deleted file mode 100644 index 8307b4adc..000000000 --- a/sdk/constructive-react/src/compute/orm/models/resourceUtilizationDaily.ts +++ /dev/null @@ -1,136 +0,0 @@ -/** - * ResourceUtilizationDaily model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - ResourceUtilizationDaily, - ResourceUtilizationDailyWithRelations, - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy, - CreateResourceUtilizationDailyInput, - UpdateResourceUtilizationDailyInput, - ResourceUtilizationDailyPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class ResourceUtilizationDailyModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - resourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'ResourceUtilizationDaily', - 'resourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'ResourceUtilizationDailyFilter', - 'ResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'ResourceUtilizationDaily', - fieldName: 'resourceUtilizationDailies', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - resourceUtilizationDaily: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'ResourceUtilizationDaily', - 'resourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'ResourceUtilizationDailyFilter', - 'ResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'ResourceUtilizationDaily', - fieldName: 'resourceUtilizationDaily', - document, - variables, - transform: (data: { - resourceUtilizationDailies?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - resourceUtilizationDaily: data.resourceUtilizationDailies?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createResourceUtilizationDaily: { - resourceUtilizationDaily: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'ResourceUtilizationDaily', - 'createResourceUtilizationDaily', - 'resourceUtilizationDaily', - args.select, - args.data, - 'CreateResourceUtilizationDailyInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'ResourceUtilizationDaily', - fieldName: 'createResourceUtilizationDaily', - document, - variables, - }); - } -} diff --git a/sdk/constructive-react/src/compute/schema-types.ts b/sdk/constructive-react/src/compute/schema-types.ts index 948e64a08..c5c293aa8 100644 --- a/sdk/constructive-react/src/compute/schema-types.ts +++ b/sdk/constructive-react/src/compute/schema-types.ts @@ -6,7 +6,6 @@ import type { DbPreset, - DeclaredCapacity, FunctionApiBinding, FunctionDefinition, FunctionDeployment, @@ -21,6 +20,7 @@ import type { FunctionGraphRef, FunctionGraphStore, FunctionInvocation, + FunctionInvocationAttempt, GetAllTreeNodesRecord, InfraCommit, InfraGetAllTreeNodesRecord, @@ -30,13 +30,13 @@ import type { IntegrationProvider, Namespace, NamespaceEvent, - PlatformDeclaredCapacity, PlatformFunctionApiBinding, PlatformFunctionDefinition, PlatformFunctionDeployment, PlatformFunctionDeploymentEvent, PlatformFunctionExecutionLog, PlatformFunctionInvocation, + PlatformFunctionInvocationAttempt, PlatformInfraCommit, PlatformInfraGetAllTreeNodesRecord, PlatformInfraObject, @@ -45,26 +45,28 @@ import type { PlatformNamespace, PlatformNamespaceEvent, PlatformResource, + PlatformResourceDeclaredCapacity, PlatformResourceDefinition, PlatformResourceEvent, PlatformResourceInstallation, PlatformResourceStatusCheck, PlatformResourceUsageLog, PlatformResourceUsageSummary, - PlatformResourceUtilizationDaily, + PlatformResourceUtilization, PlatformResourcesHealth, PlatformResourcesRequirementsState, PlatformResourcesResolvedRequirement, PlatformWebhookEndpoint, PlatformWebhookEvent, Resource, + ResourceDeclaredCapacity, ResourceDefinition, ResourceEvent, ResourceInstallation, ResourceStatusCheck, ResourceUsageLog, ResourceUsageSummary, - ResourceUtilizationDaily, + ResourceUtilization, ResourcesHealth, ResourcesRequirementsState, ResourcesResolvedRequirement, @@ -117,35 +119,6 @@ export type DbPresetOrderBy = | 'STORE_ID_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC'; -/** Methods to use when ordering `DeclaredCapacity`. */ -export type DeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; /** Methods to use when ordering `FunctionApiBinding`. */ export type FunctionApiBindingOrderBy = | 'ALIAS_ASC' @@ -563,6 +536,37 @@ export type FunctionGraphStoreOrderBy = | 'PRIMARY_KEY_DESC' | 'SCOPE_ID_ASC' | 'SCOPE_ID_DESC'; +/** Methods to use when ordering `FunctionInvocationAttempt`. */ +export type FunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; /** Methods to use when ordering `FunctionInvocation`. */ export type FunctionInvocationOrderBy = | 'ACTOR_ID_ASC' @@ -759,35 +763,6 @@ export type NamespaceOrderBy = | 'STATUS_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC'; -/** Methods to use when ordering `PlatformDeclaredCapacity`. */ -export type PlatformDeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; /** Methods to use when ordering `PlatformFunctionApiBinding`. */ export type PlatformFunctionApiBindingOrderBy = | 'ALIAS_ASC' @@ -807,6 +782,8 @@ export type PlatformFunctionApiBindingOrderBy = export type PlatformFunctionDefinitionOrderBy = | 'ACCESS_CHANNELS_ASC' | 'ACCESS_CHANNELS_DESC' + | 'BILLABLE_ASC' + | 'BILLABLE_DESC' | 'CATEGORY_ASC' | 'CATEGORY_DESC' | 'CONCURRENCY_ASC' @@ -880,6 +857,8 @@ export type PlatformFunctionDefinitionOrderBy = | 'SCALE_MAX_DESC' | 'SCALE_MIN_ASC' | 'SCALE_MIN_DESC' + | 'SYSTEM_ASC' + | 'SYSTEM_DESC' | 'TARGET_FUNCTION_ASC' | 'TARGET_FUNCTION_DESC' | 'TARGET_SCHEMA_ASC' @@ -979,6 +958,35 @@ export type PlatformFunctionExecutionLogOrderBy = | 'PRIMARY_KEY_DESC' | 'TASK_IDENTIFIER_ASC' | 'TASK_IDENTIFIER_DESC'; +/** Methods to use when ordering `PlatformFunctionInvocationAttempt`. */ +export type PlatformFunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; /** Methods to use when ordering `PlatformFunctionInvocation`. */ export type PlatformFunctionInvocationOrderBy = | 'ACTOR_ID_ASC' @@ -1140,6 +1148,35 @@ export type PlatformNamespaceOrderBy = | 'STATUS_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC'; +/** Methods to use when ordering `PlatformResourceDeclaredCapacity`. */ +export type PlatformResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; /** Methods to use when ordering `PlatformResourceDefinition`. */ export type PlatformResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' @@ -1357,8 +1394,8 @@ export type PlatformResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -/** Methods to use when ordering `PlatformResourceUtilizationDaily`. */ -export type PlatformResourceUtilizationDailyOrderBy = +/** Methods to use when ordering `PlatformResourceUtilization`. */ +export type PlatformResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -1561,6 +1598,35 @@ export type PlatformWebhookEventOrderBy = | 'STATUS_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC'; +/** Methods to use when ordering `ResourceDeclaredCapacity`. */ +export type ResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; /** Methods to use when ordering `ResourceDefinition`. */ export type ResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' @@ -1792,8 +1858,8 @@ export type ResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -/** Methods to use when ordering `ResourceUtilizationDaily`. */ -export type ResourceUtilizationDailyOrderBy = +/** Methods to use when ordering `ResourceUtilization`. */ +export type ResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -2174,6 +2240,11 @@ export interface CreateFunctionGraphStoreInput { /** The `FunctionGraphStore` to be created by this mutation. */ functionGraphStore: FunctionGraphStoreInput; } +export interface CreateFunctionInvocationAttemptInput { + clientMutationId?: string; + /** The `FunctionInvocationAttempt` to be created by this mutation. */ + functionInvocationAttempt: FunctionInvocationAttemptInput; +} export interface CreateFunctionInvocationInput { clientMutationId?: string; /** The `FunctionInvocation` to be created by this mutation. */ @@ -2239,6 +2310,11 @@ export interface CreatePlatformFunctionExecutionLogInput { /** The `PlatformFunctionExecutionLog` to be created by this mutation. */ platformFunctionExecutionLog: PlatformFunctionExecutionLogInput; } +export interface CreatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + /** The `PlatformFunctionInvocationAttempt` to be created by this mutation. */ + platformFunctionInvocationAttempt: PlatformFunctionInvocationAttemptInput; +} export interface CreatePlatformFunctionInvocationInput { clientMutationId?: string; /** The `PlatformFunctionInvocation` to be created by this mutation. */ @@ -2445,41 +2521,6 @@ export interface DbPresetPatch { /** Timestamp of last modification */ updatedAt?: string; } -/** A filter to be used against `DeclaredCapacity` object types. All fields are combined with a logical ‘and.’ */ -export interface DeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: DeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: DeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: DeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} export interface DeleteDbPresetInput { clientMutationId?: string; /** Unique preset identifier */ @@ -2563,6 +2604,13 @@ export interface DeleteFunctionGraphStoreInput { /** Unique store identifier */ id: string; } +export interface DeleteFunctionInvocationAttemptInput { + clientMutationId?: string; + /** When the attempt result was recorded (partition key) */ + createdAt: string; + /** Unique attempt identifier */ + id: string; +} export interface DeleteFunctionInvocationInput { clientMutationId?: string; /** Invocation creation timestamp (partition key) */ @@ -2637,6 +2685,13 @@ export interface DeletePlatformFunctionExecutionLogInput { /** Unique log entry identifier */ id: string; } +export interface DeletePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + /** When the attempt result was recorded (partition key) */ + createdAt: string; + /** Unique attempt identifier */ + id: string; +} export interface DeletePlatformFunctionInvocationInput { clientMutationId?: string; /** Invocation creation timestamp (partition key) */ @@ -3000,8 +3055,6 @@ export interface FunctionDefinitionInput { targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -3078,8 +3131,6 @@ export interface FunctionDefinitionPatch { targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier?: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -4034,6 +4085,99 @@ export interface FunctionGraphToManyPlatformFunctionDefinitionFilter { /** Filters to entities where at least one related entity matches. */ some?: PlatformFunctionDefinitionFilter; } +/** A filter to be used against `FunctionInvocationAttempt` object types. All fields are combined with a logical ‘and.’ */ +export interface FunctionInvocationAttemptFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: FunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} +/** An input for mutations affecting `FunctionInvocationAttempt` */ +export interface FunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Database that owns this resource (database-scoped isolation) */ + databaseId: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: unknown; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} +/** Represents an update to a `FunctionInvocationAttempt`. Fields that are set will be updated. */ +export interface FunctionInvocationAttemptPatch { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt?: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Database that owns this resource (database-scoped isolation) */ + databaseId?: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: unknown; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success?: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string; +} /** A filter to be used against `FunctionInvocation` object types. All fields are combined with a logical ‘and.’ */ export interface FunctionInvocationFilter { /** Filter by the object’s `actorId` field. */ @@ -4105,7 +4249,7 @@ export interface FunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -4125,7 +4269,7 @@ export interface FunctionInvocationInput { result?: unknown; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -4148,7 +4292,7 @@ export interface FunctionInvocationPatch { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -4168,7 +4312,7 @@ export interface FunctionInvocationPatch { result?: unknown; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string; @@ -4773,41 +4917,6 @@ export interface NamespaceToManyWebhookEndpointFilter { /** Filters to entities where at least one related entity matches. */ some?: WebhookEndpointFilter; } -/** A filter to be used against `PlatformDeclaredCapacity` object types. All fields are combined with a logical ‘and.’ */ -export interface PlatformDeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: PlatformDeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} /** A filter to be used against `PlatformFunctionApiBinding` object types. All fields are combined with a logical ‘and.’ */ export interface PlatformFunctionApiBindingFilter { /** Filter by the object’s `alias` field. */ @@ -4872,6 +4981,8 @@ export interface PlatformFunctionDefinitionFilter { accessChannels?: StringListFilter; /** Checks for all expressions in this list. */ and?: PlatformFunctionDefinitionFilter[]; + /** Filter by the object’s `billable` field. */ + billable?: BooleanFilter; /** Filter by the object’s `category` field. */ category?: StringFilter; /** Filter by the object’s `concurrency` field. */ @@ -4954,6 +5065,8 @@ export interface PlatformFunctionDefinitionFilter { scaleMax?: IntFilter; /** Filter by the object’s `scaleMin` field. */ scaleMin?: IntFilter; + /** Filter by the object’s `system` field. */ + system?: BooleanFilter; /** Filter by the object’s `targetFunction` field. */ targetFunction?: StringFilter; /** Filter by the object’s `targetSchema` field. */ @@ -4971,6 +5084,8 @@ export interface PlatformFunctionDefinitionFilter { export interface PlatformFunctionDefinitionInput { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[]; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean; /** Function task category (e.g. email, embed, chunk, custom) */ category: string; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -5031,12 +5146,12 @@ export interface PlatformFunctionDefinitionInput { scaleMax?: number; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -5047,6 +5162,8 @@ export interface PlatformFunctionDefinitionInput { export interface PlatformFunctionDefinitionPatch { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[]; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean; /** Function task category (e.g. email, embed, chunk, custom) */ category?: string; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -5107,12 +5224,12 @@ export interface PlatformFunctionDefinitionPatch { scaleMax?: number; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier?: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -5394,6 +5511,93 @@ export interface PlatformFunctionExecutionLogPatch { /** Function routing key (NULL for generic job logs) */ taskIdentifier?: string; } +/** A filter to be used against `PlatformFunctionInvocationAttempt` object types. All fields are combined with a logical ‘and.’ */ +export interface PlatformFunctionInvocationAttemptFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformFunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} +/** An input for mutations affecting `PlatformFunctionInvocationAttempt` */ +export interface PlatformFunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: unknown; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} +/** Represents an update to a `PlatformFunctionInvocationAttempt`. Fields that are set will be updated. */ +export interface PlatformFunctionInvocationAttemptPatch { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt?: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: unknown; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success?: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string; +} /** A filter to be used against `PlatformFunctionInvocation` object types. All fields are combined with a logical ‘and.’ */ export interface PlatformFunctionInvocationFilter { /** Filter by the object’s `actorId` field. */ @@ -5461,7 +5665,7 @@ export interface PlatformFunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -5481,7 +5685,7 @@ export interface PlatformFunctionInvocationInput { result?: unknown; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -5502,7 +5706,7 @@ export interface PlatformFunctionInvocationPatch { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -5522,7 +5726,7 @@ export interface PlatformFunctionInvocationPatch { result?: unknown; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string; @@ -5961,6 +6165,41 @@ export interface PlatformNamespaceToManyPlatformWebhookEndpointFilter { /** Filters to entities where at least one related entity matches. */ some?: PlatformWebhookEndpointFilter; } +/** A filter to be used against `PlatformResourceDeclaredCapacity` object types. All fields are combined with a logical ‘and.’ */ +export interface PlatformResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} /** A filter to be used against `PlatformResourceDefinition` object types. All fields are combined with a logical ‘and.’ */ export interface PlatformResourceDefinitionFilter { /** Checks for all expressions in this list. */ @@ -6019,7 +6258,7 @@ export interface PlatformResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: unknown; @@ -6051,7 +6290,7 @@ export interface PlatformResourceDefinitionPatch { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string; /** Key/value pairs for selecting and filtering definitions */ labels?: unknown; @@ -6226,7 +6465,7 @@ export interface PlatformResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: unknown; @@ -6355,24 +6594,24 @@ export interface PlatformResourceInstallationToManyPlatformResourceFilter { } export interface PlatformResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: unknown; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: unknown; + slug?: string; } export interface PlatformResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: unknown; + newParams?: unknown; + targetInstallationId?: string; } /** Represents an update to a `PlatformResource`. Fields that are set will be updated. */ export interface PlatformResourcePatch { @@ -6387,7 +6626,7 @@ export interface PlatformResourcePatch { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string; /** Key/value pairs for selecting and filtering resources */ labels?: unknown; @@ -6529,7 +6768,7 @@ export interface PlatformResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** Represents an update to a `PlatformResourceUsageLog`. Fields that are set will be updated. */ @@ -6550,7 +6789,7 @@ export interface PlatformResourceUsageLogPatch { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string; } /** A filter to be used against `PlatformResourceUsageSummary` object types. All fields are combined with a logical ‘and.’ */ @@ -6622,10 +6861,10 @@ export interface PlatformResourceUsageSummaryPatch { /** Number of raw samples aggregated into this summary */ sampleCount?: number; } -/** A filter to be used against `PlatformResourceUtilizationDaily` object types. All fields are combined with a logical ‘and.’ */ -export interface PlatformResourceUtilizationDailyFilter { +/** A filter to be used against `PlatformResourceUtilization` object types. All fields are combined with a logical ‘and.’ */ +export interface PlatformResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: PlatformResourceUtilizationDailyFilter[]; + and?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -6657,9 +6896,9 @@ export interface PlatformResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: PlatformResourceUtilizationDailyFilter; + not?: PlatformResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: PlatformResourceUtilizationDailyFilter[]; + or?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -6978,6 +7217,41 @@ export interface ProvisionBucketInput { */ ownerId?: string; } +/** A filter to be used against `ResourceDeclaredCapacity` object types. All fields are combined with a logical ‘and.’ */ +export interface ResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: ResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} /** A filter to be used against `ResourceDefinition` object types. All fields are combined with a logical ‘and.’ */ export interface ResourceDefinitionFilter { /** Checks for all expressions in this list. */ @@ -7040,7 +7314,7 @@ export interface ResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: unknown; @@ -7074,7 +7348,7 @@ export interface ResourceDefinitionPatch { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string; /** Key/value pairs for selecting and filtering definitions */ labels?: unknown; @@ -7259,7 +7533,7 @@ export interface ResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: unknown; @@ -7394,24 +7668,24 @@ export interface ResourceInstallationToManyResourceFilter { } export interface ResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: unknown; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: unknown; + slug?: string; } export interface ResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: unknown; + newParams?: unknown; + targetInstallationId?: string; } /** Represents an update to a `Resource`. Fields that are set will be updated. */ export interface ResourcePatch { @@ -7428,7 +7702,7 @@ export interface ResourcePatch { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string; /** Key/value pairs for selecting and filtering resources */ labels?: unknown; @@ -7586,7 +7860,7 @@ export interface ResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** Represents an update to a `ResourceUsageLog`. Fields that are set will be updated. */ @@ -7609,7 +7883,7 @@ export interface ResourceUsageLogPatch { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string; } /** A filter to be used against `ResourceUsageSummary` object types. All fields are combined with a logical ‘and.’ */ @@ -7687,10 +7961,10 @@ export interface ResourceUsageSummaryPatch { /** Number of raw samples aggregated into this summary */ sampleCount?: number; } -/** A filter to be used against `ResourceUtilizationDaily` object types. All fields are combined with a logical ‘and.’ */ -export interface ResourceUtilizationDailyFilter { +/** A filter to be used against `ResourceUtilization` object types. All fields are combined with a logical ‘and.’ */ +export interface ResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: ResourceUtilizationDailyFilter[]; + and?: ResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -7722,9 +7996,9 @@ export interface ResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: ResourceUtilizationDailyFilter; + not?: ResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: ResourceUtilizationDailyFilter[]; + or?: ResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -7990,6 +8264,15 @@ export interface UpdateFunctionGraphStoreInput { /** Unique store identifier */ id: string; } +export interface UpdateFunctionInvocationAttemptInput { + clientMutationId?: string; + /** When the attempt result was recorded (partition key) */ + createdAt: string; + /** An object where the defined keys will be set on the `FunctionInvocationAttempt` being updated. */ + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; + /** Unique attempt identifier */ + id: string; +} export interface UpdateFunctionInvocationInput { clientMutationId?: string; /** Invocation creation timestamp (partition key) */ @@ -8090,6 +8373,15 @@ export interface UpdatePlatformFunctionExecutionLogInput { /** An object where the defined keys will be set on the `PlatformFunctionExecutionLog` being updated. */ platformFunctionExecutionLogPatch: PlatformFunctionExecutionLogPatch; } +export interface UpdatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + /** When the attempt result was recorded (partition key) */ + createdAt: string; + /** Unique attempt identifier */ + id: string; + /** An object where the defined keys will be set on the `PlatformFunctionInvocationAttempt` being updated. */ + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; +} export interface UpdatePlatformFunctionInvocationInput { clientMutationId?: string; /** Invocation creation timestamp (partition key) */ @@ -8486,13 +8778,6 @@ export interface DbPresetConnection { pageInfo: PageInfo; totalCount: number; } -/** A connection to a list of `DeclaredCapacity` values. */ -export interface DeclaredCapacityConnection { - edges: DeclaredCapacityEdge[]; - nodes: DeclaredCapacity[]; - pageInfo: PageInfo; - totalCount: number; -} /** A connection to a list of `FunctionApiBinding` values. */ export interface FunctionApiBindingConnection { edges: FunctionApiBindingEdge[]; @@ -8584,6 +8869,13 @@ export interface FunctionGraphConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `FunctionInvocationAttempt` values. */ +export interface FunctionInvocationAttemptConnection { + edges: FunctionInvocationAttemptEdge[]; + nodes: FunctionInvocationAttempt[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `FunctionInvocation` values. */ export interface FunctionInvocationConnection { edges: FunctionInvocationEdge[]; @@ -8654,13 +8946,6 @@ export interface NamespaceConnection { pageInfo: PageInfo; totalCount: number; } -/** A connection to a list of `PlatformDeclaredCapacity` values. */ -export interface PlatformDeclaredCapacityConnection { - edges: PlatformDeclaredCapacityEdge[]; - nodes: PlatformDeclaredCapacity[]; - pageInfo: PageInfo; - totalCount: number; -} /** A connection to a list of `PlatformFunctionApiBinding` values. */ export interface PlatformFunctionApiBindingConnection { edges: PlatformFunctionApiBindingEdge[]; @@ -8696,6 +8981,13 @@ export interface PlatformFunctionExecutionLogConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `PlatformFunctionInvocationAttempt` values. */ +export interface PlatformFunctionInvocationAttemptConnection { + edges: PlatformFunctionInvocationAttemptEdge[]; + nodes: PlatformFunctionInvocationAttempt[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `PlatformFunctionInvocation` values. */ export interface PlatformFunctionInvocationConnection { edges: PlatformFunctionInvocationEdge[]; @@ -8752,6 +9044,13 @@ export interface PlatformNamespaceConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `PlatformResourceDeclaredCapacity` values. */ +export interface PlatformResourceDeclaredCapacityConnection { + edges: PlatformResourceDeclaredCapacityEdge[]; + nodes: PlatformResourceDeclaredCapacity[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `PlatformResourceDefinition` values. */ export interface PlatformResourceDefinitionConnection { edges: PlatformResourceDefinitionEdge[]; @@ -8794,10 +9093,10 @@ export interface PlatformResourceUsageSummaryConnection { pageInfo: PageInfo; totalCount: number; } -/** A connection to a list of `PlatformResourceUtilizationDaily` values. */ -export interface PlatformResourceUtilizationDailyConnection { - edges: PlatformResourceUtilizationDailyEdge[]; - nodes: PlatformResourceUtilizationDaily[]; +/** A connection to a list of `PlatformResourceUtilization` values. */ +export interface PlatformResourceUtilizationConnection { + edges: PlatformResourceUtilizationEdge[]; + nodes: PlatformResourceUtilization[]; pageInfo: PageInfo; totalCount: number; } @@ -8843,6 +9142,13 @@ export interface PlatformWebhookEventConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `ResourceDeclaredCapacity` values. */ +export interface ResourceDeclaredCapacityConnection { + edges: ResourceDeclaredCapacityEdge[]; + nodes: ResourceDeclaredCapacity[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `ResourceDefinition` values. */ export interface ResourceDefinitionConnection { edges: ResourceDefinitionEdge[]; @@ -8885,10 +9191,10 @@ export interface ResourceUsageSummaryConnection { pageInfo: PageInfo; totalCount: number; } -/** A connection to a list of `ResourceUtilizationDaily` values. */ -export interface ResourceUtilizationDailyConnection { - edges: ResourceUtilizationDailyEdge[]; - nodes: ResourceUtilizationDaily[]; +/** A connection to a list of `ResourceUtilization` values. */ +export interface ResourceUtilizationConnection { + edges: ResourceUtilizationEdge[]; + nodes: ResourceUtilization[]; pageInfo: PageInfo; totalCount: number; } @@ -9042,6 +9348,12 @@ export interface CreateFunctionInvocationPayload { functionInvocation?: FunctionInvocation | null; functionInvocationEdge?: FunctionInvocationEdge | null; } +export interface CreateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was created by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} export interface CreateInfraCommitPayload { clientMutationId?: string | null; /** The `InfraCommit` that was created by this mutation. */ @@ -9120,6 +9432,12 @@ export interface CreatePlatformFunctionInvocationPayload { platformFunctionInvocation?: PlatformFunctionInvocation | null; platformFunctionInvocationEdge?: PlatformFunctionInvocationEdge | null; } +export interface CreatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was created by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} export interface CreatePlatformInfraCommitPayload { clientMutationId?: string | null; /** The `PlatformInfraCommit` that was created by this mutation. */ @@ -9354,6 +9672,12 @@ export interface DeleteFunctionInvocationPayload { functionInvocation?: FunctionInvocation | null; functionInvocationEdge?: FunctionInvocationEdge | null; } +export interface DeleteFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was deleted by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} export interface DeleteInfraCommitPayload { clientMutationId?: string | null; /** The `InfraCommit` that was deleted by this mutation. */ @@ -9432,6 +9756,12 @@ export interface DeletePlatformFunctionInvocationPayload { platformFunctionInvocation?: PlatformFunctionInvocation | null; platformFunctionInvocationEdge?: PlatformFunctionInvocationEdge | null; } +export interface DeletePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was deleted by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} export interface DeletePlatformInfraCommitPayload { clientMutationId?: string | null; /** The `PlatformInfraCommit` that was deleted by this mutation. */ @@ -9754,6 +10084,12 @@ export interface UpdateFunctionInvocationPayload { functionInvocation?: FunctionInvocation | null; functionInvocationEdge?: FunctionInvocationEdge | null; } +export interface UpdateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was updated by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} export interface UpdateInfraCommitPayload { clientMutationId?: string | null; /** The `InfraCommit` that was updated by this mutation. */ @@ -9832,6 +10168,12 @@ export interface UpdatePlatformFunctionInvocationPayload { platformFunctionInvocation?: PlatformFunctionInvocation | null; platformFunctionInvocationEdge?: PlatformFunctionInvocationEdge | null; } +export interface UpdatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was updated by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} export interface UpdatePlatformInfraCommitPayload { clientMutationId?: string | null; /** The `PlatformInfraCommit` that was updated by this mutation. */ @@ -9996,6 +10338,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -10019,12 +10363,6 @@ export interface PageInfo { /** When paginating backwards, the cursor to continue. */ startCursor?: string | null; } -/** A `DeclaredCapacity` edge in the connection. */ -export interface DeclaredCapacityEdge { - cursor?: string | null; - /** The `DeclaredCapacity` at the end of the edge. */ - node?: DeclaredCapacity | null; -} /** A `FunctionApiBinding` edge in the connection. */ export interface FunctionApiBindingEdge { cursor?: string | null; @@ -10103,6 +10441,12 @@ export interface FunctionGraphEdge { /** The `FunctionGraph` at the end of the edge. */ node?: FunctionGraph | null; } +/** A `FunctionInvocationAttempt` edge in the connection. */ +export interface FunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `FunctionInvocationAttempt` at the end of the edge. */ + node?: FunctionInvocationAttempt | null; +} /** A `FunctionInvocation` edge in the connection. */ export interface FunctionInvocationEdge { cursor?: string | null; @@ -10163,12 +10507,6 @@ export interface NamespaceEdge { /** The `Namespace` at the end of the edge. */ node?: Namespace | null; } -/** A `PlatformDeclaredCapacity` edge in the connection. */ -export interface PlatformDeclaredCapacityEdge { - cursor?: string | null; - /** The `PlatformDeclaredCapacity` at the end of the edge. */ - node?: PlatformDeclaredCapacity | null; -} /** A `PlatformFunctionApiBinding` edge in the connection. */ export interface PlatformFunctionApiBindingEdge { cursor?: string | null; @@ -10199,6 +10537,12 @@ export interface PlatformFunctionExecutionLogEdge { /** The `PlatformFunctionExecutionLog` at the end of the edge. */ node?: PlatformFunctionExecutionLog | null; } +/** A `PlatformFunctionInvocationAttempt` edge in the connection. */ +export interface PlatformFunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `PlatformFunctionInvocationAttempt` at the end of the edge. */ + node?: PlatformFunctionInvocationAttempt | null; +} /** A `PlatformFunctionInvocation` edge in the connection. */ export interface PlatformFunctionInvocationEdge { cursor?: string | null; @@ -10247,6 +10591,12 @@ export interface PlatformNamespaceEdge { /** The `PlatformNamespace` at the end of the edge. */ node?: PlatformNamespace | null; } +/** A `PlatformResourceDeclaredCapacity` edge in the connection. */ +export interface PlatformResourceDeclaredCapacityEdge { + cursor?: string | null; + /** The `PlatformResourceDeclaredCapacity` at the end of the edge. */ + node?: PlatformResourceDeclaredCapacity | null; +} /** A `PlatformResourceDefinition` edge in the connection. */ export interface PlatformResourceDefinitionEdge { cursor?: string | null; @@ -10283,11 +10633,11 @@ export interface PlatformResourceUsageSummaryEdge { /** The `PlatformResourceUsageSummary` at the end of the edge. */ node?: PlatformResourceUsageSummary | null; } -/** A `PlatformResourceUtilizationDaily` edge in the connection. */ -export interface PlatformResourceUtilizationDailyEdge { +/** A `PlatformResourceUtilization` edge in the connection. */ +export interface PlatformResourceUtilizationEdge { cursor?: string | null; - /** The `PlatformResourceUtilizationDaily` at the end of the edge. */ - node?: PlatformResourceUtilizationDaily | null; + /** The `PlatformResourceUtilization` at the end of the edge. */ + node?: PlatformResourceUtilization | null; } /** A `PlatformResource` edge in the connection. */ export interface PlatformResourceEdge { @@ -10325,6 +10675,12 @@ export interface PlatformWebhookEventEdge { /** The `PlatformWebhookEvent` at the end of the edge. */ node?: PlatformWebhookEvent | null; } +/** A `ResourceDeclaredCapacity` edge in the connection. */ +export interface ResourceDeclaredCapacityEdge { + cursor?: string | null; + /** The `ResourceDeclaredCapacity` at the end of the edge. */ + node?: ResourceDeclaredCapacity | null; +} /** A `ResourceDefinition` edge in the connection. */ export interface ResourceDefinitionEdge { cursor?: string | null; @@ -10361,11 +10717,11 @@ export interface ResourceUsageSummaryEdge { /** The `ResourceUsageSummary` at the end of the edge. */ node?: ResourceUsageSummary | null; } -/** A `ResourceUtilizationDaily` edge in the connection. */ -export interface ResourceUtilizationDailyEdge { +/** A `ResourceUtilization` edge in the connection. */ +export interface ResourceUtilizationEdge { cursor?: string | null; - /** The `ResourceUtilizationDaily` at the end of the edge. */ - node?: ResourceUtilizationDaily | null; + /** The `ResourceUtilization` at the end of the edge. */ + node?: ResourceUtilization | null; } /** A `Resource` edge in the connection. */ export interface ResourceEdge { @@ -10486,6 +10842,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -10518,6 +10887,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -10583,3 +10954,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/compute/types.ts b/sdk/constructive-react/src/compute/types.ts index 153cef7fe..e31d49acc 100644 --- a/sdk/constructive-react/src/compute/types.ts +++ b/sdk/constructive-react/src/compute/types.ts @@ -19,21 +19,6 @@ export interface DbPreset { storeId: string | null; updatedAt: string | null; } -export interface DeclaredCapacity { - cpuLimitMillicores: string | null; - cpuRequestMillicores: string | null; - installationId: string | null; - isTransient: boolean | null; - kind: string | null; - memoryLimitBytes: string | null; - memoryRequestBytes: string | null; - namespaceId: string | null; - podCountMax: number | null; - podCountMin: number | null; - source: string | null; - sourceId: string | null; - storageSizeBytes: string | null; -} export interface FunctionApiBinding { alias: string | null; apiId: string | null; @@ -236,6 +221,21 @@ export interface FunctionGraphStore { name: string | null; scopeId: string | null; } +export interface FunctionInvocationAttempt { + actorId: string | null; + attempt: number | null; + createdAt: string | null; + databaseId: string | null; + durationMs: number | null; + error: string | null; + errorDetail: unknown | null; + id: string | null; + invocationCreatedAt: string | null; + invocationId: string | null; + startedAt: string | null; + success: boolean | null; + taskIdentifier: string | null; +} export interface FunctionInvocation { actorId: string | null; apiBindingId: string | null; @@ -338,21 +338,6 @@ export interface NamespaceEvent { metadata: unknown | null; namespaceId: string | null; } -export interface PlatformDeclaredCapacity { - cpuLimitMillicores: string | null; - cpuRequestMillicores: string | null; - installationId: string | null; - isTransient: boolean | null; - kind: string | null; - memoryLimitBytes: string | null; - memoryRequestBytes: string | null; - namespaceId: string | null; - podCountMax: number | null; - podCountMin: number | null; - source: string | null; - sourceId: string | null; - storageSizeBytes: string | null; -} export interface PlatformFunctionApiBinding { alias: string | null; apiId: string | null; @@ -362,6 +347,7 @@ export interface PlatformFunctionApiBinding { } export interface PlatformFunctionDefinition { accessChannels: string[] | null; + billable: boolean | null; category: string | null; concurrency: number | null; cpuLimitMillicores: string | null; @@ -397,6 +383,7 @@ export interface PlatformFunctionDefinition { runtime: string | null; scaleMax: number | null; scaleMin: number | null; + system: boolean | null; targetFunction: string | null; targetSchema: string | null; taskIdentifier: string | null; @@ -446,6 +433,20 @@ export interface PlatformFunctionExecutionLog { metadata: unknown | null; taskIdentifier: string | null; } +export interface PlatformFunctionInvocationAttempt { + actorId: string | null; + attempt: number | null; + createdAt: string | null; + durationMs: number | null; + error: string | null; + errorDetail: unknown | null; + id: string | null; + invocationCreatedAt: string | null; + invocationId: string | null; + startedAt: string | null; + success: boolean | null; + taskIdentifier: string | null; +} export interface PlatformFunctionInvocation { actorId: string | null; apiBindingId: string | null; @@ -558,6 +559,21 @@ export interface PlatformResource { updatedAt: string | null; updatedBy: string | null; } +export interface PlatformResourceDeclaredCapacity { + cpuLimitMillicores: string | null; + cpuRequestMillicores: string | null; + installationId: string | null; + isTransient: boolean | null; + kind: string | null; + memoryLimitBytes: string | null; + memoryRequestBytes: string | null; + namespaceId: string | null; + podCountMax: number | null; + podCountMin: number | null; + source: string | null; + sourceId: string | null; + storageSizeBytes: string | null; +} export interface PlatformResourceDefinition { annotations: unknown | null; createdAt: string | null; @@ -632,7 +648,7 @@ export interface PlatformResourceUsageSummary { runtimeSeconds: string | null; sampleCount: number | null; } -export interface PlatformResourceUtilizationDaily { +export interface PlatformResourceUtilization { avgMemoryBytes: string | null; cpuLimitMillicores: string | null; cpuPeakUtilization: string | null; @@ -767,6 +783,21 @@ export interface Resource { updatedAt: string | null; updatedBy: string | null; } +export interface ResourceDeclaredCapacity { + cpuLimitMillicores: string | null; + cpuRequestMillicores: string | null; + installationId: string | null; + isTransient: boolean | null; + kind: string | null; + memoryLimitBytes: string | null; + memoryRequestBytes: string | null; + namespaceId: string | null; + podCountMax: number | null; + podCountMin: number | null; + source: string | null; + sourceId: string | null; + storageSizeBytes: string | null; +} export interface ResourceDefinition { annotations: unknown | null; createdAt: string | null; @@ -847,7 +878,7 @@ export interface ResourceUsageSummary { runtimeSeconds: string | null; sampleCount: number | null; } -export interface ResourceUtilizationDaily { +export interface ResourceUtilization { avgMemoryBytes: string | null; cpuLimitMillicores: string | null; cpuPeakUtilization: string | null; diff --git a/sdk/constructive-react/src/config/schema-types.ts b/sdk/constructive-react/src/config/schema-types.ts index bc6301a29..5fca79c52 100644 --- a/sdk/constructive-react/src/config/schema-types.ts +++ b/sdk/constructive-react/src/config/schema-types.ts @@ -680,6 +680,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -810,6 +812,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -842,6 +857,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -907,3 +924,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/infra/schema-types.ts b/sdk/constructive-react/src/infra/schema-types.ts index 5e422660e..5279e3749 100644 --- a/sdk/constructive-react/src/infra/schema-types.ts +++ b/sdk/constructive-react/src/infra/schema-types.ts @@ -1285,6 +1285,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -1445,6 +1447,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -1477,6 +1492,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -1542,3 +1559,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/modules/README.md b/sdk/constructive-react/src/modules/README.md index dc503ce8a..d7de76e9f 100644 --- a/sdk/constructive-react/src/modules/README.md +++ b/sdk/constructive-react/src/modules/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 68 +- **Tables:** 74 - **Custom queries:** 2 - **Custom mutations:** 10 diff --git a/sdk/constructive-react/src/modules/hooks/README.md b/sdk/constructive-react/src/modules/hooks/README.md index 25d42cc60..54452966a 100644 --- a/sdk/constructive-react/src/modules/hooks/README.md +++ b/sdk/constructive-react/src/modules/hooks/README.md @@ -37,6 +37,16 @@ function App() { | `useCreateAgentModuleMutation` | Mutation | Create a agentModule | | `useUpdateAgentModuleMutation` | Mutation | Update a agentModule | | `useDeleteAgentModuleMutation` | Mutation | Delete a agentModule | +| `useApiSurfaceModulesQuery` | Query | List all apiSurfaceModules | +| `useApiSurfaceModuleQuery` | Query | Get one apiSurfaceModule | +| `useCreateApiSurfaceModuleMutation` | Mutation | Create a apiSurfaceModule | +| `useUpdateApiSurfaceModuleMutation` | Mutation | Update a apiSurfaceModule | +| `useDeleteApiSurfaceModuleMutation` | Mutation | Delete a apiSurfaceModule | +| `useAppModulesQuery` | Query | List all appModules | +| `useAppModuleQuery` | Query | Get one appModule | +| `useCreateAppModuleMutation` | Mutation | Create a appModule | +| `useUpdateAppModuleMutation` | Mutation | Update a appModule | +| `useDeleteAppModuleMutation` | Mutation | Delete a appModule | | `useBillingModulesQuery` | Query | List all billingModules | | `useBillingModuleQuery` | Query | Get one billingModule | | `useCreateBillingModuleMutation` | Mutation | Create a billingModule | @@ -62,6 +72,11 @@ function App() { | `useCreateBlueprintTemplateMutation` | Mutation | A shareable, versioned schema recipe for the blueprint marketplace. Templates define arrays of secure_table_provision + relation_provision inputs that together describe a complete domain schema (e.g. e-commerce, telemedicine, habit tracker). Templates are never executed directly — they are copied into a blueprint first via copy_template_to_blueprint(). Can be private (owner-only) or public (marketplace-visible). | | `useUpdateBlueprintTemplateMutation` | Mutation | A shareable, versioned schema recipe for the blueprint marketplace. Templates define arrays of secure_table_provision + relation_provision inputs that together describe a complete domain schema (e.g. e-commerce, telemedicine, habit tracker). Templates are never executed directly — they are copied into a blueprint first via copy_template_to_blueprint(). Can be private (owner-only) or public (marketplace-visible). | | `useDeleteBlueprintTemplateMutation` | Mutation | A shareable, versioned schema recipe for the blueprint marketplace. Templates define arrays of secure_table_provision + relation_provision inputs that together describe a complete domain schema (e.g. e-commerce, telemedicine, habit tracker). Templates are never executed directly — they are copied into a blueprint first via copy_template_to_blueprint(). Can be private (owner-only) or public (marketplace-visible). | +| `useCatalogModulesQuery` | Query | List all catalogModules | +| `useCatalogModuleQuery` | Query | Get one catalogModule | +| `useCreateCatalogModuleMutation` | Mutation | Create a catalogModule | +| `useUpdateCatalogModuleMutation` | Mutation | Update a catalogModule | +| `useDeleteCatalogModuleMutation` | Mutation | Delete a catalogModule | | `useComputeLogModulesQuery` | Query | List all computeLogModules | | `useComputeLogModuleQuery` | Query | Get one computeLogModule | | `useCreateComputeLogModuleMutation` | Mutation | Create a computeLogModule | @@ -127,6 +142,11 @@ function App() { | `useCreateDevicesModuleMutation` | Mutation | Create a devicesModule | | `useUpdateDevicesModuleMutation` | Mutation | Update a devicesModule | | `useDeleteDevicesModuleMutation` | Mutation | Delete a devicesModule | +| `useDomainModulesQuery` | Query | List all domainModules | +| `useDomainModuleQuery` | Query | Get one domainModule | +| `useCreateDomainModuleMutation` | Mutation | Create a domainModule | +| `useUpdateDomainModuleMutation` | Mutation | Update a domainModule | +| `useDeleteDomainModuleMutation` | Mutation | Delete a domainModule | | `useEmailsModulesQuery` | Query | List all emailsModules | | `useEmailsModuleQuery` | Query | Get one emailsModule | | `useCreateEmailsModuleMutation` | Mutation | Create a emailsModule | @@ -432,6 +452,11 @@ function App() { | `useCreateRlsModuleMutation` | Mutation | Create a rlsModule | | `useUpdateRlsModuleMutation` | Mutation | Update a rlsModule | | `useDeleteRlsModuleMutation` | Mutation | Delete a rlsModule | +| `useRouteModulesQuery` | Query | List all routeModules | +| `useRouteModuleQuery` | Query | Get one routeModule | +| `useCreateRouteModuleMutation` | Mutation | Create a routeModule | +| `useUpdateRouteModuleMutation` | Mutation | Update a routeModule | +| `useDeleteRouteModuleMutation` | Mutation | Delete a routeModule | | `useSecureTableProvisionsQuery` | Query | Provisions security, fields, grants, and policies onto a table. Each row can independently: (1) create fields via nodes[] array (supporting multiple Data* modules per row), (2) grant privileges via grants[] array (supporting per-role privilege targeting), (3) create RLS policies via policies[] array (supporting multiple Authz* policies per row). Multiple rows can target the same table to compose different concerns. All three concerns are optional and independent. | | `useSecureTableProvisionQuery` | Query | Provisions security, fields, grants, and policies onto a table. Each row can independently: (1) create fields via nodes[] array (supporting multiple Data* modules per row), (2) grant privileges via grants[] array (supporting per-role privilege targeting), (3) create RLS policies via policies[] array (supporting multiple Authz* policies per row). Multiple rows can target the same table to compose different concerns. All three concerns are optional and independent. | | `useCreateSecureTableProvisionMutation` | Mutation | Provisions security, fields, grants, and policies onto a table. Each row can independently: (1) create fields via nodes[] array (supporting multiple Data* modules per row), (2) grant privileges via grants[] array (supporting per-role privilege targeting), (3) create RLS policies via policies[] array (supporting multiple Authz* policies per row). Multiple rows can target the same table to compose different concerns. All three concerns are optional and independent. | @@ -447,6 +472,11 @@ function App() { | `useCreateSessionsModuleMutation` | Mutation | Create a sessionsModule | | `useUpdateSessionsModuleMutation` | Mutation | Update a sessionsModule | | `useDeleteSessionsModuleMutation` | Mutation | Delete a sessionsModule | +| `useSiteSurfaceModulesQuery` | Query | List all siteSurfaceModules | +| `useSiteSurfaceModuleQuery` | Query | Get one siteSurfaceModule | +| `useCreateSiteSurfaceModuleMutation` | Mutation | Create a siteSurfaceModule | +| `useUpdateSiteSurfaceModuleMutation` | Mutation | Update a siteSurfaceModule | +| `useDeleteSiteSurfaceModuleMutation` | Mutation | Delete a siteSurfaceModule | | `useStorageLogModulesQuery` | Query | List all storageLogModules | | `useStorageLogModuleQuery` | Query | Get one storageLogModule | | `useCreateStorageLogModuleMutation` | Mutation | Create a storageLogModule | @@ -551,6 +581,48 @@ const { mutate: create } = useCreateAgentModuleMutation({ create({ agentTableId: '', agentTableName: '', apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', hasAgents: '', hasPlans: '', hasResources: '', messageTableId: '', messageTableName: '', personaTableId: '', personaTableName: '', planTableId: '', planTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', promptsTableId: '', promptsTableName: '', provisions: '', publicSchemaName: '', resourceTableId: '', resourceTableName: '', resources: '', schemaId: '', scope: '', shared: '', taskTableId: '', taskTableName: '', threadTableId: '', threadTableName: '' }); ``` +### ApiSurfaceModule + +```typescript +// List all apiSurfaceModules +const { data, isLoading } = useApiSurfaceModulesQuery({ + selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); + +// Get one apiSurfaceModule +const { data: item } = useApiSurfaceModuleQuery({ + id: '', + selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); + +// Create a apiSurfaceModule +const { mutate: create } = useCreateApiSurfaceModuleMutation({ + selection: { fields: { id: true } }, +}); +create({ apiName: '', apisTableId: '', apisTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +``` + +### AppModule + +```typescript +// List all appModules +const { data, isLoading } = useAppModulesQuery({ + selection: { fields: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); + +// Get one appModule +const { data: item } = useAppModuleQuery({ + id: '', + selection: { fields: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); + +// Create a appModule +const { mutate: create } = useCreateAppModuleMutation({ + selection: { fields: { id: true } }, +}); +create({ apiName: '', appMembersTableId: '', appMembersTableName: '', appsTableId: '', appsTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +``` + ### BillingModule ```typescript @@ -656,6 +728,27 @@ const { mutate: create } = useCreateBlueprintTemplateMutation({ create({ categories: '', complexity: '', copyCount: '', definition: '', definitionHash: '', definitionSchemaVersion: '', description: '', displayName: '', forkCount: '', forkedFromId: '', name: '', ownerId: '', source: '', tableHashes: '', tags: '', version: '', visibility: '' }); ``` +### CatalogModule + +```typescript +// List all catalogModules +const { data, isLoading } = useCatalogModulesQuery({ + selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }, +}); + +// Get one catalogModule +const { data: item } = useCatalogModuleQuery({ + id: '', + selection: { fields: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }, +}); + +// Create a catalogModule +const { mutate: create } = useCreateCatalogModuleMutation({ + selection: { fields: { id: true } }, +}); +create({ apiName: '', apisTableId: '', apisTableName: '', appsTableId: '', appsTableName: '', databaseId: '', defaultPermissions: '', domainsTableId: '', domainsTableName: '', entityTableId: '', functionsTableId: '', functionsTableName: '', namespacesTableId: '', namespacesTableName: '', policies: '', privateApiName: '', provisions: '', publicSchemaName: '', resourceDefinitionsTableId: '', resourceDefinitionsTableName: '', resourceInstallationsTableId: '', resourceInstallationsTableName: '', resourcesTableId: '', resourcesTableName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }); +``` + ### ComputeLogModule ```typescript @@ -766,20 +859,20 @@ create({ addressesTableId: '', cryptoNetwork: '', databaseId: '', - selection: { fields: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }, + selection: { fields: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }, }); // Create a databaseProvisionModule const { mutate: create } = useCreateDatabaseProvisionModuleMutation({ selection: { fields: { id: true } }, }); -create({ bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }); +create({ async: '', bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }); ``` ### DbPoolConfig @@ -929,6 +1022,27 @@ const { mutate: create } = useCreateDevicesModuleMutation({ create({ databaseId: '', deviceSettingsTableId: '', deviceSettingsTableName: '', schemaId: '', userDevicesTableId: '', userDevicesTableName: '' }); ``` +### DomainModule + +```typescript +// List all domainModules +const { data, isLoading } = useDomainModulesQuery({ + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); + +// Get one domainModule +const { data: item } = useDomainModuleQuery({ + id: '', + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, +}); + +// Create a domainModule +const { mutate: create } = useCreateDomainModuleMutation({ + selection: { fields: { id: true } }, +}); +create({ apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainEventsTableId: '', domainEventsTableName: '', domainVerificationsTableId: '', domainVerificationsTableName: '', domainsTableId: '', domainsTableName: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +``` + ### EmailsModule ```typescript @@ -1018,20 +1132,20 @@ create({ apiName: '', databaseId: '', defaultPermissions: '', - selection: { fields: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, + selection: { fields: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }, }); // Create a functionInvocationModule const { mutate: create } = useCreateFunctionInvocationModuleMutation({ selection: { fields: { id: true } }, }); -create({ apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); +create({ apiName: '', attemptsTableId: '', attemptsTableName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }); ``` ### FunctionModule @@ -1664,6 +1778,27 @@ const { mutate: create } = useCreateRlsModuleMutation({ create({ apiName: '', authenticate: '', authenticateStrict: '', currentRole: '', currentRoleId: '', databaseId: '', privateApiName: '', privateSchemaId: '', schemaId: '', sessionCredentialsTableId: '', sessionsTableId: '', usersTableId: '' }); ``` +### RouteModule + +```typescript +// List all routeModules +const { data, isLoading } = useRouteModulesQuery({ + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }, +}); + +// Get one routeModule +const { data: item } = useRouteModuleQuery({ + id: '', + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }, +}); + +// Create a routeModule +const { mutate: create } = useCreateRouteModuleMutation({ + selection: { fields: { id: true } }, +}); +create({ apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainModuleId: '', entityField: '', entityTableId: '', hostnameBindingsTableId: '', hostnameBindingsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', resolverFunctionName: '', routeBindingsTableId: '', routeBindingsTableName: '', routesTableId: '', routesTableName: '', schemaId: '', scope: '' }); +``` + ### SecureTableProvision ```typescript @@ -1727,6 +1862,27 @@ const { mutate: create } = useCreateSessionsModuleMutation({ create({ authSettingsTableId: '', authSettingsTableName: '', databaseId: '', schemaId: '', sessionCredentialsTableId: '', sessionCredentialsTableName: '', sessionsDefaultExpiration: '', sessionsTableId: '', sessionsTableName: '', usersTableId: '' }); ``` +### SiteSurfaceModule + +```typescript +// List all siteSurfaceModules +const { data, isLoading } = useSiteSurfaceModulesQuery({ + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }, +}); + +// Get one siteSurfaceModule +const { data: item } = useSiteSurfaceModuleQuery({ + id: '', + selection: { fields: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }, +}); + +// Create a siteSurfaceModule +const { mutate: create } = useCreateSiteSurfaceModuleMutation({ + selection: { fields: { id: true } }, +}); +create({ apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }); +``` + ### StorageLogModule ```typescript diff --git a/sdk/constructive-react/src/modules/hooks/index.ts b/sdk/constructive-react/src/modules/hooks/index.ts index 8cc837233..f68a02493 100644 --- a/sdk/constructive-react/src/modules/hooks/index.ts +++ b/sdk/constructive-react/src/modules/hooks/index.ts @@ -2,7 +2,7 @@ * GraphQL SDK * @generated by @constructive-io/graphql-codegen * - * Tables: AgentModule, BillingModule, BillingProviderModule, Blueprint, BlueprintConstruction, BlueprintTemplate, ComputeLogModule, ConfigSecretsUserModule, ConnectedAccountsModule, CryptoAddressesModule, CryptoAuthModule, DatabaseProvisionModule, DbPoolConfig, DbPool, DbPresetModule, DbUsageModule, DefaultIdsModule, DenormalizedTableField, DevicesModule, EmailsModule, EntityTypeProvision, EventsModule, FunctionDeploymentModule, FunctionInvocationModule, FunctionModule, GraphExecutionModule, GraphModule, HierarchyModule, HttpRouteModule, I18NModule, IdentityProvidersModule, InferenceLogModule, InfraConfigModule, InfraSecretsModule, IntegrationProvidersModule, InternalSecretsModule, InvitesModule, LimitsModule, MembershipTypesModule, MembershipsModule, MerkleStoreModule, NamespaceModule, NotificationsModule, PermissionsModule, PhoneNumbersModule, PlansModule, PrincipalAuthModule, ProfilesModule, RateLimitMetersModule, RateLimitsModule, RealtimeModule, RelationProvision, ResourceModule, RlsModule, SecureTableProvision, SessionSecretsModule, SessionsModule, StorageLogModule, StorageModule, TransferLogModule, UserAuthModule, UserCredentialsModule, UserSettingsModule, UserStateModule, UsersModule, WebauthnAuthModule, WebauthnCredentialsModule, WebhookModule + * Tables: AgentModule, ApiSurfaceModule, AppModule, BillingModule, BillingProviderModule, Blueprint, BlueprintConstruction, BlueprintTemplate, CatalogModule, ComputeLogModule, ConfigSecretsUserModule, ConnectedAccountsModule, CryptoAddressesModule, CryptoAuthModule, DatabaseProvisionModule, DbPoolConfig, DbPool, DbPresetModule, DbUsageModule, DefaultIdsModule, DenormalizedTableField, DevicesModule, DomainModule, EmailsModule, EntityTypeProvision, EventsModule, FunctionDeploymentModule, FunctionInvocationModule, FunctionModule, GraphExecutionModule, GraphModule, HierarchyModule, HttpRouteModule, I18NModule, IdentityProvidersModule, InferenceLogModule, InfraConfigModule, InfraSecretsModule, IntegrationProvidersModule, InternalSecretsModule, InvitesModule, LimitsModule, MembershipTypesModule, MembershipsModule, MerkleStoreModule, NamespaceModule, NotificationsModule, PermissionsModule, PhoneNumbersModule, PlansModule, PrincipalAuthModule, ProfilesModule, RateLimitMetersModule, RateLimitsModule, RealtimeModule, RelationProvision, ResourceModule, RlsModule, RouteModule, SecureTableProvision, SessionSecretsModule, SessionsModule, SiteSurfaceModule, StorageLogModule, StorageModule, TransferLogModule, UserAuthModule, UserCredentialsModule, UserSettingsModule, UserStateModule, UsersModule, WebauthnAuthModule, WebauthnCredentialsModule, WebhookModule * * Usage: * diff --git a/sdk/constructive-react/src/modules/hooks/invalidation.ts b/sdk/constructive-react/src/modules/hooks/invalidation.ts index 4ccc15a3b..1cb321647 100644 --- a/sdk/constructive-react/src/modules/hooks/invalidation.ts +++ b/sdk/constructive-react/src/modules/hooks/invalidation.ts @@ -16,11 +16,14 @@ import type { QueryClient } from '@tanstack/react-query'; import { agentModuleKeys, + apiSurfaceModuleKeys, + appModuleKeys, billingModuleKeys, billingProviderModuleKeys, blueprintKeys, blueprintConstructionKeys, blueprintTemplateKeys, + catalogModuleKeys, computeLogModuleKeys, configSecretsUserModuleKeys, connectedAccountsModuleKeys, @@ -34,6 +37,7 @@ import { defaultIdsModuleKeys, denormalizedTableFieldKeys, devicesModuleKeys, + domainModuleKeys, emailsModuleKeys, entityTypeProvisionKeys, eventsModuleKeys, @@ -69,9 +73,11 @@ import { relationProvisionKeys, resourceModuleKeys, rlsModuleKeys, + routeModuleKeys, secureTableProvisionKeys, sessionSecretsModuleKeys, sessionsModuleKeys, + siteSurfaceModuleKeys, storageLogModuleKeys, storageModuleKeys, transferLogModuleKeys, @@ -121,6 +127,40 @@ export const invalidate = { queryKey: agentModuleKeys.detail(id), }), }, + /** Invalidate apiSurfaceModule queries */ apiSurfaceModule: { + /** Invalidate all apiSurfaceModule queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: apiSurfaceModuleKeys.all, + }), + /** Invalidate apiSurfaceModule list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: apiSurfaceModuleKeys.lists(), + }), + /** Invalidate a specific apiSurfaceModule */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: apiSurfaceModuleKeys.detail(id), + }), + }, + /** Invalidate appModule queries */ appModule: { + /** Invalidate all appModule queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: appModuleKeys.all, + }), + /** Invalidate appModule list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: appModuleKeys.lists(), + }), + /** Invalidate a specific appModule */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: appModuleKeys.detail(id), + }), + }, /** Invalidate billingModule queries */ billingModule: { /** Invalidate all billingModule queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -206,6 +246,23 @@ export const invalidate = { queryKey: blueprintTemplateKeys.detail(id), }), }, + /** Invalidate catalogModule queries */ catalogModule: { + /** Invalidate all catalogModule queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: catalogModuleKeys.all, + }), + /** Invalidate catalogModule list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: catalogModuleKeys.lists(), + }), + /** Invalidate a specific catalogModule */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: catalogModuleKeys.detail(id), + }), + }, /** Invalidate computeLogModule queries */ computeLogModule: { /** Invalidate all computeLogModule queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -424,6 +481,23 @@ export const invalidate = { queryKey: devicesModuleKeys.detail(id), }), }, + /** Invalidate domainModule queries */ domainModule: { + /** Invalidate all domainModule queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: domainModuleKeys.all, + }), + /** Invalidate domainModule list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: domainModuleKeys.lists(), + }), + /** Invalidate a specific domainModule */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: domainModuleKeys.detail(id), + }), + }, /** Invalidate emailsModule queries */ emailsModule: { /** Invalidate all emailsModule queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -1019,6 +1093,23 @@ export const invalidate = { queryKey: rlsModuleKeys.detail(id), }), }, + /** Invalidate routeModule queries */ routeModule: { + /** Invalidate all routeModule queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: routeModuleKeys.all, + }), + /** Invalidate routeModule list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: routeModuleKeys.lists(), + }), + /** Invalidate a specific routeModule */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: routeModuleKeys.detail(id), + }), + }, /** Invalidate secureTableProvision queries */ secureTableProvision: { /** Invalidate all secureTableProvision queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -1070,6 +1161,23 @@ export const invalidate = { queryKey: sessionsModuleKeys.detail(id), }), }, + /** Invalidate siteSurfaceModule queries */ siteSurfaceModule: { + /** Invalidate all siteSurfaceModule queries */ all: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: siteSurfaceModuleKeys.all, + }), + /** Invalidate siteSurfaceModule list queries */ lists: (queryClient: QueryClient) => + queryClient.invalidateQueries({ + queryKey: siteSurfaceModuleKeys.lists(), + }), + /** Invalidate a specific siteSurfaceModule */ detail: ( + queryClient: QueryClient, + id: string | number + ) => + queryClient.invalidateQueries({ + queryKey: siteSurfaceModuleKeys.detail(id), + }), + }, /** Invalidate storageLogModule queries */ storageLogModule: { /** Invalidate all storageLogModule queries */ all: (queryClient: QueryClient) => queryClient.invalidateQueries({ @@ -1278,6 +1386,19 @@ export const remove = { queryKey: agentModuleKeys.detail(id), }); }, + /** Remove apiSurfaceModule from cache */ apiSurfaceModule: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: apiSurfaceModuleKeys.detail(id), + }); + }, + /** Remove appModule from cache */ appModule: (queryClient: QueryClient, id: string | number) => { + queryClient.removeQueries({ + queryKey: appModuleKeys.detail(id), + }); + }, /** Remove billingModule from cache */ billingModule: ( queryClient: QueryClient, id: string | number @@ -1315,6 +1436,14 @@ export const remove = { queryKey: blueprintTemplateKeys.detail(id), }); }, + /** Remove catalogModule from cache */ catalogModule: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: catalogModuleKeys.detail(id), + }); + }, /** Remove computeLogModule from cache */ computeLogModule: ( queryClient: QueryClient, id: string | number @@ -1416,6 +1545,14 @@ export const remove = { queryKey: devicesModuleKeys.detail(id), }); }, + /** Remove domainModule from cache */ domainModule: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: domainModuleKeys.detail(id), + }); + }, /** Remove emailsModule from cache */ emailsModule: ( queryClient: QueryClient, id: string | number @@ -1693,6 +1830,14 @@ export const remove = { queryKey: rlsModuleKeys.detail(id), }); }, + /** Remove routeModule from cache */ routeModule: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: routeModuleKeys.detail(id), + }); + }, /** Remove secureTableProvision from cache */ secureTableProvision: ( queryClient: QueryClient, id: string | number @@ -1717,6 +1862,14 @@ export const remove = { queryKey: sessionsModuleKeys.detail(id), }); }, + /** Remove siteSurfaceModule from cache */ siteSurfaceModule: ( + queryClient: QueryClient, + id: string | number + ) => { + queryClient.removeQueries({ + queryKey: siteSurfaceModuleKeys.detail(id), + }); + }, /** Remove storageLogModule from cache */ storageLogModule: ( queryClient: QueryClient, id: string | number diff --git a/sdk/constructive-react/src/modules/hooks/mutation-keys.ts b/sdk/constructive-react/src/modules/hooks/mutation-keys.ts index 64709f31d..9cb2803c2 100644 --- a/sdk/constructive-react/src/modules/hooks/mutation-keys.ts +++ b/sdk/constructive-react/src/modules/hooks/mutation-keys.ts @@ -27,6 +27,23 @@ export const agentModuleMutationKeys = { /** Delete agentModule mutation key */ delete: (id: string | number) => ['mutation', 'agentmodule', 'delete', id] as const, } as const; +export const apiSurfaceModuleMutationKeys = { + /** All apiSurfaceModule mutation keys */ all: ['mutation', 'apisurfacemodule'] as const, + /** Create apiSurfaceModule mutation key */ create: () => + ['mutation', 'apisurfacemodule', 'create'] as const, + /** Update apiSurfaceModule mutation key */ update: (id: string | number) => + ['mutation', 'apisurfacemodule', 'update', id] as const, + /** Delete apiSurfaceModule mutation key */ delete: (id: string | number) => + ['mutation', 'apisurfacemodule', 'delete', id] as const, +} as const; +export const appModuleMutationKeys = { + /** All appModule mutation keys */ all: ['mutation', 'appmodule'] as const, + /** Create appModule mutation key */ create: () => ['mutation', 'appmodule', 'create'] as const, + /** Update appModule mutation key */ update: (id: string | number) => + ['mutation', 'appmodule', 'update', id] as const, + /** Delete appModule mutation key */ delete: (id: string | number) => + ['mutation', 'appmodule', 'delete', id] as const, +} as const; export const billingModuleMutationKeys = { /** All billingModule mutation keys */ all: ['mutation', 'billingmodule'] as const, /** Create billingModule mutation key */ create: () => @@ -77,6 +94,15 @@ export const blueprintTemplateMutationKeys = { /** Delete blueprintTemplate mutation key */ delete: (id: string | number) => ['mutation', 'blueprinttemplate', 'delete', id] as const, } as const; +export const catalogModuleMutationKeys = { + /** All catalogModule mutation keys */ all: ['mutation', 'catalogmodule'] as const, + /** Create catalogModule mutation key */ create: () => + ['mutation', 'catalogmodule', 'create'] as const, + /** Update catalogModule mutation key */ update: (id: string | number) => + ['mutation', 'catalogmodule', 'update', id] as const, + /** Delete catalogModule mutation key */ delete: (id: string | number) => + ['mutation', 'catalogmodule', 'delete', id] as const, +} as const; export const computeLogModuleMutationKeys = { /** All computeLogModule mutation keys */ all: ['mutation', 'computelogmodule'] as const, /** Create computeLogModule mutation key */ create: () => @@ -208,6 +234,15 @@ export const devicesModuleMutationKeys = { /** Delete devicesModule mutation key */ delete: (id: string | number) => ['mutation', 'devicesmodule', 'delete', id] as const, } as const; +export const domainModuleMutationKeys = { + /** All domainModule mutation keys */ all: ['mutation', 'domainmodule'] as const, + /** Create domainModule mutation key */ create: () => + ['mutation', 'domainmodule', 'create'] as const, + /** Update domainModule mutation key */ update: (id: string | number) => + ['mutation', 'domainmodule', 'update', id] as const, + /** Delete domainModule mutation key */ delete: (id: string | number) => + ['mutation', 'domainmodule', 'delete', id] as const, +} as const; export const emailsModuleMutationKeys = { /** All emailsModule mutation keys */ all: ['mutation', 'emailsmodule'] as const, /** Create emailsModule mutation key */ create: () => @@ -542,6 +577,15 @@ export const rlsModuleMutationKeys = { /** Delete rlsModule mutation key */ delete: (id: string | number) => ['mutation', 'rlsmodule', 'delete', id] as const, } as const; +export const routeModuleMutationKeys = { + /** All routeModule mutation keys */ all: ['mutation', 'routemodule'] as const, + /** Create routeModule mutation key */ create: () => + ['mutation', 'routemodule', 'create'] as const, + /** Update routeModule mutation key */ update: (id: string | number) => + ['mutation', 'routemodule', 'update', id] as const, + /** Delete routeModule mutation key */ delete: (id: string | number) => + ['mutation', 'routemodule', 'delete', id] as const, +} as const; export const secureTableProvisionMutationKeys = { /** All secureTableProvision mutation keys */ all: ['mutation', 'securetableprovision'] as const, /** Create secureTableProvision mutation key */ create: () => @@ -569,6 +613,15 @@ export const sessionsModuleMutationKeys = { /** Delete sessionsModule mutation key */ delete: (id: string | number) => ['mutation', 'sessionsmodule', 'delete', id] as const, } as const; +export const siteSurfaceModuleMutationKeys = { + /** All siteSurfaceModule mutation keys */ all: ['mutation', 'sitesurfacemodule'] as const, + /** Create siteSurfaceModule mutation key */ create: () => + ['mutation', 'sitesurfacemodule', 'create'] as const, + /** Update siteSurfaceModule mutation key */ update: (id: string | number) => + ['mutation', 'sitesurfacemodule', 'update', id] as const, + /** Delete siteSurfaceModule mutation key */ delete: (id: string | number) => + ['mutation', 'sitesurfacemodule', 'delete', id] as const, +} as const; export const storageLogModuleMutationKeys = { /** All storageLogModule mutation keys */ all: ['mutation', 'storagelogmodule'] as const, /** Create storageLogModule mutation key */ create: () => @@ -751,11 +804,14 @@ export const customMutationKeys = { */ export const mutationKeys = { agentModule: agentModuleMutationKeys, + apiSurfaceModule: apiSurfaceModuleMutationKeys, + appModule: appModuleMutationKeys, billingModule: billingModuleMutationKeys, billingProviderModule: billingProviderModuleMutationKeys, blueprint: blueprintMutationKeys, blueprintConstruction: blueprintConstructionMutationKeys, blueprintTemplate: blueprintTemplateMutationKeys, + catalogModule: catalogModuleMutationKeys, computeLogModule: computeLogModuleMutationKeys, configSecretsUserModule: configSecretsUserModuleMutationKeys, connectedAccountsModule: connectedAccountsModuleMutationKeys, @@ -769,6 +825,7 @@ export const mutationKeys = { defaultIdsModule: defaultIdsModuleMutationKeys, denormalizedTableField: denormalizedTableFieldMutationKeys, devicesModule: devicesModuleMutationKeys, + domainModule: domainModuleMutationKeys, emailsModule: emailsModuleMutationKeys, entityTypeProvision: entityTypeProvisionMutationKeys, eventsModule: eventsModuleMutationKeys, @@ -804,9 +861,11 @@ export const mutationKeys = { relationProvision: relationProvisionMutationKeys, resourceModule: resourceModuleMutationKeys, rlsModule: rlsModuleMutationKeys, + routeModule: routeModuleMutationKeys, secureTableProvision: secureTableProvisionMutationKeys, sessionSecretsModule: sessionSecretsModuleMutationKeys, sessionsModule: sessionsModuleMutationKeys, + siteSurfaceModule: siteSurfaceModuleMutationKeys, storageLogModule: storageLogModuleMutationKeys, storageModule: storageModuleMutationKeys, transferLogModule: transferLogModuleMutationKeys, diff --git a/sdk/constructive-react/src/modules/hooks/mutations/index.ts b/sdk/constructive-react/src/modules/hooks/mutations/index.ts index fbd1927e6..427448ece 100644 --- a/sdk/constructive-react/src/modules/hooks/mutations/index.ts +++ b/sdk/constructive-react/src/modules/hooks/mutations/index.ts @@ -6,6 +6,12 @@ export * from './useCreateAgentModuleMutation'; export * from './useUpdateAgentModuleMutation'; export * from './useDeleteAgentModuleMutation'; +export * from './useCreateApiSurfaceModuleMutation'; +export * from './useUpdateApiSurfaceModuleMutation'; +export * from './useDeleteApiSurfaceModuleMutation'; +export * from './useCreateAppModuleMutation'; +export * from './useUpdateAppModuleMutation'; +export * from './useDeleteAppModuleMutation'; export * from './useCreateBillingModuleMutation'; export * from './useUpdateBillingModuleMutation'; export * from './useDeleteBillingModuleMutation'; @@ -21,6 +27,9 @@ export * from './useDeleteBlueprintConstructionMutation'; export * from './useCreateBlueprintTemplateMutation'; export * from './useUpdateBlueprintTemplateMutation'; export * from './useDeleteBlueprintTemplateMutation'; +export * from './useCreateCatalogModuleMutation'; +export * from './useUpdateCatalogModuleMutation'; +export * from './useDeleteCatalogModuleMutation'; export * from './useCreateComputeLogModuleMutation'; export * from './useUpdateComputeLogModuleMutation'; export * from './useDeleteComputeLogModuleMutation'; @@ -60,6 +69,9 @@ export * from './useDeleteDenormalizedTableFieldMutation'; export * from './useCreateDevicesModuleMutation'; export * from './useUpdateDevicesModuleMutation'; export * from './useDeleteDevicesModuleMutation'; +export * from './useCreateDomainModuleMutation'; +export * from './useUpdateDomainModuleMutation'; +export * from './useDeleteDomainModuleMutation'; export * from './useCreateEmailsModuleMutation'; export * from './useUpdateEmailsModuleMutation'; export * from './useDeleteEmailsModuleMutation'; @@ -165,6 +177,9 @@ export * from './useDeleteResourceModuleMutation'; export * from './useCreateRlsModuleMutation'; export * from './useUpdateRlsModuleMutation'; export * from './useDeleteRlsModuleMutation'; +export * from './useCreateRouteModuleMutation'; +export * from './useUpdateRouteModuleMutation'; +export * from './useDeleteRouteModuleMutation'; export * from './useCreateSecureTableProvisionMutation'; export * from './useUpdateSecureTableProvisionMutation'; export * from './useDeleteSecureTableProvisionMutation'; @@ -174,6 +189,9 @@ export * from './useDeleteSessionSecretsModuleMutation'; export * from './useCreateSessionsModuleMutation'; export * from './useUpdateSessionsModuleMutation'; export * from './useDeleteSessionsModuleMutation'; +export * from './useCreateSiteSurfaceModuleMutation'; +export * from './useUpdateSiteSurfaceModuleMutation'; +export * from './useDeleteSiteSurfaceModuleMutation'; export * from './useCreateStorageLogModuleMutation'; export * from './useUpdateStorageLogModuleMutation'; export * from './useDeleteStorageLogModuleMutation'; diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useCreateApiSurfaceModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useCreateApiSurfaceModuleMutation.ts new file mode 100644 index 000000000..2ab626bc2 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useCreateApiSurfaceModuleMutation.ts @@ -0,0 +1,91 @@ +/** + * Create mutation hook for ApiSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { apiSurfaceModuleKeys } from '../query-keys'; +import { apiSurfaceModuleMutationKeys } from '../mutation-keys'; +import type { + ApiSurfaceModuleSelect, + ApiSurfaceModuleWithRelations, + CreateApiSurfaceModuleInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + ApiSurfaceModuleSelect, + ApiSurfaceModuleWithRelations, + CreateApiSurfaceModuleInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a ApiSurfaceModule + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateApiSurfaceModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateApiSurfaceModuleMutation( + params: { + selection: { + fields: S & ApiSurfaceModuleSelect; + } & HookStrictSelect, ApiSurfaceModuleSelect>; + } & Omit< + UseMutationOptions< + { + createApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }, + Error, + CreateApiSurfaceModuleInput['apiSurfaceModule'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }, + Error, + CreateApiSurfaceModuleInput['apiSurfaceModule'] +>; +export function useCreateApiSurfaceModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: apiSurfaceModuleMutationKeys.create(), + mutationFn: (data: CreateApiSurfaceModuleInput['apiSurfaceModule']) => + getClient() + .apiSurfaceModule.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: apiSurfaceModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useCreateAppModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useCreateAppModuleMutation.ts new file mode 100644 index 000000000..90f8611d8 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useCreateAppModuleMutation.ts @@ -0,0 +1,88 @@ +/** + * Create mutation hook for AppModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { appModuleKeys } from '../query-keys'; +import { appModuleMutationKeys } from '../mutation-keys'; +import type { + AppModuleSelect, + AppModuleWithRelations, + CreateAppModuleInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + AppModuleSelect, + AppModuleWithRelations, + CreateAppModuleInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a AppModule + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateAppModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateAppModuleMutation( + params: { + selection: { + fields: S & AppModuleSelect; + } & HookStrictSelect, AppModuleSelect>; + } & Omit< + UseMutationOptions< + { + createAppModule: { + appModule: InferSelectResult; + }; + }, + Error, + CreateAppModuleInput['appModule'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createAppModule: { + appModule: InferSelectResult; + }; + }, + Error, + CreateAppModuleInput['appModule'] +>; +export function useCreateAppModuleMutation( + params: { + selection: SelectionConfig; + } & Omit, 'mutationFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: appModuleMutationKeys.create(), + mutationFn: (data: CreateAppModuleInput['appModule']) => + getClient() + .appModule.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: appModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useCreateCatalogModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useCreateCatalogModuleMutation.ts new file mode 100644 index 000000000..d4c350fe1 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useCreateCatalogModuleMutation.ts @@ -0,0 +1,88 @@ +/** + * Create mutation hook for CatalogModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { catalogModuleKeys } from '../query-keys'; +import { catalogModuleMutationKeys } from '../mutation-keys'; +import type { + CatalogModuleSelect, + CatalogModuleWithRelations, + CreateCatalogModuleInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + CatalogModuleSelect, + CatalogModuleWithRelations, + CreateCatalogModuleInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a CatalogModule + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateCatalogModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateCatalogModuleMutation( + params: { + selection: { + fields: S & CatalogModuleSelect; + } & HookStrictSelect, CatalogModuleSelect>; + } & Omit< + UseMutationOptions< + { + createCatalogModule: { + catalogModule: InferSelectResult; + }; + }, + Error, + CreateCatalogModuleInput['catalogModule'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createCatalogModule: { + catalogModule: InferSelectResult; + }; + }, + Error, + CreateCatalogModuleInput['catalogModule'] +>; +export function useCreateCatalogModuleMutation( + params: { + selection: SelectionConfig; + } & Omit, 'mutationFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: catalogModuleMutationKeys.create(), + mutationFn: (data: CreateCatalogModuleInput['catalogModule']) => + getClient() + .catalogModule.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: catalogModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useCreateDomainModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useCreateDomainModuleMutation.ts new file mode 100644 index 000000000..374bd40ee --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useCreateDomainModuleMutation.ts @@ -0,0 +1,88 @@ +/** + * Create mutation hook for DomainModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainModuleKeys } from '../query-keys'; +import { domainModuleMutationKeys } from '../mutation-keys'; +import type { + DomainModuleSelect, + DomainModuleWithRelations, + CreateDomainModuleInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainModuleSelect, + DomainModuleWithRelations, + CreateDomainModuleInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a DomainModule + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateDomainModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateDomainModuleMutation( + params: { + selection: { + fields: S & DomainModuleSelect; + } & HookStrictSelect, DomainModuleSelect>; + } & Omit< + UseMutationOptions< + { + createDomainModule: { + domainModule: InferSelectResult; + }; + }, + Error, + CreateDomainModuleInput['domainModule'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createDomainModule: { + domainModule: InferSelectResult; + }; + }, + Error, + CreateDomainModuleInput['domainModule'] +>; +export function useCreateDomainModuleMutation( + params: { + selection: SelectionConfig; + } & Omit, 'mutationFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainModuleMutationKeys.create(), + mutationFn: (data: CreateDomainModuleInput['domainModule']) => + getClient() + .domainModule.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: domainModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useCreateRouteModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useCreateRouteModuleMutation.ts new file mode 100644 index 000000000..9be35da4c --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useCreateRouteModuleMutation.ts @@ -0,0 +1,88 @@ +/** + * Create mutation hook for RouteModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { routeModuleKeys } from '../query-keys'; +import { routeModuleMutationKeys } from '../mutation-keys'; +import type { + RouteModuleSelect, + RouteModuleWithRelations, + CreateRouteModuleInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + RouteModuleSelect, + RouteModuleWithRelations, + CreateRouteModuleInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a RouteModule + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateRouteModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateRouteModuleMutation( + params: { + selection: { + fields: S & RouteModuleSelect; + } & HookStrictSelect, RouteModuleSelect>; + } & Omit< + UseMutationOptions< + { + createRouteModule: { + routeModule: InferSelectResult; + }; + }, + Error, + CreateRouteModuleInput['routeModule'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createRouteModule: { + routeModule: InferSelectResult; + }; + }, + Error, + CreateRouteModuleInput['routeModule'] +>; +export function useCreateRouteModuleMutation( + params: { + selection: SelectionConfig; + } & Omit, 'mutationFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: routeModuleMutationKeys.create(), + mutationFn: (data: CreateRouteModuleInput['routeModule']) => + getClient() + .routeModule.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: routeModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useCreateSiteSurfaceModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useCreateSiteSurfaceModuleMutation.ts new file mode 100644 index 000000000..970ed5a3e --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useCreateSiteSurfaceModuleMutation.ts @@ -0,0 +1,91 @@ +/** + * Create mutation hook for SiteSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { siteSurfaceModuleKeys } from '../query-keys'; +import { siteSurfaceModuleMutationKeys } from '../mutation-keys'; +import type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, + CreateSiteSurfaceModuleInput, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, + CreateSiteSurfaceModuleInput, +} from '../../orm/input-types'; +/** + * Mutation hook for creating a SiteSurfaceModule + * + * @example + * ```tsx + * const { mutate, isPending } = useCreateSiteSurfaceModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ name: 'New item' }); + * ``` + */ +export function useCreateSiteSurfaceModuleMutation( + params: { + selection: { + fields: S & SiteSurfaceModuleSelect; + } & HookStrictSelect, SiteSurfaceModuleSelect>; + } & Omit< + UseMutationOptions< + { + createSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }, + Error, + CreateSiteSurfaceModuleInput['siteSurfaceModule'] + >, + 'mutationFn' + > +): UseMutationResult< + { + createSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }, + Error, + CreateSiteSurfaceModuleInput['siteSurfaceModule'] +>; +export function useCreateSiteSurfaceModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: siteSurfaceModuleMutationKeys.create(), + mutationFn: (data: CreateSiteSurfaceModuleInput['siteSurfaceModule']) => + getClient() + .siteSurfaceModule.create({ + data, + select: args.select, + }) + .unwrap(), + onSuccess: () => { + queryClient.invalidateQueries({ + queryKey: siteSurfaceModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useDeleteApiSurfaceModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteApiSurfaceModuleMutation.ts new file mode 100644 index 000000000..b0c2fa559 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteApiSurfaceModuleMutation.ts @@ -0,0 +1,98 @@ +/** + * Delete mutation hook for ApiSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { apiSurfaceModuleKeys } from '../query-keys'; +import { apiSurfaceModuleMutationKeys } from '../mutation-keys'; +import type { ApiSurfaceModuleSelect, ApiSurfaceModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { ApiSurfaceModuleSelect, ApiSurfaceModuleWithRelations } from '../../orm/input-types'; +/** + * Mutation hook for deleting a ApiSurfaceModule with typed selection + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteApiSurfaceModuleMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteApiSurfaceModuleMutation( + params: { + selection: { + fields: S & ApiSurfaceModuleSelect; + } & HookStrictSelect, ApiSurfaceModuleSelect>; + } & Omit< + UseMutationOptions< + { + deleteApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteApiSurfaceModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: apiSurfaceModuleMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .apiSurfaceModule.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: apiSurfaceModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: apiSurfaceModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useDeleteAppModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteAppModuleMutation.ts new file mode 100644 index 000000000..b05a9740c --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteAppModuleMutation.ts @@ -0,0 +1,98 @@ +/** + * Delete mutation hook for AppModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { appModuleKeys } from '../query-keys'; +import { appModuleMutationKeys } from '../mutation-keys'; +import type { AppModuleSelect, AppModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { AppModuleSelect, AppModuleWithRelations } from '../../orm/input-types'; +/** + * Mutation hook for deleting a AppModule with typed selection + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteAppModuleMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteAppModuleMutation( + params: { + selection: { + fields: S & AppModuleSelect; + } & HookStrictSelect, AppModuleSelect>; + } & Omit< + UseMutationOptions< + { + deleteAppModule: { + appModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteAppModule: { + appModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteAppModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: appModuleMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .appModule.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: appModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: appModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useDeleteCatalogModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteCatalogModuleMutation.ts new file mode 100644 index 000000000..a36f0a01e --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteCatalogModuleMutation.ts @@ -0,0 +1,98 @@ +/** + * Delete mutation hook for CatalogModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { catalogModuleKeys } from '../query-keys'; +import { catalogModuleMutationKeys } from '../mutation-keys'; +import type { CatalogModuleSelect, CatalogModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { CatalogModuleSelect, CatalogModuleWithRelations } from '../../orm/input-types'; +/** + * Mutation hook for deleting a CatalogModule with typed selection + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteCatalogModuleMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteCatalogModuleMutation( + params: { + selection: { + fields: S & CatalogModuleSelect; + } & HookStrictSelect, CatalogModuleSelect>; + } & Omit< + UseMutationOptions< + { + deleteCatalogModule: { + catalogModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteCatalogModule: { + catalogModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteCatalogModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: catalogModuleMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .catalogModule.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: catalogModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: catalogModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useDeleteDomainModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteDomainModuleMutation.ts new file mode 100644 index 000000000..913cb1d10 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteDomainModuleMutation.ts @@ -0,0 +1,98 @@ +/** + * Delete mutation hook for DomainModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainModuleKeys } from '../query-keys'; +import { domainModuleMutationKeys } from '../mutation-keys'; +import type { DomainModuleSelect, DomainModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { DomainModuleSelect, DomainModuleWithRelations } from '../../orm/input-types'; +/** + * Mutation hook for deleting a DomainModule with typed selection + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteDomainModuleMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteDomainModuleMutation( + params: { + selection: { + fields: S & DomainModuleSelect; + } & HookStrictSelect, DomainModuleSelect>; + } & Omit< + UseMutationOptions< + { + deleteDomainModule: { + domainModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteDomainModule: { + domainModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteDomainModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainModuleMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .domainModule.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: domainModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: domainModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useDeleteRouteModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteRouteModuleMutation.ts new file mode 100644 index 000000000..faa5faa44 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteRouteModuleMutation.ts @@ -0,0 +1,98 @@ +/** + * Delete mutation hook for RouteModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { routeModuleKeys } from '../query-keys'; +import { routeModuleMutationKeys } from '../mutation-keys'; +import type { RouteModuleSelect, RouteModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { RouteModuleSelect, RouteModuleWithRelations } from '../../orm/input-types'; +/** + * Mutation hook for deleting a RouteModule with typed selection + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteRouteModuleMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteRouteModuleMutation( + params: { + selection: { + fields: S & RouteModuleSelect; + } & HookStrictSelect, RouteModuleSelect>; + } & Omit< + UseMutationOptions< + { + deleteRouteModule: { + routeModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteRouteModule: { + routeModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteRouteModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: routeModuleMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .routeModule.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: routeModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: routeModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useDeleteSiteSurfaceModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteSiteSurfaceModuleMutation.ts new file mode 100644 index 000000000..b0efea4d2 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useDeleteSiteSurfaceModuleMutation.ts @@ -0,0 +1,104 @@ +/** + * Delete mutation hook for SiteSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { siteSurfaceModuleKeys } from '../query-keys'; +import { siteSurfaceModuleMutationKeys } from '../mutation-keys'; +import type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, +} from '../../orm/input-types'; +/** + * Mutation hook for deleting a SiteSurfaceModule with typed selection + * + * @example + * ```tsx + * const { mutate, isPending } = useDeleteSiteSurfaceModuleMutation({ + * selection: { fields: { id: true } }, + * }); + * + * mutate({ id: 'value-to-delete' }); + * ``` + */ +export function useDeleteSiteSurfaceModuleMutation( + params: { + selection: { + fields: S & SiteSurfaceModuleSelect; + } & HookStrictSelect, SiteSurfaceModuleSelect>; + } & Omit< + UseMutationOptions< + { + deleteSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + deleteSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + } +>; +export function useDeleteSiteSurfaceModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: siteSurfaceModuleMutationKeys.all, + mutationFn: ({ id }: { id: string }) => + getClient() + .siteSurfaceModule.delete({ + where: { + id, + }, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.removeQueries({ + queryKey: siteSurfaceModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: siteSurfaceModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useUpdateApiSurfaceModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateApiSurfaceModuleMutation.ts new file mode 100644 index 000000000..e31598616 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateApiSurfaceModuleMutation.ts @@ -0,0 +1,116 @@ +/** + * Update mutation hook for ApiSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { apiSurfaceModuleKeys } from '../query-keys'; +import { apiSurfaceModuleMutationKeys } from '../mutation-keys'; +import type { + ApiSurfaceModuleSelect, + ApiSurfaceModuleWithRelations, + ApiSurfaceModulePatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + ApiSurfaceModuleSelect, + ApiSurfaceModuleWithRelations, + ApiSurfaceModulePatch, +} from '../../orm/input-types'; +/** + * Mutation hook for updating a ApiSurfaceModule + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateApiSurfaceModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', apiSurfaceModulePatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateApiSurfaceModuleMutation( + params: { + selection: { + fields: S & ApiSurfaceModuleSelect; + } & HookStrictSelect, ApiSurfaceModuleSelect>; + } & Omit< + UseMutationOptions< + { + updateApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + apiSurfaceModulePatch: ApiSurfaceModulePatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + apiSurfaceModulePatch: ApiSurfaceModulePatch; + } +>; +export function useUpdateApiSurfaceModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + apiSurfaceModulePatch: ApiSurfaceModulePatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: apiSurfaceModuleMutationKeys.all, + mutationFn: ({ + id, + apiSurfaceModulePatch, + }: { + id: string; + apiSurfaceModulePatch: ApiSurfaceModulePatch; + }) => + getClient() + .apiSurfaceModule.update({ + where: { + id, + }, + data: apiSurfaceModulePatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: apiSurfaceModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: apiSurfaceModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useUpdateAppModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateAppModuleMutation.ts new file mode 100644 index 000000000..28ee09acf --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateAppModuleMutation.ts @@ -0,0 +1,110 @@ +/** + * Update mutation hook for AppModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { appModuleKeys } from '../query-keys'; +import { appModuleMutationKeys } from '../mutation-keys'; +import type { + AppModuleSelect, + AppModuleWithRelations, + AppModulePatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + AppModuleSelect, + AppModuleWithRelations, + AppModulePatch, +} from '../../orm/input-types'; +/** + * Mutation hook for updating a AppModule + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateAppModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', appModulePatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateAppModuleMutation( + params: { + selection: { + fields: S & AppModuleSelect; + } & HookStrictSelect, AppModuleSelect>; + } & Omit< + UseMutationOptions< + { + updateAppModule: { + appModule: InferSelectResult; + }; + }, + Error, + { + id: string; + appModulePatch: AppModulePatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateAppModule: { + appModule: InferSelectResult; + }; + }, + Error, + { + id: string; + appModulePatch: AppModulePatch; + } +>; +export function useUpdateAppModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + appModulePatch: AppModulePatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: appModuleMutationKeys.all, + mutationFn: ({ id, appModulePatch }: { id: string; appModulePatch: AppModulePatch }) => + getClient() + .appModule.update({ + where: { + id, + }, + data: appModulePatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: appModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: appModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useUpdateCatalogModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateCatalogModuleMutation.ts new file mode 100644 index 000000000..0d6f90652 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateCatalogModuleMutation.ts @@ -0,0 +1,116 @@ +/** + * Update mutation hook for CatalogModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { catalogModuleKeys } from '../query-keys'; +import { catalogModuleMutationKeys } from '../mutation-keys'; +import type { + CatalogModuleSelect, + CatalogModuleWithRelations, + CatalogModulePatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + CatalogModuleSelect, + CatalogModuleWithRelations, + CatalogModulePatch, +} from '../../orm/input-types'; +/** + * Mutation hook for updating a CatalogModule + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateCatalogModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', catalogModulePatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateCatalogModuleMutation( + params: { + selection: { + fields: S & CatalogModuleSelect; + } & HookStrictSelect, CatalogModuleSelect>; + } & Omit< + UseMutationOptions< + { + updateCatalogModule: { + catalogModule: InferSelectResult; + }; + }, + Error, + { + id: string; + catalogModulePatch: CatalogModulePatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateCatalogModule: { + catalogModule: InferSelectResult; + }; + }, + Error, + { + id: string; + catalogModulePatch: CatalogModulePatch; + } +>; +export function useUpdateCatalogModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + catalogModulePatch: CatalogModulePatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: catalogModuleMutationKeys.all, + mutationFn: ({ + id, + catalogModulePatch, + }: { + id: string; + catalogModulePatch: CatalogModulePatch; + }) => + getClient() + .catalogModule.update({ + where: { + id, + }, + data: catalogModulePatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: catalogModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: catalogModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useUpdateDomainModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateDomainModuleMutation.ts new file mode 100644 index 000000000..4b8058997 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateDomainModuleMutation.ts @@ -0,0 +1,110 @@ +/** + * Update mutation hook for DomainModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainModuleKeys } from '../query-keys'; +import { domainModuleMutationKeys } from '../mutation-keys'; +import type { + DomainModuleSelect, + DomainModuleWithRelations, + DomainModulePatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + DomainModuleSelect, + DomainModuleWithRelations, + DomainModulePatch, +} from '../../orm/input-types'; +/** + * Mutation hook for updating a DomainModule + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateDomainModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', domainModulePatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateDomainModuleMutation( + params: { + selection: { + fields: S & DomainModuleSelect; + } & HookStrictSelect, DomainModuleSelect>; + } & Omit< + UseMutationOptions< + { + updateDomainModule: { + domainModule: InferSelectResult; + }; + }, + Error, + { + id: string; + domainModulePatch: DomainModulePatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateDomainModule: { + domainModule: InferSelectResult; + }; + }, + Error, + { + id: string; + domainModulePatch: DomainModulePatch; + } +>; +export function useUpdateDomainModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + domainModulePatch: DomainModulePatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: domainModuleMutationKeys.all, + mutationFn: ({ id, domainModulePatch }: { id: string; domainModulePatch: DomainModulePatch }) => + getClient() + .domainModule.update({ + where: { + id, + }, + data: domainModulePatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: domainModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: domainModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useUpdateRouteModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateRouteModuleMutation.ts new file mode 100644 index 000000000..5ccf5b0b5 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateRouteModuleMutation.ts @@ -0,0 +1,110 @@ +/** + * Update mutation hook for RouteModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { routeModuleKeys } from '../query-keys'; +import { routeModuleMutationKeys } from '../mutation-keys'; +import type { + RouteModuleSelect, + RouteModuleWithRelations, + RouteModulePatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + RouteModuleSelect, + RouteModuleWithRelations, + RouteModulePatch, +} from '../../orm/input-types'; +/** + * Mutation hook for updating a RouteModule + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateRouteModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', routeModulePatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateRouteModuleMutation( + params: { + selection: { + fields: S & RouteModuleSelect; + } & HookStrictSelect, RouteModuleSelect>; + } & Omit< + UseMutationOptions< + { + updateRouteModule: { + routeModule: InferSelectResult; + }; + }, + Error, + { + id: string; + routeModulePatch: RouteModulePatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateRouteModule: { + routeModule: InferSelectResult; + }; + }, + Error, + { + id: string; + routeModulePatch: RouteModulePatch; + } +>; +export function useUpdateRouteModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + routeModulePatch: RouteModulePatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: routeModuleMutationKeys.all, + mutationFn: ({ id, routeModulePatch }: { id: string; routeModulePatch: RouteModulePatch }) => + getClient() + .routeModule.update({ + where: { + id, + }, + data: routeModulePatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: routeModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: routeModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/mutations/useUpdateSiteSurfaceModuleMutation.ts b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateSiteSurfaceModuleMutation.ts new file mode 100644 index 000000000..2379cf446 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/mutations/useUpdateSiteSurfaceModuleMutation.ts @@ -0,0 +1,116 @@ +/** + * Update mutation hook for SiteSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useMutation, useQueryClient } from '@tanstack/react-query'; +import type { UseMutationOptions, UseMutationResult } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { siteSurfaceModuleKeys } from '../query-keys'; +import { siteSurfaceModuleMutationKeys } from '../mutation-keys'; +import type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, + SiteSurfaceModulePatch, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, + SiteSurfaceModulePatch, +} from '../../orm/input-types'; +/** + * Mutation hook for updating a SiteSurfaceModule + * + * @example + * ```tsx + * const { mutate, isPending } = useUpdateSiteSurfaceModuleMutation({ + * selection: { fields: { id: true, name: true } }, + * }); + * + * mutate({ id: 'value-here', siteSurfaceModulePatch: { name: 'Updated' } }); + * ``` + */ +export function useUpdateSiteSurfaceModuleMutation( + params: { + selection: { + fields: S & SiteSurfaceModuleSelect; + } & HookStrictSelect, SiteSurfaceModuleSelect>; + } & Omit< + UseMutationOptions< + { + updateSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + siteSurfaceModulePatch: SiteSurfaceModulePatch; + } + >, + 'mutationFn' + > +): UseMutationResult< + { + updateSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }, + Error, + { + id: string; + siteSurfaceModulePatch: SiteSurfaceModulePatch; + } +>; +export function useUpdateSiteSurfaceModuleMutation( + params: { + selection: SelectionConfig; + } & Omit< + UseMutationOptions< + any, + Error, + { + id: string; + siteSurfaceModulePatch: SiteSurfaceModulePatch; + } + >, + 'mutationFn' + > +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...mutationOptions } = params ?? {}; + void _selection; + const queryClient = useQueryClient(); + return useMutation({ + mutationKey: siteSurfaceModuleMutationKeys.all, + mutationFn: ({ + id, + siteSurfaceModulePatch, + }: { + id: string; + siteSurfaceModulePatch: SiteSurfaceModulePatch; + }) => + getClient() + .siteSurfaceModule.update({ + where: { + id, + }, + data: siteSurfaceModulePatch, + select: args.select, + }) + .unwrap(), + onSuccess: (_, variables) => { + queryClient.invalidateQueries({ + queryKey: siteSurfaceModuleKeys.detail(variables.id), + }); + queryClient.invalidateQueries({ + queryKey: siteSurfaceModuleKeys.lists(), + }); + }, + ...mutationOptions, + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/index.ts b/sdk/constructive-react/src/modules/hooks/queries/index.ts index 78d8c6a86..87a1c8596 100644 --- a/sdk/constructive-react/src/modules/hooks/queries/index.ts +++ b/sdk/constructive-react/src/modules/hooks/queries/index.ts @@ -5,6 +5,10 @@ */ export * from './useAgentModulesQuery'; export * from './useAgentModuleQuery'; +export * from './useApiSurfaceModulesQuery'; +export * from './useApiSurfaceModuleQuery'; +export * from './useAppModulesQuery'; +export * from './useAppModuleQuery'; export * from './useBillingModulesQuery'; export * from './useBillingModuleQuery'; export * from './useBillingProviderModulesQuery'; @@ -15,6 +19,8 @@ export * from './useBlueprintConstructionsQuery'; export * from './useBlueprintConstructionQuery'; export * from './useBlueprintTemplatesQuery'; export * from './useBlueprintTemplateQuery'; +export * from './useCatalogModulesQuery'; +export * from './useCatalogModuleQuery'; export * from './useComputeLogModulesQuery'; export * from './useComputeLogModuleQuery'; export * from './useConfigSecretsUserModulesQuery'; @@ -41,6 +47,8 @@ export * from './useDenormalizedTableFieldsQuery'; export * from './useDenormalizedTableFieldQuery'; export * from './useDevicesModulesQuery'; export * from './useDevicesModuleQuery'; +export * from './useDomainModulesQuery'; +export * from './useDomainModuleQuery'; export * from './useEmailsModulesQuery'; export * from './useEmailsModuleQuery'; export * from './useEntityTypeProvisionsQuery'; @@ -111,12 +119,16 @@ export * from './useResourceModulesQuery'; export * from './useResourceModuleQuery'; export * from './useRlsModulesQuery'; export * from './useRlsModuleQuery'; +export * from './useRouteModulesQuery'; +export * from './useRouteModuleQuery'; export * from './useSecureTableProvisionsQuery'; export * from './useSecureTableProvisionQuery'; export * from './useSessionSecretsModulesQuery'; export * from './useSessionSecretsModuleQuery'; export * from './useSessionsModulesQuery'; export * from './useSessionsModuleQuery'; +export * from './useSiteSurfaceModulesQuery'; +export * from './useSiteSurfaceModuleQuery'; export * from './useStorageLogModulesQuery'; export * from './useStorageLogModuleQuery'; export * from './useStorageModulesQuery'; diff --git a/sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModuleQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModuleQuery.ts new file mode 100644 index 000000000..873a8e3a4 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModuleQuery.ts @@ -0,0 +1,138 @@ +/** + * Single item query hook for ApiSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { apiSurfaceModuleKeys } from '../query-keys'; +import type { ApiSurfaceModuleSelect, ApiSurfaceModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { ApiSurfaceModuleSelect, ApiSurfaceModuleWithRelations } from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const apiSurfaceModuleQueryKey = apiSurfaceModuleKeys.detail; +/** + * Query hook for fetching a single ApiSurfaceModule + * + * @example + * ```tsx + * const { data, isLoading } = useApiSurfaceModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useApiSurfaceModuleQuery< + S extends ApiSurfaceModuleSelect, + TData = { + apiSurfaceModule: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, ApiSurfaceModuleSelect>; + } & Omit< + UseQueryOptions< + { + apiSurfaceModule: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useApiSurfaceModuleQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: apiSurfaceModuleKeys.detail(params.id), + queryFn: () => + getClient() + .apiSurfaceModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Fetch a single ApiSurfaceModule without React hooks + * + * @example + * ```ts + * const data = await fetchApiSurfaceModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchApiSurfaceModuleQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, ApiSurfaceModuleSelect>; +}): Promise<{ + apiSurfaceModule: InferSelectResult | null; +}>; +export async function fetchApiSurfaceModuleQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .apiSurfaceModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Prefetch a single ApiSurfaceModule for SSR or cache warming + * + * @example + * ```ts + * await prefetchApiSurfaceModuleQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchApiSurfaceModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, ApiSurfaceModuleSelect>; + } +): Promise; +export async function prefetchApiSurfaceModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: apiSurfaceModuleKeys.detail(params.id), + queryFn: () => + getClient() + .apiSurfaceModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModulesQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModulesQuery.ts new file mode 100644 index 000000000..5b21fbdbe --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useApiSurfaceModulesQuery.ts @@ -0,0 +1,163 @@ +/** + * List query hook for ApiSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { apiSurfaceModuleKeys } from '../query-keys'; +import type { + ApiSurfaceModuleSelect, + ApiSurfaceModuleWithRelations, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + ApiSurfaceModuleSelect, + ApiSurfaceModuleWithRelations, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const apiSurfaceModulesQueryKey = apiSurfaceModuleKeys.list; +/** + * Query hook for fetching ApiSurfaceModule list + * + * @example + * ```tsx + * const { data, isLoading } = useApiSurfaceModulesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useApiSurfaceModulesQuery< + S extends ApiSurfaceModuleSelect, + TData = { + apiSurfaceModules: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, ApiSurfaceModuleSelect>; + } & Omit< + UseQueryOptions< + { + apiSurfaceModules: ConnectionResult>; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useApiSurfaceModulesQuery( + params: { + selection: ListSelectionConfig< + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: apiSurfaceModuleKeys.list(args), + queryFn: () => getClient().apiSurfaceModule.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch ApiSurfaceModule list without React hooks + * + * @example + * ```ts + * const data = await fetchApiSurfaceModulesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchApiSurfaceModulesQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, ApiSurfaceModuleSelect>; +}): Promise<{ + apiSurfaceModules: ConnectionResult>; +}>; +export async function fetchApiSurfaceModulesQuery(params: { + selection: ListSelectionConfig< + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy + >; +}) { + const args = buildListSelectionArgs< + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy + >(params.selection); + return getClient().apiSurfaceModule.findMany(args).unwrap(); +} +/** + * Prefetch ApiSurfaceModule list for SSR or cache warming + * + * @example + * ```ts + * await prefetchApiSurfaceModulesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchApiSurfaceModulesQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, ApiSurfaceModuleSelect>; + } +): Promise; +export async function prefetchApiSurfaceModulesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: apiSurfaceModuleKeys.list(args), + queryFn: () => getClient().apiSurfaceModule.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useAppModuleQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useAppModuleQuery.ts new file mode 100644 index 000000000..fddea27e3 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useAppModuleQuery.ts @@ -0,0 +1,138 @@ +/** + * Single item query hook for AppModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { appModuleKeys } from '../query-keys'; +import type { AppModuleSelect, AppModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { AppModuleSelect, AppModuleWithRelations } from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const appModuleQueryKey = appModuleKeys.detail; +/** + * Query hook for fetching a single AppModule + * + * @example + * ```tsx + * const { data, isLoading } = useAppModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useAppModuleQuery< + S extends AppModuleSelect, + TData = { + appModule: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, AppModuleSelect>; + } & Omit< + UseQueryOptions< + { + appModule: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useAppModuleQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: appModuleKeys.detail(params.id), + queryFn: () => + getClient() + .appModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Fetch a single AppModule without React hooks + * + * @example + * ```ts + * const data = await fetchAppModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchAppModuleQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, AppModuleSelect>; +}): Promise<{ + appModule: InferSelectResult | null; +}>; +export async function fetchAppModuleQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .appModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Prefetch a single AppModule for SSR or cache warming + * + * @example + * ```ts + * await prefetchAppModuleQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchAppModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, AppModuleSelect>; + } +): Promise; +export async function prefetchAppModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: appModuleKeys.detail(params.id), + queryFn: () => + getClient() + .appModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useAppModulesQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useAppModulesQuery.ts new file mode 100644 index 000000000..b4958750a --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useAppModulesQuery.ts @@ -0,0 +1,145 @@ +/** + * List query hook for AppModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { appModuleKeys } from '../query-keys'; +import type { + AppModuleSelect, + AppModuleWithRelations, + AppModuleFilter, + AppModuleOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + AppModuleSelect, + AppModuleWithRelations, + AppModuleFilter, + AppModuleOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const appModulesQueryKey = appModuleKeys.list; +/** + * Query hook for fetching AppModule list + * + * @example + * ```tsx + * const { data, isLoading } = useAppModulesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useAppModulesQuery< + S extends AppModuleSelect, + TData = { + appModules: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, AppModuleSelect>; + } & Omit< + UseQueryOptions< + { + appModules: ConnectionResult>; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useAppModulesQuery( + params: { + selection: ListSelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs( + params.selection + ); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: appModuleKeys.list(args), + queryFn: () => getClient().appModule.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch AppModule list without React hooks + * + * @example + * ```ts + * const data = await fetchAppModulesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchAppModulesQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, AppModuleSelect>; +}): Promise<{ + appModules: ConnectionResult>; +}>; +export async function fetchAppModulesQuery(params: { + selection: ListSelectionConfig; +}) { + const args = buildListSelectionArgs( + params.selection + ); + return getClient().appModule.findMany(args).unwrap(); +} +/** + * Prefetch AppModule list for SSR or cache warming + * + * @example + * ```ts + * await prefetchAppModulesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchAppModulesQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, AppModuleSelect>; + } +): Promise; +export async function prefetchAppModulesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig; + } +): Promise { + const args = buildListSelectionArgs( + params.selection + ); + await queryClient.prefetchQuery({ + queryKey: appModuleKeys.list(args), + queryFn: () => getClient().appModule.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useCatalogModuleQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useCatalogModuleQuery.ts new file mode 100644 index 000000000..ce42b450b --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useCatalogModuleQuery.ts @@ -0,0 +1,138 @@ +/** + * Single item query hook for CatalogModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { catalogModuleKeys } from '../query-keys'; +import type { CatalogModuleSelect, CatalogModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { CatalogModuleSelect, CatalogModuleWithRelations } from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const catalogModuleQueryKey = catalogModuleKeys.detail; +/** + * Query hook for fetching a single CatalogModule + * + * @example + * ```tsx + * const { data, isLoading } = useCatalogModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useCatalogModuleQuery< + S extends CatalogModuleSelect, + TData = { + catalogModule: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, CatalogModuleSelect>; + } & Omit< + UseQueryOptions< + { + catalogModule: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useCatalogModuleQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: catalogModuleKeys.detail(params.id), + queryFn: () => + getClient() + .catalogModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Fetch a single CatalogModule without React hooks + * + * @example + * ```ts + * const data = await fetchCatalogModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchCatalogModuleQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, CatalogModuleSelect>; +}): Promise<{ + catalogModule: InferSelectResult | null; +}>; +export async function fetchCatalogModuleQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .catalogModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Prefetch a single CatalogModule for SSR or cache warming + * + * @example + * ```ts + * await prefetchCatalogModuleQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchCatalogModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, CatalogModuleSelect>; + } +): Promise; +export async function prefetchCatalogModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: catalogModuleKeys.detail(params.id), + queryFn: () => + getClient() + .catalogModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useCatalogModulesQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useCatalogModulesQuery.ts new file mode 100644 index 000000000..6e84f24c0 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useCatalogModulesQuery.ts @@ -0,0 +1,151 @@ +/** + * List query hook for CatalogModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { catalogModuleKeys } from '../query-keys'; +import type { + CatalogModuleSelect, + CatalogModuleWithRelations, + CatalogModuleFilter, + CatalogModuleOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + CatalogModuleSelect, + CatalogModuleWithRelations, + CatalogModuleFilter, + CatalogModuleOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const catalogModulesQueryKey = catalogModuleKeys.list; +/** + * Query hook for fetching CatalogModule list + * + * @example + * ```tsx + * const { data, isLoading } = useCatalogModulesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useCatalogModulesQuery< + S extends CatalogModuleSelect, + TData = { + catalogModules: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, CatalogModuleSelect>; + } & Omit< + UseQueryOptions< + { + catalogModules: ConnectionResult>; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useCatalogModulesQuery( + params: { + selection: ListSelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + CatalogModuleSelect, + CatalogModuleFilter, + CatalogModuleOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: catalogModuleKeys.list(args), + queryFn: () => getClient().catalogModule.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch CatalogModule list without React hooks + * + * @example + * ```ts + * const data = await fetchCatalogModulesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchCatalogModulesQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, CatalogModuleSelect>; +}): Promise<{ + catalogModules: ConnectionResult>; +}>; +export async function fetchCatalogModulesQuery(params: { + selection: ListSelectionConfig; +}) { + const args = buildListSelectionArgs< + CatalogModuleSelect, + CatalogModuleFilter, + CatalogModuleOrderBy + >(params.selection); + return getClient().catalogModule.findMany(args).unwrap(); +} +/** + * Prefetch CatalogModule list for SSR or cache warming + * + * @example + * ```ts + * await prefetchCatalogModulesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchCatalogModulesQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, CatalogModuleSelect>; + } +): Promise; +export async function prefetchCatalogModulesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig; + } +): Promise { + const args = buildListSelectionArgs< + CatalogModuleSelect, + CatalogModuleFilter, + CatalogModuleOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: catalogModuleKeys.list(args), + queryFn: () => getClient().catalogModule.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useDomainModuleQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useDomainModuleQuery.ts new file mode 100644 index 000000000..b7b2de840 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useDomainModuleQuery.ts @@ -0,0 +1,138 @@ +/** + * Single item query hook for DomainModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { domainModuleKeys } from '../query-keys'; +import type { DomainModuleSelect, DomainModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { DomainModuleSelect, DomainModuleWithRelations } from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const domainModuleQueryKey = domainModuleKeys.detail; +/** + * Query hook for fetching a single DomainModule + * + * @example + * ```tsx + * const { data, isLoading } = useDomainModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useDomainModuleQuery< + S extends DomainModuleSelect, + TData = { + domainModule: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainModuleSelect>; + } & Omit< + UseQueryOptions< + { + domainModule: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useDomainModuleQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: domainModuleKeys.detail(params.id), + queryFn: () => + getClient() + .domainModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Fetch a single DomainModule without React hooks + * + * @example + * ```ts + * const data = await fetchDomainModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchDomainModuleQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainModuleSelect>; +}): Promise<{ + domainModule: InferSelectResult | null; +}>; +export async function fetchDomainModuleQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .domainModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Prefetch a single DomainModule for SSR or cache warming + * + * @example + * ```ts + * await prefetchDomainModuleQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchDomainModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, DomainModuleSelect>; + } +): Promise; +export async function prefetchDomainModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: domainModuleKeys.detail(params.id), + queryFn: () => + getClient() + .domainModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useDomainModulesQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useDomainModulesQuery.ts new file mode 100644 index 000000000..93df08003 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useDomainModulesQuery.ts @@ -0,0 +1,145 @@ +/** + * List query hook for DomainModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { domainModuleKeys } from '../query-keys'; +import type { + DomainModuleSelect, + DomainModuleWithRelations, + DomainModuleFilter, + DomainModuleOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + DomainModuleSelect, + DomainModuleWithRelations, + DomainModuleFilter, + DomainModuleOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const domainModulesQueryKey = domainModuleKeys.list; +/** + * Query hook for fetching DomainModule list + * + * @example + * ```tsx + * const { data, isLoading } = useDomainModulesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useDomainModulesQuery< + S extends DomainModuleSelect, + TData = { + domainModules: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, DomainModuleSelect>; + } & Omit< + UseQueryOptions< + { + domainModules: ConnectionResult>; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useDomainModulesQuery( + params: { + selection: ListSelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs( + params.selection + ); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: domainModuleKeys.list(args), + queryFn: () => getClient().domainModule.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch DomainModule list without React hooks + * + * @example + * ```ts + * const data = await fetchDomainModulesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchDomainModulesQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, DomainModuleSelect>; +}): Promise<{ + domainModules: ConnectionResult>; +}>; +export async function fetchDomainModulesQuery(params: { + selection: ListSelectionConfig; +}) { + const args = buildListSelectionArgs( + params.selection + ); + return getClient().domainModule.findMany(args).unwrap(); +} +/** + * Prefetch DomainModule list for SSR or cache warming + * + * @example + * ```ts + * await prefetchDomainModulesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchDomainModulesQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, DomainModuleSelect>; + } +): Promise; +export async function prefetchDomainModulesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig; + } +): Promise { + const args = buildListSelectionArgs( + params.selection + ); + await queryClient.prefetchQuery({ + queryKey: domainModuleKeys.list(args), + queryFn: () => getClient().domainModule.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useRouteModuleQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useRouteModuleQuery.ts new file mode 100644 index 000000000..c8786c231 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useRouteModuleQuery.ts @@ -0,0 +1,138 @@ +/** + * Single item query hook for RouteModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { routeModuleKeys } from '../query-keys'; +import type { RouteModuleSelect, RouteModuleWithRelations } from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { RouteModuleSelect, RouteModuleWithRelations } from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const routeModuleQueryKey = routeModuleKeys.detail; +/** + * Query hook for fetching a single RouteModule + * + * @example + * ```tsx + * const { data, isLoading } = useRouteModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useRouteModuleQuery< + S extends RouteModuleSelect, + TData = { + routeModule: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, RouteModuleSelect>; + } & Omit< + UseQueryOptions< + { + routeModule: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useRouteModuleQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: routeModuleKeys.detail(params.id), + queryFn: () => + getClient() + .routeModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Fetch a single RouteModule without React hooks + * + * @example + * ```ts + * const data = await fetchRouteModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchRouteModuleQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, RouteModuleSelect>; +}): Promise<{ + routeModule: InferSelectResult | null; +}>; +export async function fetchRouteModuleQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .routeModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Prefetch a single RouteModule for SSR or cache warming + * + * @example + * ```ts + * await prefetchRouteModuleQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchRouteModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, RouteModuleSelect>; + } +): Promise; +export async function prefetchRouteModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: routeModuleKeys.detail(params.id), + queryFn: () => + getClient() + .routeModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useRouteModulesQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useRouteModulesQuery.ts new file mode 100644 index 000000000..fe5304810 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useRouteModulesQuery.ts @@ -0,0 +1,145 @@ +/** + * List query hook for RouteModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { routeModuleKeys } from '../query-keys'; +import type { + RouteModuleSelect, + RouteModuleWithRelations, + RouteModuleFilter, + RouteModuleOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + RouteModuleSelect, + RouteModuleWithRelations, + RouteModuleFilter, + RouteModuleOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const routeModulesQueryKey = routeModuleKeys.list; +/** + * Query hook for fetching RouteModule list + * + * @example + * ```tsx + * const { data, isLoading } = useRouteModulesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useRouteModulesQuery< + S extends RouteModuleSelect, + TData = { + routeModules: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, RouteModuleSelect>; + } & Omit< + UseQueryOptions< + { + routeModules: ConnectionResult>; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useRouteModulesQuery( + params: { + selection: ListSelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs( + params.selection + ); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: routeModuleKeys.list(args), + queryFn: () => getClient().routeModule.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch RouteModule list without React hooks + * + * @example + * ```ts + * const data = await fetchRouteModulesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchRouteModulesQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, RouteModuleSelect>; +}): Promise<{ + routeModules: ConnectionResult>; +}>; +export async function fetchRouteModulesQuery(params: { + selection: ListSelectionConfig; +}) { + const args = buildListSelectionArgs( + params.selection + ); + return getClient().routeModule.findMany(args).unwrap(); +} +/** + * Prefetch RouteModule list for SSR or cache warming + * + * @example + * ```ts + * await prefetchRouteModulesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchRouteModulesQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, RouteModuleSelect>; + } +): Promise; +export async function prefetchRouteModulesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig; + } +): Promise { + const args = buildListSelectionArgs( + params.selection + ); + await queryClient.prefetchQuery({ + queryKey: routeModuleKeys.list(args), + queryFn: () => getClient().routeModule.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModuleQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModuleQuery.ts new file mode 100644 index 000000000..002ae85c6 --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModuleQuery.ts @@ -0,0 +1,144 @@ +/** + * Single item query hook for SiteSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildSelectionArgs } from '../selection'; +import type { SelectionConfig } from '../selection'; +import { siteSurfaceModuleKeys } from '../query-keys'; +import type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, +} from '../../orm/input-types'; +import type { InferSelectResult, HookStrictSelect } from '../../orm/select-types'; +export type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const siteSurfaceModuleQueryKey = siteSurfaceModuleKeys.detail; +/** + * Query hook for fetching a single SiteSurfaceModule + * + * @example + * ```tsx + * const { data, isLoading } = useSiteSurfaceModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true, name: true } }, + * }); + * ``` + */ +export function useSiteSurfaceModuleQuery< + S extends SiteSurfaceModuleSelect, + TData = { + siteSurfaceModule: InferSelectResult | null; + }, +>( + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, SiteSurfaceModuleSelect>; + } & Omit< + UseQueryOptions< + { + siteSurfaceModule: InferSelectResult | null; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useSiteSurfaceModuleQuery( + params: { + id: string; + selection: SelectionConfig; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildSelectionArgs(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: siteSurfaceModuleKeys.detail(params.id), + queryFn: () => + getClient() + .siteSurfaceModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + ...queryOptions, + }); +} +/** + * Fetch a single SiteSurfaceModule without React hooks + * + * @example + * ```ts + * const data = await fetchSiteSurfaceModuleQuery({ + * id: 'some-id', + * selection: { fields: { id: true } }, + * }); + * ``` + */ +export async function fetchSiteSurfaceModuleQuery(params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, SiteSurfaceModuleSelect>; +}): Promise<{ + siteSurfaceModule: InferSelectResult | null; +}>; +export async function fetchSiteSurfaceModuleQuery(params: { + id: string; + selection: SelectionConfig; +}): Promise { + const args = buildSelectionArgs(params.selection); + return getClient() + .siteSurfaceModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(); +} +/** + * Prefetch a single SiteSurfaceModule for SSR or cache warming + * + * @example + * ```ts + * await prefetchSiteSurfaceModuleQuery(queryClient, { id: 'some-id', selection: { fields: { id: true } } }); + * ``` + */ +export async function prefetchSiteSurfaceModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: { + fields: S; + } & HookStrictSelect, SiteSurfaceModuleSelect>; + } +): Promise; +export async function prefetchSiteSurfaceModuleQuery( + queryClient: QueryClient, + params: { + id: string; + selection: SelectionConfig; + } +): Promise { + const args = buildSelectionArgs(params.selection); + await queryClient.prefetchQuery({ + queryKey: siteSurfaceModuleKeys.detail(params.id), + queryFn: () => + getClient() + .siteSurfaceModule.findOne({ + id: params.id, + select: args.select, + }) + .unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModulesQuery.ts b/sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModulesQuery.ts new file mode 100644 index 000000000..e87fd031b --- /dev/null +++ b/sdk/constructive-react/src/modules/hooks/queries/useSiteSurfaceModulesQuery.ts @@ -0,0 +1,163 @@ +/** + * List query hook for SiteSurfaceModule + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ + +import { useQuery } from '@tanstack/react-query'; +import type { UseQueryOptions, UseQueryResult, QueryClient } from '@tanstack/react-query'; +import { getClient } from '../client'; +import { buildListSelectionArgs } from '../selection'; +import type { ListSelectionConfig } from '../selection'; +import { siteSurfaceModuleKeys } from '../query-keys'; +import type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy, +} from '../../orm/input-types'; +import type { + FindManyArgs, + InferSelectResult, + ConnectionResult, + HookStrictSelect, +} from '../../orm/select-types'; +export type { + SiteSurfaceModuleSelect, + SiteSurfaceModuleWithRelations, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy, +} from '../../orm/input-types'; +/** Query key factory - re-exported from query-keys.ts */ +export const siteSurfaceModulesQueryKey = siteSurfaceModuleKeys.list; +/** + * Query hook for fetching SiteSurfaceModule list + * + * @example + * ```tsx + * const { data, isLoading } = useSiteSurfaceModulesQuery({ + * selection: { + * fields: { id: true, name: true }, + * where: { name: { equalTo: "example" } }, + * orderBy: ['CREATED_AT_DESC'], + * first: 10, + * }, + * }); + * ``` + */ +export function useSiteSurfaceModulesQuery< + S extends SiteSurfaceModuleSelect, + TData = { + siteSurfaceModules: ConnectionResult>; + }, +>( + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, SiteSurfaceModuleSelect>; + } & Omit< + UseQueryOptions< + { + siteSurfaceModules: ConnectionResult>; + }, + Error, + TData + >, + 'queryKey' | 'queryFn' + > +): UseQueryResult; +export function useSiteSurfaceModulesQuery( + params: { + selection: ListSelectionConfig< + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy + >; + } & Omit, 'queryKey' | 'queryFn'> +) { + const args = buildListSelectionArgs< + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy + >(params.selection); + const { selection: _selection, ...queryOptions } = params ?? {}; + void _selection; + return useQuery({ + queryKey: siteSurfaceModuleKeys.list(args), + queryFn: () => getClient().siteSurfaceModule.findMany(args).unwrap(), + ...queryOptions, + }); +} +/** + * Fetch SiteSurfaceModule list without React hooks + * + * @example + * ```ts + * const data = await fetchSiteSurfaceModulesQuery({ + * selection: { + * fields: { id: true }, + * first: 10, + * }, + * }); + * ``` + */ +export async function fetchSiteSurfaceModulesQuery(params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, SiteSurfaceModuleSelect>; +}): Promise<{ + siteSurfaceModules: ConnectionResult>; +}>; +export async function fetchSiteSurfaceModulesQuery(params: { + selection: ListSelectionConfig< + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy + >; +}) { + const args = buildListSelectionArgs< + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy + >(params.selection); + return getClient().siteSurfaceModule.findMany(args).unwrap(); +} +/** + * Prefetch SiteSurfaceModule list for SSR or cache warming + * + * @example + * ```ts + * await prefetchSiteSurfaceModulesQuery(queryClient, { selection: { fields: { id: true }, first: 10 } }); + * ``` + */ +export async function prefetchSiteSurfaceModulesQuery( + queryClient: QueryClient, + params: { + selection: { + fields: S; + } & Omit, 'fields'> & + HookStrictSelect, SiteSurfaceModuleSelect>; + } +): Promise; +export async function prefetchSiteSurfaceModulesQuery( + queryClient: QueryClient, + params: { + selection: ListSelectionConfig< + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy + >; + } +): Promise { + const args = buildListSelectionArgs< + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy + >(params.selection); + await queryClient.prefetchQuery({ + queryKey: siteSurfaceModuleKeys.list(args), + queryFn: () => getClient().siteSurfaceModule.findMany(args).unwrap(), + }); +} diff --git a/sdk/constructive-react/src/modules/hooks/query-keys.ts b/sdk/constructive-react/src/modules/hooks/query-keys.ts index 303af350f..74e40cc8a 100644 --- a/sdk/constructive-react/src/modules/hooks/query-keys.ts +++ b/sdk/constructive-react/src/modules/hooks/query-keys.ts @@ -28,6 +28,24 @@ export const agentModuleKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...agentModuleKeys.details(), id] as const, } as const; +export const apiSurfaceModuleKeys = { + /** All apiSurfaceModule queries */ all: ['apisurfacemodule'] as const, + /** List query keys */ lists: () => [...apiSurfaceModuleKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...apiSurfaceModuleKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...apiSurfaceModuleKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...apiSurfaceModuleKeys.details(), id] as const, +} as const; +export const appModuleKeys = { + /** All appModule queries */ all: ['appmodule'] as const, + /** List query keys */ lists: () => [...appModuleKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...appModuleKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...appModuleKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...appModuleKeys.details(), id] as const, +} as const; export const billingModuleKeys = { /** All billingModule queries */ all: ['billingmodule'] as const, /** List query keys */ lists: () => [...billingModuleKeys.all, 'list'] as const, @@ -73,6 +91,15 @@ export const blueprintTemplateKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...blueprintTemplateKeys.details(), id] as const, } as const; +export const catalogModuleKeys = { + /** All catalogModule queries */ all: ['catalogmodule'] as const, + /** List query keys */ lists: () => [...catalogModuleKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...catalogModuleKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...catalogModuleKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...catalogModuleKeys.details(), id] as const, +} as const; export const computeLogModuleKeys = { /** All computeLogModule queries */ all: ['computelogmodule'] as const, /** List query keys */ lists: () => [...computeLogModuleKeys.all, 'list'] as const, @@ -190,6 +217,15 @@ export const devicesModuleKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...devicesModuleKeys.details(), id] as const, } as const; +export const domainModuleKeys = { + /** All domainModule queries */ all: ['domainmodule'] as const, + /** List query keys */ lists: () => [...domainModuleKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...domainModuleKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...domainModuleKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...domainModuleKeys.details(), id] as const, +} as const; export const emailsModuleKeys = { /** All emailsModule queries */ all: ['emailsmodule'] as const, /** List query keys */ lists: () => [...emailsModuleKeys.all, 'list'] as const, @@ -506,6 +542,15 @@ export const rlsModuleKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...rlsModuleKeys.details(), id] as const, } as const; +export const routeModuleKeys = { + /** All routeModule queries */ all: ['routemodule'] as const, + /** List query keys */ lists: () => [...routeModuleKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...routeModuleKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...routeModuleKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...routeModuleKeys.details(), id] as const, +} as const; export const secureTableProvisionKeys = { /** All secureTableProvision queries */ all: ['securetableprovision'] as const, /** List query keys */ lists: () => [...secureTableProvisionKeys.all, 'list'] as const, @@ -533,6 +578,15 @@ export const sessionsModuleKeys = { /** Detail query key for specific item */ detail: (id: string | number) => [...sessionsModuleKeys.details(), id] as const, } as const; +export const siteSurfaceModuleKeys = { + /** All siteSurfaceModule queries */ all: ['sitesurfacemodule'] as const, + /** List query keys */ lists: () => [...siteSurfaceModuleKeys.all, 'list'] as const, + /** List query key with variables */ list: (variables?: object) => + [...siteSurfaceModuleKeys.lists(), variables] as const, + /** Detail query keys */ details: () => [...siteSurfaceModuleKeys.all, 'detail'] as const, + /** Detail query key for specific item */ detail: (id: string | number) => + [...siteSurfaceModuleKeys.details(), id] as const, +} as const; export const storageLogModuleKeys = { /** All storageLogModule queries */ all: ['storagelogmodule'] as const, /** List query keys */ lists: () => [...storageLogModuleKeys.all, 'list'] as const, @@ -667,11 +721,14 @@ export const customQueryKeys = { */ export const queryKeys = { agentModule: agentModuleKeys, + apiSurfaceModule: apiSurfaceModuleKeys, + appModule: appModuleKeys, billingModule: billingModuleKeys, billingProviderModule: billingProviderModuleKeys, blueprint: blueprintKeys, blueprintConstruction: blueprintConstructionKeys, blueprintTemplate: blueprintTemplateKeys, + catalogModule: catalogModuleKeys, computeLogModule: computeLogModuleKeys, configSecretsUserModule: configSecretsUserModuleKeys, connectedAccountsModule: connectedAccountsModuleKeys, @@ -685,6 +742,7 @@ export const queryKeys = { defaultIdsModule: defaultIdsModuleKeys, denormalizedTableField: denormalizedTableFieldKeys, devicesModule: devicesModuleKeys, + domainModule: domainModuleKeys, emailsModule: emailsModuleKeys, entityTypeProvision: entityTypeProvisionKeys, eventsModule: eventsModuleKeys, @@ -720,9 +778,11 @@ export const queryKeys = { relationProvision: relationProvisionKeys, resourceModule: resourceModuleKeys, rlsModule: rlsModuleKeys, + routeModule: routeModuleKeys, secureTableProvision: secureTableProvisionKeys, sessionSecretsModule: sessionSecretsModuleKeys, sessionsModule: sessionsModuleKeys, + siteSurfaceModule: siteSurfaceModuleKeys, storageLogModule: storageLogModuleKeys, storageModule: storageModuleKeys, transferLogModule: transferLogModuleKeys, diff --git a/sdk/constructive-react/src/modules/orm/README.md b/sdk/constructive-react/src/modules/orm/README.md index e420c3adb..41c41241d 100644 --- a/sdk/constructive-react/src/modules/orm/README.md +++ b/sdk/constructive-react/src/modules/orm/README.md @@ -22,11 +22,14 @@ const db = createClient({ | Model | Operations | |-------|------------| | `agentModule` | findMany, findOne, create, update, delete | +| `apiSurfaceModule` | findMany, findOne, create, update, delete | +| `appModule` | findMany, findOne, create, update, delete | | `billingModule` | findMany, findOne, create, update, delete | | `billingProviderModule` | findMany, findOne, create, update, delete | | `blueprint` | findMany, findOne, create, update, delete | | `blueprintConstruction` | findMany, findOne, create, update, delete | | `blueprintTemplate` | findMany, findOne, create, update, delete | +| `catalogModule` | findMany, findOne, create, update, delete | | `computeLogModule` | findMany, findOne, create, update, delete | | `configSecretsUserModule` | findMany, findOne, create, update, delete | | `connectedAccountsModule` | findMany, findOne, create, update, delete | @@ -40,6 +43,7 @@ const db = createClient({ | `defaultIdsModule` | findMany, findOne, create, update, delete | | `denormalizedTableField` | findMany, findOne, create, update, delete | | `devicesModule` | findMany, findOne, create, update, delete | +| `domainModule` | findMany, findOne, create, update, delete | | `emailsModule` | findMany, findOne, create, update, delete | | `entityTypeProvision` | findMany, findOne, create, update, delete | | `eventsModule` | findMany, findOne, create, update, delete | @@ -75,9 +79,11 @@ const db = createClient({ | `relationProvision` | findMany, findOne, create, update, delete | | `resourceModule` | findMany, findOne, create, update, delete | | `rlsModule` | findMany, findOne, create, update, delete | +| `routeModule` | findMany, findOne, create, update, delete | | `secureTableProvision` | findMany, findOne, create, update, delete | | `sessionSecretsModule` | findMany, findOne, create, update, delete | | `sessionsModule` | findMany, findOne, create, update, delete | +| `siteSurfaceModule` | findMany, findOne, create, update, delete | | `storageLogModule` | findMany, findOne, create, update, delete | | `storageModule` | findMany, findOne, create, update, delete | | `transferLogModule` | findMany, findOne, create, update, delete | @@ -156,6 +162,98 @@ const updated = await db.agentModule.update({ where: { id: '' }, data: { a const deleted = await db.agentModule.delete({ where: { id: '' } }).execute(); ``` +### `db.apiSurfaceModule` + +CRUD operations for ApiSurfaceModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `apisTableId` | UUID | Yes | +| `apisTableName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all apiSurfaceModule records +const items = await db.apiSurfaceModule.findMany({ select: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.apiSurfaceModule.findOne({ id: '', select: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.apiSurfaceModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.apiSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.apiSurfaceModule.delete({ where: { id: '' } }).execute(); +``` + +### `db.appModule` + +CRUD operations for AppModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `appMembersTableId` | UUID | Yes | +| `appMembersTableName` | String | Yes | +| `appsTableId` | UUID | Yes | +| `appsTableName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `privateSchemaId` | UUID | Yes | +| `privateSchemaName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all appModule records +const items = await db.appModule.findMany({ select: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.appModule.findOne({ id: '', select: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.appModule.create({ data: { apiName: '', appMembersTableId: '', appMembersTableName: '', appsTableId: '', appsTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.appModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.appModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.billingModule` CRUD operations for BillingModule records. @@ -388,6 +486,63 @@ const updated = await db.blueprintTemplate.update({ where: { id: '' }, dat const deleted = await db.blueprintTemplate.delete({ where: { id: '' } }).execute(); ``` +### `db.catalogModule` + +CRUD operations for CatalogModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `apisTableId` | UUID | Yes | +| `apisTableName` | String | Yes | +| `appsTableId` | UUID | Yes | +| `appsTableName` | String | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainsTableId` | UUID | Yes | +| `domainsTableName` | String | Yes | +| `entityTableId` | UUID | Yes | +| `functionsTableId` | UUID | Yes | +| `functionsTableName` | String | Yes | +| `id` | UUID | No | +| `namespacesTableId` | UUID | Yes | +| `namespacesTableName` | String | Yes | +| `policies` | JSON | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `resourceDefinitionsTableId` | UUID | Yes | +| `resourceDefinitionsTableName` | String | Yes | +| `resourceInstallationsTableId` | UUID | Yes | +| `resourceInstallationsTableName` | String | Yes | +| `resourcesTableId` | UUID | Yes | +| `resourcesTableName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | +| `sitesTableId` | UUID | Yes | +| `sitesTableName` | String | Yes | + +**Operations:** + +```typescript +// List all catalogModule records +const items = await db.catalogModule.findMany({ select: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Get one by id +const item = await db.catalogModule.findOne({ id: '', select: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Create +const created = await db.catalogModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', appsTableId: '', appsTableName: '', databaseId: '', defaultPermissions: '', domainsTableId: '', domainsTableName: '', entityTableId: '', functionsTableId: '', functionsTableName: '', namespacesTableId: '', namespacesTableName: '', policies: '', privateApiName: '', provisions: '', publicSchemaName: '', resourceDefinitionsTableId: '', resourceDefinitionsTableName: '', resourceInstallationsTableId: '', resourceInstallationsTableName: '', resourcesTableId: '', resourcesTableName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.catalogModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.catalogModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.computeLogModule` CRUD operations for ComputeLogModule records. @@ -597,6 +752,7 @@ CRUD operations for DatabaseProvisionModule records. | Field | Type | Editable | |-------|------|----------| +| `async` | Boolean | Yes | | `bootstrapError` | String | Yes | | `bootstrapStatus` | String | Yes | | `bootstrapUser` | Boolean | Yes | @@ -620,16 +776,16 @@ CRUD operations for DatabaseProvisionModule records. ```typescript // List all databaseProvisionModule records -const items = await db.databaseProvisionModule.findMany({ select: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); +const items = await db.databaseProvisionModule.findMany({ select: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); // Get one by id -const item = await db.databaseProvisionModule.findOne({ id: '', select: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); +const item = await db.databaseProvisionModule.findOne({ id: '', select: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); // Create -const created = await db.databaseProvisionModule.create({ data: { bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute(); +const created = await db.databaseProvisionModule.create({ data: { async: '', bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute(); // Update -const updated = await db.databaseProvisionModule.update({ where: { id: '' }, data: { bootstrapError: '' }, select: { id: true } }).execute(); +const updated = await db.databaseProvisionModule.update({ where: { id: '' }, data: { async: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseProvisionModule.delete({ where: { id: '' } }).execute(); @@ -919,6 +1075,54 @@ const updated = await db.devicesModule.update({ where: { id: '' }, data: { const deleted = await db.devicesModule.delete({ where: { id: '' } }).execute(); ``` +### `db.domainModule` + +CRUD operations for DomainModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainEventsTableId` | UUID | Yes | +| `domainEventsTableName` | String | Yes | +| `domainVerificationsTableId` | UUID | Yes | +| `domainVerificationsTableName` | String | Yes | +| `domainsTableId` | UUID | Yes | +| `domainsTableName` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all domainModule records +const items = await db.domainModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.domainModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.domainModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainEventsTableId: '', domainEventsTableName: '', domainVerificationsTableId: '', domainVerificationsTableName: '', domainsTableId: '', domainsTableName: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.emailsModule` CRUD operations for EmailsModule records. @@ -1153,6 +1357,8 @@ CRUD operations for FunctionInvocationModule records. | Field | Type | Editable | |-------|------|----------| | `apiName` | String | Yes | +| `attemptsTableId` | UUID | Yes | +| `attemptsTableName` | String | Yes | | `databaseId` | UUID | Yes | | `defaultPermissions` | String | Yes | | `entityField` | String | Yes | @@ -1176,13 +1382,13 @@ CRUD operations for FunctionInvocationModule records. ```typescript // List all functionInvocationModule records -const items = await db.functionInvocationModule.findMany({ select: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); +const items = await db.functionInvocationModule.findMany({ select: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); // Get one by id -const item = await db.functionInvocationModule.findOne({ id: '', select: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); +const item = await db.functionInvocationModule.findOne({ id: '', select: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); // Create -const created = await db.functionInvocationModule.create({ data: { apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); +const created = await db.functionInvocationModule.create({ data: { apiName: '', attemptsTableId: '', attemptsTableName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionInvocationModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); @@ -2612,6 +2818,58 @@ const updated = await db.rlsModule.update({ where: { id: '' }, data: { api const deleted = await db.rlsModule.delete({ where: { id: '' } }).execute(); ``` +### `db.routeModule` + +CRUD operations for RouteModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainModuleId` | UUID | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `hostnameBindingsTableId` | UUID | Yes | +| `hostnameBindingsTableName` | String | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `privateSchemaId` | UUID | Yes | +| `privateSchemaName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `resolverFunctionName` | String | Yes | +| `routeBindingsTableId` | UUID | Yes | +| `routeBindingsTableName` | String | Yes | +| `routesTableId` | UUID | Yes | +| `routesTableName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all routeModule records +const items = await db.routeModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.routeModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.routeModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainModuleId: '', entityField: '', entityTableId: '', hostnameBindingsTableId: '', hostnameBindingsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', resolverFunctionName: '', routeBindingsTableId: '', routeBindingsTableName: '', routesTableId: '', routesTableName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.routeModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.routeModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.secureTableProvision` CRUD operations for SecureTableProvision records. @@ -2724,6 +2982,50 @@ const updated = await db.sessionsModule.update({ where: { id: '' }, data: const deleted = await db.sessionsModule.delete({ where: { id: '' } }).execute(); ``` +### `db.siteSurfaceModule` + +CRUD operations for SiteSurfaceModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | +| `sitesTableId` | UUID | Yes | +| `sitesTableName` | String | Yes | + +**Operations:** + +```typescript +// List all siteSurfaceModule records +const items = await db.siteSurfaceModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Get one by id +const item = await db.siteSurfaceModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Create +const created = await db.siteSurfaceModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.siteSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.siteSurfaceModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.storageLogModule` CRUD operations for StorageLogModule records. diff --git a/sdk/constructive-react/src/modules/orm/index.ts b/sdk/constructive-react/src/modules/orm/index.ts index dc11b99fb..64ef96660 100644 --- a/sdk/constructive-react/src/modules/orm/index.ts +++ b/sdk/constructive-react/src/modules/orm/index.ts @@ -6,11 +6,14 @@ import { OrmClient } from './client'; import type { OrmClientConfig } from './client'; import { AgentModuleModel } from './models/agentModule'; +import { ApiSurfaceModuleModel } from './models/apiSurfaceModule'; +import { AppModuleModel } from './models/appModule'; import { BillingModuleModel } from './models/billingModule'; import { BillingProviderModuleModel } from './models/billingProviderModule'; import { BlueprintModel } from './models/blueprint'; import { BlueprintConstructionModel } from './models/blueprintConstruction'; import { BlueprintTemplateModel } from './models/blueprintTemplate'; +import { CatalogModuleModel } from './models/catalogModule'; import { ComputeLogModuleModel } from './models/computeLogModule'; import { ConfigSecretsUserModuleModel } from './models/configSecretsUserModule'; import { ConnectedAccountsModuleModel } from './models/connectedAccountsModule'; @@ -24,6 +27,7 @@ import { DbUsageModuleModel } from './models/dbUsageModule'; import { DefaultIdsModuleModel } from './models/defaultIdsModule'; import { DenormalizedTableFieldModel } from './models/denormalizedTableField'; import { DevicesModuleModel } from './models/devicesModule'; +import { DomainModuleModel } from './models/domainModule'; import { EmailsModuleModel } from './models/emailsModule'; import { EntityTypeProvisionModel } from './models/entityTypeProvision'; import { EventsModuleModel } from './models/eventsModule'; @@ -59,9 +63,11 @@ import { RealtimeModuleModel } from './models/realtimeModule'; import { RelationProvisionModel } from './models/relationProvision'; import { ResourceModuleModel } from './models/resourceModule'; import { RlsModuleModel } from './models/rlsModule'; +import { RouteModuleModel } from './models/routeModule'; import { SecureTableProvisionModel } from './models/secureTableProvision'; import { SessionSecretsModuleModel } from './models/sessionSecretsModule'; import { SessionsModuleModel } from './models/sessionsModule'; +import { SiteSurfaceModuleModel } from './models/siteSurfaceModule'; import { StorageLogModuleModel } from './models/storageLogModule'; import { StorageModuleModel } from './models/storageModule'; import { TransferLogModuleModel } from './models/transferLogModule'; @@ -109,11 +115,14 @@ export function createClient(config: OrmClientConfig) { const client = new OrmClient(config); return { agentModule: new AgentModuleModel(client), + apiSurfaceModule: new ApiSurfaceModuleModel(client), + appModule: new AppModuleModel(client), billingModule: new BillingModuleModel(client), billingProviderModule: new BillingProviderModuleModel(client), blueprint: new BlueprintModel(client), blueprintConstruction: new BlueprintConstructionModel(client), blueprintTemplate: new BlueprintTemplateModel(client), + catalogModule: new CatalogModuleModel(client), computeLogModule: new ComputeLogModuleModel(client), configSecretsUserModule: new ConfigSecretsUserModuleModel(client), connectedAccountsModule: new ConnectedAccountsModuleModel(client), @@ -127,6 +136,7 @@ export function createClient(config: OrmClientConfig) { defaultIdsModule: new DefaultIdsModuleModel(client), denormalizedTableField: new DenormalizedTableFieldModel(client), devicesModule: new DevicesModuleModel(client), + domainModule: new DomainModuleModel(client), emailsModule: new EmailsModuleModel(client), entityTypeProvision: new EntityTypeProvisionModel(client), eventsModule: new EventsModuleModel(client), @@ -162,9 +172,11 @@ export function createClient(config: OrmClientConfig) { relationProvision: new RelationProvisionModel(client), resourceModule: new ResourceModuleModel(client), rlsModule: new RlsModuleModel(client), + routeModule: new RouteModuleModel(client), secureTableProvision: new SecureTableProvisionModel(client), sessionSecretsModule: new SessionSecretsModuleModel(client), sessionsModule: new SessionsModuleModel(client), + siteSurfaceModule: new SiteSurfaceModuleModel(client), storageLogModule: new StorageLogModuleModel(client), storageModule: new StorageModuleModel(client), transferLogModule: new TransferLogModuleModel(client), diff --git a/sdk/constructive-react/src/modules/orm/input-types.ts b/sdk/constructive-react/src/modules/orm/input-types.ts index a163f67d4..c151221f6 100644 --- a/sdk/constructive-react/src/modules/orm/input-types.ts +++ b/sdk/constructive-react/src/modules/orm/input-types.ts @@ -269,6 +269,46 @@ export interface AgentModule { threadTableId?: string | null; threadTableName?: string | null; } +export interface ApiSurfaceModule { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface AppModule { + apiName?: string | null; + appMembersTableId?: string | null; + appMembersTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} export interface BillingModule { apiName?: string | null; balancesTableId?: string | null; @@ -417,6 +457,37 @@ export interface BlueprintTemplate { /** Access control for the template. private: only the owner can see and copy. public: anyone can browse and copy from the marketplace. Defaults to private. */ visibility?: string | null; } +export interface CatalogModule { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityTableId?: string | null; + functionsTableId?: string | null; + functionsTableName?: string | null; + id: string; + namespacesTableId?: string | null; + namespacesTableName?: string | null; + policies?: Record | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resourceDefinitionsTableId?: string | null; + resourceDefinitionsTableName?: string | null; + resourceInstallationsTableId?: string | null; + resourceInstallationsTableName?: string | null; + resourcesTableId?: string | null; + resourcesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} export interface ComputeLogModule { actorFkTableId?: string | null; apiName?: string | null; @@ -490,6 +561,8 @@ export interface CryptoAuthModule { } /** Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. */ export interface DatabaseProvisionModule { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean | null; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string | null; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -639,6 +712,28 @@ export interface DevicesModule { userDevicesTableId?: string | null; userDevicesTableName?: string | null; } +export interface DomainModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainEventsTableId?: string | null; + domainEventsTableName?: string | null; + domainVerificationsTableId?: string | null; + domainVerificationsTableName?: string | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} export interface EmailsModule { apiName?: string | null; databaseId?: string | null; @@ -982,6 +1077,8 @@ export interface FunctionDeploymentModule { } export interface FunctionInvocationModule { apiName?: string | null; + attemptsTableId?: string | null; + attemptsTableName?: string | null; databaseId?: string | null; defaultPermissions?: string[] | null; entityField?: string | null; @@ -1772,6 +1869,32 @@ export interface RlsModule { sessionsTableId?: string | null; usersTableId?: string | null; } +export interface RouteModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainModuleId?: string | null; + entityField?: string | null; + entityTableId?: string | null; + hostnameBindingsTableId?: string | null; + hostnameBindingsTableName?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resolverFunctionName?: string | null; + routeBindingsTableId?: string | null; + routeBindingsTableName?: string | null; + routesTableId?: string | null; + routesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; +} /** Provisions security, fields, grants, and policies onto a table. Each row can independently: (1) create fields via nodes[] array (supporting multiple Data* modules per row), (2) grant privileges via grants[] array (supporting per-role privilege targeting), (3) create RLS policies via policies[] array (supporting multiple Authz* policies per row). Multiple rows can target the same table to compose different concerns. All three concerns are optional and independent. */ export interface SecureTableProvision { /** The database this provision belongs to. Required. */ @@ -1820,6 +1943,24 @@ export interface SessionsModule { sessionsTableName?: string | null; usersTableId?: string | null; } +export interface SiteSurfaceModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} export interface StorageLogModule { actorFkTableId?: string | null; apiName?: string | null; @@ -2048,6 +2189,12 @@ export interface PageInfo { } // ============ Entity Relation Types ============ export interface AgentModuleRelations {} +export interface ApiSurfaceModuleRelations { + catalogModule?: CatalogModule | null; +} +export interface AppModuleRelations { + catalogModule?: CatalogModule | null; +} export interface BillingModuleRelations {} export interface BillingProviderModuleRelations {} export interface BlueprintRelations { @@ -2062,6 +2209,7 @@ export interface BlueprintTemplateRelations { blueprintTemplatesByForkedFromId?: ConnectionResult; blueprintsByTemplateId?: ConnectionResult; } +export interface CatalogModuleRelations {} export interface ComputeLogModuleRelations {} export interface ConfigSecretsUserModuleRelations {} export interface ConnectedAccountsModuleRelations {} @@ -2077,6 +2225,9 @@ export interface DbUsageModuleRelations {} export interface DefaultIdsModuleRelations {} export interface DenormalizedTableFieldRelations {} export interface DevicesModuleRelations {} +export interface DomainModuleRelations { + catalogModule?: CatalogModule | null; +} export interface EmailsModuleRelations {} export interface EntityTypeProvisionRelations {} export interface EventsModuleRelations {} @@ -2129,9 +2280,16 @@ export interface ResourceModuleRelations { namespaceModule?: NamespaceModule | null; } export interface RlsModuleRelations {} +export interface RouteModuleRelations { + catalogModule?: CatalogModule | null; + domainModule?: DomainModule | null; +} export interface SecureTableProvisionRelations {} export interface SessionSecretsModuleRelations {} export interface SessionsModuleRelations {} +export interface SiteSurfaceModuleRelations { + catalogModule?: CatalogModule | null; +} export interface StorageLogModuleRelations {} export interface StorageModuleRelations {} export interface TransferLogModuleRelations {} @@ -2150,6 +2308,8 @@ export interface WebhookModuleRelations { } // ============ Entity Types With Relations ============ export type AgentModuleWithRelations = AgentModule & AgentModuleRelations; +export type ApiSurfaceModuleWithRelations = ApiSurfaceModule & ApiSurfaceModuleRelations; +export type AppModuleWithRelations = AppModule & AppModuleRelations; export type BillingModuleWithRelations = BillingModule & BillingModuleRelations; export type BillingProviderModuleWithRelations = BillingProviderModule & BillingProviderModuleRelations; @@ -2157,6 +2317,7 @@ export type BlueprintWithRelations = Blueprint & BlueprintRelations; export type BlueprintConstructionWithRelations = BlueprintConstruction & BlueprintConstructionRelations; export type BlueprintTemplateWithRelations = BlueprintTemplate & BlueprintTemplateRelations; +export type CatalogModuleWithRelations = CatalogModule & CatalogModuleRelations; export type ComputeLogModuleWithRelations = ComputeLogModule & ComputeLogModuleRelations; export type ConfigSecretsUserModuleWithRelations = ConfigSecretsUserModule & ConfigSecretsUserModuleRelations; @@ -2175,6 +2336,7 @@ export type DefaultIdsModuleWithRelations = DefaultIdsModule & DefaultIdsModuleR export type DenormalizedTableFieldWithRelations = DenormalizedTableField & DenormalizedTableFieldRelations; export type DevicesModuleWithRelations = DevicesModule & DevicesModuleRelations; +export type DomainModuleWithRelations = DomainModule & DomainModuleRelations; export type EmailsModuleWithRelations = EmailsModule & EmailsModuleRelations; export type EntityTypeProvisionWithRelations = EntityTypeProvision & EntityTypeProvisionRelations; export type EventsModuleWithRelations = EventsModule & EventsModuleRelations; @@ -2218,11 +2380,13 @@ export type RealtimeModuleWithRelations = RealtimeModule & RealtimeModuleRelatio export type RelationProvisionWithRelations = RelationProvision & RelationProvisionRelations; export type ResourceModuleWithRelations = ResourceModule & ResourceModuleRelations; export type RlsModuleWithRelations = RlsModule & RlsModuleRelations; +export type RouteModuleWithRelations = RouteModule & RouteModuleRelations; export type SecureTableProvisionWithRelations = SecureTableProvision & SecureTableProvisionRelations; export type SessionSecretsModuleWithRelations = SessionSecretsModule & SessionSecretsModuleRelations; export type SessionsModuleWithRelations = SessionsModule & SessionsModuleRelations; +export type SiteSurfaceModuleWithRelations = SiteSurfaceModule & SiteSurfaceModuleRelations; export type StorageLogModuleWithRelations = StorageLogModule & StorageLogModuleRelations; export type StorageModuleWithRelations = StorageModule & StorageModuleRelations; export type TransferLogModuleWithRelations = TransferLogModule & TransferLogModuleRelations; @@ -2275,6 +2439,52 @@ export type AgentModuleSelect = { threadTableId?: boolean; threadTableName?: boolean; }; +export type ApiSurfaceModuleSelect = { + apiName?: boolean; + apisTableId?: boolean; + apisTableName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; +export type AppModuleSelect = { + apiName?: boolean; + appMembersTableId?: boolean; + appMembersTableName?: boolean; + appsTableId?: boolean; + appsTableName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + privateSchemaId?: boolean; + privateSchemaName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type BillingModuleSelect = { apiName?: boolean; balancesTableId?: boolean; @@ -2404,6 +2614,37 @@ export type BlueprintTemplateSelect = { orderBy?: BlueprintOrderBy[]; }; }; +export type CatalogModuleSelect = { + apiName?: boolean; + apisTableId?: boolean; + apisTableName?: boolean; + appsTableId?: boolean; + appsTableName?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainsTableId?: boolean; + domainsTableName?: boolean; + entityTableId?: boolean; + functionsTableId?: boolean; + functionsTableName?: boolean; + id?: boolean; + namespacesTableId?: boolean; + namespacesTableName?: boolean; + policies?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + resourceDefinitionsTableId?: boolean; + resourceDefinitionsTableName?: boolean; + resourceInstallationsTableId?: boolean; + resourceInstallationsTableName?: boolean; + resourcesTableId?: boolean; + resourcesTableName?: boolean; + schemaId?: boolean; + scope?: boolean; + sitesTableId?: boolean; + sitesTableName?: boolean; +}; export type ComputeLogModuleSelect = { actorFkTableId?: boolean; apiName?: boolean; @@ -2476,6 +2717,7 @@ export type CryptoAuthModuleSelect = { usersTableId?: boolean; }; export type DatabaseProvisionModuleSelect = { + async?: boolean; bootstrapError?: boolean; bootstrapStatus?: boolean; bootstrapUser?: boolean; @@ -2600,6 +2842,31 @@ export type DevicesModuleSelect = { userDevicesTableId?: boolean; userDevicesTableName?: boolean; }; +export type DomainModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainEventsTableId?: boolean; + domainEventsTableName?: boolean; + domainVerificationsTableId?: boolean; + domainVerificationsTableName?: boolean; + domainsTableId?: boolean; + domainsTableName?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type EmailsModuleSelect = { apiName?: boolean; databaseId?: boolean; @@ -2729,6 +2996,8 @@ export type FunctionDeploymentModuleSelect = { }; export type FunctionInvocationModuleSelect = { apiName?: boolean; + attemptsTableId?: boolean; + attemptsTableName?: boolean; databaseId?: boolean; defaultPermissions?: boolean; entityField?: boolean; @@ -3422,6 +3691,38 @@ export type RlsModuleSelect = { sessionsTableId?: boolean; usersTableId?: boolean; }; +export type RouteModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainModuleId?: boolean; + entityField?: boolean; + entityTableId?: boolean; + hostnameBindingsTableId?: boolean; + hostnameBindingsTableName?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + privateSchemaId?: boolean; + privateSchemaName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + resolverFunctionName?: boolean; + routeBindingsTableId?: boolean; + routeBindingsTableName?: boolean; + routesTableId?: boolean; + routesTableName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; + domainModule?: { + select: DomainModuleSelect; + }; +}; export type SecureTableProvisionSelect = { databaseId?: boolean; fields?: boolean; @@ -3456,6 +3757,27 @@ export type SessionsModuleSelect = { sessionsTableName?: boolean; usersTableId?: boolean; }; +export type SiteSurfaceModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + sitesTableId?: boolean; + sitesTableName?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type StorageLogModuleSelect = { actorFkTableId?: boolean; apiName?: boolean; @@ -3756,74 +4078,170 @@ export interface AgentModuleFilter { /** Filter by the object’s `threadTableName` field. */ threadTableName?: StringFilter; } -export interface BillingModuleFilter { +export interface ApiSurfaceModuleFilter { /** Checks for all expressions in this list. */ - and?: BillingModuleFilter[]; + and?: ApiSurfaceModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; - /** Filter by the object’s `balancesTableId` field. */ - balancesTableId?: UUIDFilter; - /** Filter by the object’s `balancesTableName` field. */ - balancesTableName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `defaultPermissions` field. */ defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; /** Filter by the object’s `id` field. */ id?: UUIDFilter; - /** Filter by the object’s `ledgerTableId` field. */ - ledgerTableId?: UUIDFilter; - /** Filter by the object’s `ledgerTableName` field. */ - ledgerTableName?: StringFilter; - /** Filter by the object’s `meterCreditsTableId` field. */ - meterCreditsTableId?: UUIDFilter; - /** Filter by the object’s `meterCreditsTableName` field. */ - meterCreditsTableName?: StringFilter; - /** Filter by the object’s `meterDefaultsTableId` field. */ - meterDefaultsTableId?: UUIDFilter; - /** Filter by the object’s `meterDefaultsTableName` field. */ - meterDefaultsTableName?: StringFilter; - /** Filter by the object’s `meterSourcesTableId` field. */ - meterSourcesTableId?: UUIDFilter; - /** Filter by the object’s `meterSourcesTableName` field. */ - meterSourcesTableName?: StringFilter; - /** Filter by the object’s `metersTableId` field. */ - metersTableId?: UUIDFilter; - /** Filter by the object’s `metersTableName` field. */ - metersTableName?: StringFilter; /** Negates the expression. */ - not?: BillingModuleFilter; + not?: ApiSurfaceModuleFilter; /** Checks for any expressions in this list. */ - or?: BillingModuleFilter[]; - /** Filter by the object’s `planSubscriptionsTableId` field. */ - planSubscriptionsTableId?: UUIDFilter; - /** Filter by the object’s `planSubscriptionsTableName` field. */ - planSubscriptionsTableName?: StringFilter; + or?: ApiSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; /** Filter by the object’s `prefix` field. */ prefix?: StringFilter; /** Filter by the object’s `privateApiName` field. */ privateApiName?: StringFilter; - /** Filter by the object’s `privateSchemaId` field. */ - privateSchemaId?: UUIDFilter; - /** Filter by the object’s `privateSchemaName` field. */ - privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; /** Filter by the object’s `publicSchemaName` field. */ publicSchemaName?: StringFilter; - /** Filter by the object’s `recordUsageFunction` field. */ - recordUsageFunction?: StringFilter; - /** Filter by the object’s `rollupUsageSummaryFunction` field. */ - rollupUsageSummaryFunction?: StringFilter; /** Filter by the object’s `schemaId` field. */ schemaId?: UUIDFilter; - /** Filter by the object’s `sweepExpiredSubscriptionsFunction` field. */ - sweepExpiredSubscriptionsFunction?: StringFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; } -export interface BillingProviderModuleFilter { +export interface AppModuleFilter { /** Checks for all expressions in this list. */ - and?: BillingProviderModuleFilter[]; + and?: AppModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; - /** Filter by the object’s `billingCustomersTableId` field. */ + /** Filter by the object’s `appMembersTableId` field. */ + appMembersTableId?: UUIDFilter; + /** Filter by the object’s `appMembersTableName` field. */ + appMembersTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: AppModuleFilter; + /** Checks for any expressions in this list. */ + or?: AppModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} +export interface BillingModuleFilter { + /** Checks for all expressions in this list. */ + and?: BillingModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `balancesTableId` field. */ + balancesTableId?: UUIDFilter; + /** Filter by the object’s `balancesTableName` field. */ + balancesTableName?: StringFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `ledgerTableId` field. */ + ledgerTableId?: UUIDFilter; + /** Filter by the object’s `ledgerTableName` field. */ + ledgerTableName?: StringFilter; + /** Filter by the object’s `meterCreditsTableId` field. */ + meterCreditsTableId?: UUIDFilter; + /** Filter by the object’s `meterCreditsTableName` field. */ + meterCreditsTableName?: StringFilter; + /** Filter by the object’s `meterDefaultsTableId` field. */ + meterDefaultsTableId?: UUIDFilter; + /** Filter by the object’s `meterDefaultsTableName` field. */ + meterDefaultsTableName?: StringFilter; + /** Filter by the object’s `meterSourcesTableId` field. */ + meterSourcesTableId?: UUIDFilter; + /** Filter by the object’s `meterSourcesTableName` field. */ + meterSourcesTableName?: StringFilter; + /** Filter by the object’s `metersTableId` field. */ + metersTableId?: UUIDFilter; + /** Filter by the object’s `metersTableName` field. */ + metersTableName?: StringFilter; + /** Negates the expression. */ + not?: BillingModuleFilter; + /** Checks for any expressions in this list. */ + or?: BillingModuleFilter[]; + /** Filter by the object’s `planSubscriptionsTableId` field. */ + planSubscriptionsTableId?: UUIDFilter; + /** Filter by the object’s `planSubscriptionsTableName` field. */ + planSubscriptionsTableName?: StringFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `recordUsageFunction` field. */ + recordUsageFunction?: StringFilter; + /** Filter by the object’s `rollupUsageSummaryFunction` field. */ + rollupUsageSummaryFunction?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `sweepExpiredSubscriptionsFunction` field. */ + sweepExpiredSubscriptionsFunction?: StringFilter; +} +export interface BillingProviderModuleFilter { + /** Checks for all expressions in this list. */ + and?: BillingProviderModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `billingCustomersTableId` field. */ billingCustomersTableId?: UUIDFilter; /** Filter by the object’s `billingCustomersTableName` field. */ billingCustomersTableName?: StringFilter; @@ -4002,6 +4420,72 @@ export interface BlueprintTemplateFilter { /** Filter by the object’s `visibility` field. */ visibility?: StringFilter; } +export interface CatalogModuleFilter { + /** Checks for all expressions in this list. */ + and?: CatalogModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableId` field. */ + functionsTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableName` field. */ + functionsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `namespacesTableId` field. */ + namespacesTableId?: UUIDFilter; + /** Filter by the object’s `namespacesTableName` field. */ + namespacesTableName?: StringFilter; + /** Negates the expression. */ + not?: CatalogModuleFilter; + /** Checks for any expressions in this list. */ + or?: CatalogModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resourceDefinitionsTableId` field. */ + resourceDefinitionsTableId?: UUIDFilter; + /** Filter by the object’s `resourceDefinitionsTableName` field. */ + resourceDefinitionsTableName?: StringFilter; + /** Filter by the object’s `resourceInstallationsTableId` field. */ + resourceInstallationsTableId?: UUIDFilter; + /** Filter by the object’s `resourceInstallationsTableName` field. */ + resourceInstallationsTableName?: StringFilter; + /** Filter by the object’s `resourcesTableId` field. */ + resourcesTableId?: UUIDFilter; + /** Filter by the object’s `resourcesTableName` field. */ + resourcesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} export interface ComputeLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ actorFkTableId?: UUIDFilter; @@ -4167,6 +4651,8 @@ export interface CryptoAuthModuleFilter { export interface DatabaseProvisionModuleFilter { /** Checks for all expressions in this list. */ and?: DatabaseProvisionModuleFilter[]; + /** Filter by the object’s `async` field. */ + async?: BooleanFilter; /** Filter by the object’s `bootstrapError` field. */ bootstrapError?: StringFilter; /** Filter by the object’s `bootstrapStatus` field. */ @@ -4442,6 +4928,58 @@ export interface DevicesModuleFilter { /** Filter by the object’s `userDevicesTableName` field. */ userDevicesTableName?: StringFilter; } +export interface DomainModuleFilter { + /** Checks for all expressions in this list. */ + and?: DomainModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainEventsTableId` field. */ + domainEventsTableId?: UUIDFilter; + /** Filter by the object’s `domainEventsTableName` field. */ + domainEventsTableName?: StringFilter; + /** Filter by the object’s `domainVerificationsTableId` field. */ + domainVerificationsTableId?: UUIDFilter; + /** Filter by the object’s `domainVerificationsTableName` field. */ + domainVerificationsTableName?: StringFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: DomainModuleFilter; + /** Checks for any expressions in this list. */ + or?: DomainModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} export interface EmailsModuleFilter { /** Checks for all expressions in this list. */ and?: EmailsModuleFilter[]; @@ -4713,6 +5251,10 @@ export interface FunctionInvocationModuleFilter { and?: FunctionInvocationModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; + /** Filter by the object’s `attemptsTableId` field. */ + attemptsTableId?: UUIDFilter; + /** Filter by the object’s `attemptsTableName` field. */ + attemptsTableName?: StringFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `defaultPermissions` field. */ @@ -6188,6 +6730,70 @@ export interface RlsModuleFilter { /** Filter by the object’s `usersTableId` field. */ usersTableId?: UUIDFilter; } +export interface RouteModuleFilter { + /** Checks for all expressions in this list. */ + and?: RouteModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainModule` relation. */ + domainModule?: DomainModuleFilter; + /** A related `domainModule` exists. */ + domainModuleExists?: boolean; + /** Filter by the object’s `domainModuleId` field. */ + domainModuleId?: UUIDFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableId` field. */ + hostnameBindingsTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableName` field. */ + hostnameBindingsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: RouteModuleFilter; + /** Checks for any expressions in this list. */ + or?: RouteModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resolverFunctionName` field. */ + resolverFunctionName?: StringFilter; + /** Filter by the object’s `routeBindingsTableId` field. */ + routeBindingsTableId?: UUIDFilter; + /** Filter by the object’s `routeBindingsTableName` field. */ + routeBindingsTableName?: StringFilter; + /** Filter by the object’s `routesTableId` field. */ + routesTableId?: UUIDFilter; + /** Filter by the object’s `routesTableName` field. */ + routesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} export interface SecureTableProvisionFilter { /** Checks for all expressions in this list. */ and?: SecureTableProvisionFilter[]; @@ -6268,6 +6874,50 @@ export interface SessionsModuleFilter { /** Filter by the object’s `usersTableId` field. */ usersTableId?: UUIDFilter; } +export interface SiteSurfaceModuleFilter { + /** Checks for all expressions in this list. */ + and?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: SiteSurfaceModuleFilter; + /** Checks for any expressions in this list. */ + or?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} export interface StorageLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ actorFkTableId?: UUIDFilter; @@ -6819,6 +7469,86 @@ export type AgentModuleOrderBy = | 'THREAD_TABLE_ID_DESC' | 'THREAD_TABLE_NAME_ASC' | 'THREAD_TABLE_NAME_DESC'; +export type ApiSurfaceModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; +export type AppModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'APP_MEMBERS_TABLE_ID_ASC' + | 'APP_MEMBERS_TABLE_ID_DESC' + | 'APP_MEMBERS_TABLE_NAME_ASC' + | 'APP_MEMBERS_TABLE_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type BillingModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' @@ -7023,6 +7753,68 @@ export type BlueprintTemplateOrderBy = | 'VERSION_DESC' | 'VISIBILITY_ASC' | 'VISIBILITY_DESC'; +export type CatalogModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_ID_ASC' + | 'FUNCTIONS_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_NAME_ASC' + | 'FUNCTIONS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NAMESPACES_TABLE_ID_ASC' + | 'NAMESPACES_TABLE_ID_DESC' + | 'NAMESPACES_TABLE_NAME_ASC' + | 'NAMESPACES_TABLE_NAME_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOURCES_TABLE_ID_ASC' + | 'RESOURCES_TABLE_ID_DESC' + | 'RESOURCES_TABLE_NAME_ASC' + | 'RESOURCES_TABLE_NAME_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; export type ComputeLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' | 'ACTOR_FK_TABLE_ID_DESC' @@ -7166,6 +7958,8 @@ export type CryptoAuthModuleOrderBy = | 'USER_FIELD_ASC' | 'USER_FIELD_DESC'; export type DatabaseProvisionModuleOrderBy = + | 'ASYNC_ASC' + | 'ASYNC_DESC' | 'BOOTSTRAP_ERROR_ASC' | 'BOOTSTRAP_ERROR_DESC' | 'BOOTSTRAP_STATUS_ASC' @@ -7409,6 +8203,50 @@ export type DevicesModuleOrderBy = | 'USER_DEVICES_TABLE_ID_DESC' | 'USER_DEVICES_TABLE_NAME_ASC' | 'USER_DEVICES_TABLE_NAME_DESC'; +export type DomainModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'DOMAIN_EVENTS_TABLE_ID_ASC' + | 'DOMAIN_EVENTS_TABLE_ID_DESC' + | 'DOMAIN_EVENTS_TABLE_NAME_ASC' + | 'DOMAIN_EVENTS_TABLE_NAME_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type EmailsModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' @@ -7654,6 +8492,10 @@ export type FunctionDeploymentModuleOrderBy = export type FunctionInvocationModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' + | 'ATTEMPTS_TABLE_ID_ASC' + | 'ATTEMPTS_TABLE_ID_DESC' + | 'ATTEMPTS_TABLE_NAME_ASC' + | 'ATTEMPTS_TABLE_NAME_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DEFAULT_PERMISSIONS_ASC' @@ -8975,6 +9817,58 @@ export type RlsModuleOrderBy = | 'SESSION_CREDENTIALS_TABLE_ID_DESC' | 'USERS_TABLE_ID_ASC' | 'USERS_TABLE_ID_DESC'; +export type RouteModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAIN_MODULE_ID_ASC' + | 'DOMAIN_MODULE_ID_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_ID_ASC' + | 'HOSTNAME_BINDINGS_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_ASC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOLVER_FUNCTION_NAME_ASC' + | 'RESOLVER_FUNCTION_NAME_DESC' + | 'ROUTES_TABLE_ID_ASC' + | 'ROUTES_TABLE_ID_DESC' + | 'ROUTES_TABLE_NAME_ASC' + | 'ROUTES_TABLE_NAME_DESC' + | 'ROUTE_BINDINGS_TABLE_ID_ASC' + | 'ROUTE_BINDINGS_TABLE_ID_DESC' + | 'ROUTE_BINDINGS_TABLE_NAME_ASC' + | 'ROUTE_BINDINGS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type SecureTableProvisionOrderBy = | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' @@ -9031,18 +9925,54 @@ export type SessionsModuleOrderBy = | 'PRIMARY_KEY_DESC' | 'SCHEMA_ID_ASC' | 'SCHEMA_ID_DESC' - | 'SESSIONS_DEFAULT_EXPIRATION_ASC' - | 'SESSIONS_DEFAULT_EXPIRATION_DESC' - | 'SESSIONS_TABLE_ID_ASC' - | 'SESSIONS_TABLE_ID_DESC' - | 'SESSIONS_TABLE_NAME_ASC' - | 'SESSIONS_TABLE_NAME_DESC' - | 'SESSION_CREDENTIALS_TABLE_ID_ASC' - | 'SESSION_CREDENTIALS_TABLE_ID_DESC' - | 'SESSION_CREDENTIALS_TABLE_NAME_ASC' - | 'SESSION_CREDENTIALS_TABLE_NAME_DESC' - | 'USERS_TABLE_ID_ASC' - | 'USERS_TABLE_ID_DESC'; + | 'SESSIONS_DEFAULT_EXPIRATION_ASC' + | 'SESSIONS_DEFAULT_EXPIRATION_DESC' + | 'SESSIONS_TABLE_ID_ASC' + | 'SESSIONS_TABLE_ID_DESC' + | 'SESSIONS_TABLE_NAME_ASC' + | 'SESSIONS_TABLE_NAME_DESC' + | 'SESSION_CREDENTIALS_TABLE_ID_ASC' + | 'SESSION_CREDENTIALS_TABLE_ID_DESC' + | 'SESSION_CREDENTIALS_TABLE_NAME_ASC' + | 'SESSION_CREDENTIALS_TABLE_NAME_DESC' + | 'USERS_TABLE_ID_ASC' + | 'USERS_TABLE_ID_DESC'; +export type SiteSurfaceModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; export type StorageLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' | 'ACTOR_FK_TABLE_ID_DESC' @@ -9544,6 +10474,106 @@ export interface DeleteAgentModuleInput { clientMutationId?: string; id: string; } +export interface CreateApiSurfaceModuleInput { + clientMutationId?: string; + apiSurfaceModule: { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface ApiSurfaceModulePatch { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateApiSurfaceModuleInput { + clientMutationId?: string; + id: string; + apiSurfaceModulePatch: ApiSurfaceModulePatch; +} +export interface DeleteApiSurfaceModuleInput { + clientMutationId?: string; + id: string; +} +export interface CreateAppModuleInput { + clientMutationId?: string; + appModule: { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface AppModulePatch { + apiName?: string | null; + appMembersTableId?: string | null; + appMembersTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateAppModuleInput { + clientMutationId?: string; + id: string; + appModulePatch: AppModulePatch; +} +export interface DeleteAppModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateBillingModuleInput { clientMutationId?: string; billingModule: { @@ -9786,6 +10816,78 @@ export interface DeleteBlueprintTemplateInput { clientMutationId?: string; id: string; } +export interface CreateCatalogModuleInput { + clientMutationId?: string; + catalogModule: { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: Record; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; + }; +} +export interface CatalogModulePatch { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityTableId?: string | null; + functionsTableId?: string | null; + functionsTableName?: string | null; + namespacesTableId?: string | null; + namespacesTableName?: string | null; + policies?: Record | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resourceDefinitionsTableId?: string | null; + resourceDefinitionsTableName?: string | null; + resourceInstallationsTableId?: string | null; + resourceInstallationsTableName?: string | null; + resourcesTableId?: string | null; + resourcesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} +export interface UpdateCatalogModuleInput { + clientMutationId?: string; + id: string; + catalogModulePatch: CatalogModulePatch; +} +export interface DeleteCatalogModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateComputeLogModuleInput { clientMutationId?: string; computeLogModule: { @@ -9981,6 +11083,7 @@ export interface DeleteCryptoAuthModuleInput { export interface CreateDatabaseProvisionModuleInput { clientMutationId?: string; databaseProvisionModule: { + async?: boolean; bootstrapError?: string; bootstrapStatus?: string; bootstrapUser?: boolean; @@ -9999,6 +11102,7 @@ export interface CreateDatabaseProvisionModuleInput { }; } export interface DatabaseProvisionModulePatch { + async?: boolean | null; bootstrapError?: string | null; bootstrapStatus?: string | null; bootstrapUser?: boolean | null; @@ -10288,6 +11392,60 @@ export interface DeleteDevicesModuleInput { clientMutationId?: string; id: string; } +export interface CreateDomainModuleInput { + clientMutationId?: string; + domainModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface DomainModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainEventsTableId?: string | null; + domainEventsTableName?: string | null; + domainVerificationsTableId?: string | null; + domainVerificationsTableName?: string | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateDomainModuleInput { + clientMutationId?: string; + id: string; + domainModulePatch: DomainModulePatch; +} +export interface DeleteDomainModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateEmailsModuleInput { clientMutationId?: string; emailsModule: { @@ -10574,6 +11732,8 @@ export interface CreateFunctionInvocationModuleInput { clientMutationId?: string; functionInvocationModule: { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId: string; defaultPermissions?: string[]; entityField?: string; @@ -10595,6 +11755,8 @@ export interface CreateFunctionInvocationModuleInput { } export interface FunctionInvocationModulePatch { apiName?: string | null; + attemptsTableId?: string | null; + attemptsTableName?: string | null; databaseId?: string | null; defaultPermissions?: string[] | null; entityField?: string | null; @@ -12196,6 +13358,68 @@ export interface DeleteRlsModuleInput { clientMutationId?: string; id: string; } +export interface CreateRouteModuleInput { + clientMutationId?: string; + routeModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface RouteModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainModuleId?: string | null; + entityField?: string | null; + entityTableId?: string | null; + hostnameBindingsTableId?: string | null; + hostnameBindingsTableName?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resolverFunctionName?: string | null; + routeBindingsTableId?: string | null; + routeBindingsTableName?: string | null; + routesTableId?: string | null; + routesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateRouteModuleInput { + clientMutationId?: string; + id: string; + routeModulePatch: RouteModulePatch; +} +export interface DeleteRouteModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateSecureTableProvisionInput { clientMutationId?: string; secureTableProvision: { @@ -12278,19 +13502,65 @@ export interface SessionsModulePatch { authSettingsTableName?: string | null; databaseId?: string | null; schemaId?: string | null; - sessionCredentialsTableId?: string | null; - sessionCredentialsTableName?: string | null; - sessionsDefaultExpiration?: IntervalInput | null; - sessionsTableId?: string | null; - sessionsTableName?: string | null; - usersTableId?: string | null; + sessionCredentialsTableId?: string | null; + sessionCredentialsTableName?: string | null; + sessionsDefaultExpiration?: IntervalInput | null; + sessionsTableId?: string | null; + sessionsTableName?: string | null; + usersTableId?: string | null; +} +export interface UpdateSessionsModuleInput { + clientMutationId?: string; + id: string; + sessionsModulePatch: SessionsModulePatch; +} +export interface DeleteSessionsModuleInput { + clientMutationId?: string; + id: string; +} +export interface CreateSiteSurfaceModuleInput { + clientMutationId?: string; + siteSurfaceModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; + }; +} +export interface SiteSurfaceModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; } -export interface UpdateSessionsModuleInput { +export interface UpdateSiteSurfaceModuleInput { clientMutationId?: string; id: string; - sessionsModulePatch: SessionsModulePatch; + siteSurfaceModulePatch: SiteSurfaceModulePatch; } -export interface DeleteSessionsModuleInput { +export interface DeleteSiteSurfaceModuleInput { clientMutationId?: string; id: string; } @@ -12897,14 +14167,14 @@ export interface ProvisionRelationInput { } export interface ProvisionSpatialRelationInput { clientMutationId?: string; - pDatabaseId?: string; - pName?: string; - pOperator?: string; - pParamName?: string; - pSourceFieldId?: string; - pSourceTableId?: string; - pTargetFieldId?: string; - pTargetTableId?: string; + databaseId?: string; + name?: string; + operator?: string; + paramName?: string; + sourceFieldId?: string; + sourceTableId?: string; + targetFieldId?: string; + targetTableId?: string; } export interface ProvisionTableInput { clientMutationId?: string; @@ -13076,6 +14346,48 @@ export interface AgentModuleInput { threadTableId?: string; threadTableName?: string; } +/** An input for mutations affecting `ApiSurfaceModule` */ +export interface ApiSurfaceModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} +/** An input for mutations affecting `AppModule` */ +export interface AppModuleInput { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `BillingModule` */ export interface BillingModuleInput { apiName?: string; @@ -13226,6 +14538,38 @@ export interface BlueprintTemplateInput { /** Access control for the template. private: only the owner can see and copy. public: anyone can browse and copy from the marketplace. Defaults to private. */ visibility?: string; } +/** An input for mutations affecting `CatalogModule` */ +export interface CatalogModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + id?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: Record; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** An input for mutations affecting `ComputeLogModule` */ export interface ComputeLogModuleInput { actorFkTableId?: string; @@ -13304,6 +14648,8 @@ export interface CryptoAuthModuleInput { } /** An input for mutations affecting `DatabaseProvisionModule` */ export interface DatabaseProvisionModuleInput { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -13477,6 +14823,29 @@ export interface DevicesModuleInput { userDevicesTableId?: string; userDevicesTableName?: string; } +/** An input for mutations affecting `DomainModule` */ +export interface DomainModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `EmailsModule` */ export interface EmailsModuleInput { apiName?: string; @@ -13815,6 +15184,8 @@ export interface FunctionDeploymentModuleInput { /** An input for mutations affecting `FunctionInvocationModule` */ export interface FunctionInvocationModuleInput { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId: string; defaultPermissions?: string[]; entityField?: string; @@ -14603,6 +15974,33 @@ export interface RlsModuleInput { sessionsTableId?: string; usersTableId?: string; } +/** An input for mutations affecting `RouteModule` */ +export interface RouteModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `SecureTableProvision` */ export interface SecureTableProvisionInput { /** The database this provision belongs to. Required. */ @@ -14652,6 +16050,25 @@ export interface SessionsModuleInput { sessionsTableName?: string; usersTableId?: string; } +/** An input for mutations affecting `SiteSurfaceModule` */ +export interface SiteSurfaceModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** An input for mutations affecting `StorageLogModule` */ export interface StorageLogModuleInput { actorFkTableId?: string; @@ -15517,6 +16934,96 @@ export type DeleteAgentModulePayloadSelect = { }; clientMutationId?: boolean; }; +export interface CreateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was created by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was updated by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was deleted by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface CreateAppModulePayload { + /** The `AppModule` that was created by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateAppModulePayload { + /** The `AppModule` that was updated by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteAppModulePayload { + /** The `AppModule` that was deleted by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; export interface CreateBillingModulePayload { /** The `BillingModule` that was created by this mutation. */ billingModule?: BillingModule | null; @@ -15742,6 +17249,51 @@ export type DeleteBlueprintTemplatePayloadSelect = { }; clientMutationId?: boolean; }; +export interface CreateCatalogModulePayload { + /** The `CatalogModule` that was created by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateCatalogModulePayload { + /** The `CatalogModule` that was updated by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteCatalogModulePayload { + /** The `CatalogModule` that was deleted by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; export interface CreateComputeLogModulePayload { clientMutationId?: string | null; /** The `ComputeLogModule` that was created by this mutation. */ @@ -16327,6 +17879,51 @@ export type DeleteDevicesModulePayloadSelect = { select: DevicesModuleEdgeSelect; }; }; +export interface CreateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was created by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type CreateDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; +export interface UpdateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was updated by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type UpdateDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; +export interface DeleteDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was deleted by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type DeleteDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; export interface CreateEmailsModulePayload { clientMutationId?: string | null; /** The `EmailsModule` that was created by this mutation. */ @@ -17902,6 +19499,51 @@ export type DeleteRlsModulePayloadSelect = { select: RlsModuleEdgeSelect; }; }; +export interface CreateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was created by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type CreateRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; +export interface UpdateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was updated by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type UpdateRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; +export interface DeleteRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was deleted by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type DeleteRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; export interface CreateSecureTableProvisionPayload { clientMutationId?: string | null; /** The `SecureTableProvision` that was created by this mutation. */ @@ -18037,6 +19679,51 @@ export type DeleteSessionsModulePayloadSelect = { select: SessionsModuleEdgeSelect; }; }; +export interface CreateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was created by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type CreateSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; +export interface UpdateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was updated by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type UpdateSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; +export interface DeleteSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was deleted by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type DeleteSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; export interface CreateStorageLogModulePayload { clientMutationId?: string | null; /** The `StorageLogModule` that was created by this mutation. */ @@ -18564,6 +20251,30 @@ export type AgentModuleEdgeSelect = { select: AgentModuleSelect; }; }; +/** A `ApiSurfaceModule` edge in the connection. */ +export interface ApiSurfaceModuleEdge { + cursor?: string | null; + /** The `ApiSurfaceModule` at the end of the edge. */ + node?: ApiSurfaceModule | null; +} +export type ApiSurfaceModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: ApiSurfaceModuleSelect; + }; +}; +/** A `AppModule` edge in the connection. */ +export interface AppModuleEdge { + cursor?: string | null; + /** The `AppModule` at the end of the edge. */ + node?: AppModule | null; +} +export type AppModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: AppModuleSelect; + }; +}; /** A `BillingModule` edge in the connection. */ export interface BillingModuleEdge { cursor?: string | null; @@ -18624,6 +20335,18 @@ export type BlueprintTemplateEdgeSelect = { select: BlueprintTemplateSelect; }; }; +/** A `CatalogModule` edge in the connection. */ +export interface CatalogModuleEdge { + cursor?: string | null; + /** The `CatalogModule` at the end of the edge. */ + node?: CatalogModule | null; +} +export type CatalogModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: CatalogModuleSelect; + }; +}; /** A `ComputeLogModule` edge in the connection. */ export interface ComputeLogModuleEdge { cursor?: string | null; @@ -18780,6 +20503,18 @@ export type DevicesModuleEdgeSelect = { select: DevicesModuleSelect; }; }; +/** A `DomainModule` edge in the connection. */ +export interface DomainModuleEdge { + cursor?: string | null; + /** The `DomainModule` at the end of the edge. */ + node?: DomainModule | null; +} +export type DomainModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainModuleSelect; + }; +}; /** A `EmailsModule` edge in the connection. */ export interface EmailsModuleEdge { cursor?: string | null; @@ -19200,6 +20935,18 @@ export type RlsModuleEdgeSelect = { select: RlsModuleSelect; }; }; +/** A `RouteModule` edge in the connection. */ +export interface RouteModuleEdge { + cursor?: string | null; + /** The `RouteModule` at the end of the edge. */ + node?: RouteModule | null; +} +export type RouteModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: RouteModuleSelect; + }; +}; /** A `SecureTableProvision` edge in the connection. */ export interface SecureTableProvisionEdge { cursor?: string | null; @@ -19236,6 +20983,18 @@ export type SessionsModuleEdgeSelect = { select: SessionsModuleSelect; }; }; +/** A `SiteSurfaceModule` edge in the connection. */ +export interface SiteSurfaceModuleEdge { + cursor?: string | null; + /** The `SiteSurfaceModule` at the end of the edge. */ + node?: SiteSurfaceModule | null; +} +export type SiteSurfaceModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: SiteSurfaceModuleSelect; + }; +}; /** A `StorageLogModule` edge in the connection. */ export interface StorageLogModuleEdge { cursor?: string | null; diff --git a/sdk/constructive-react/src/modules/orm/models/apiSurfaceModule.ts b/sdk/constructive-react/src/modules/orm/models/apiSurfaceModule.ts new file mode 100644 index 000000000..12cb1d83e --- /dev/null +++ b/sdk/constructive-react/src/modules/orm/models/apiSurfaceModule.ts @@ -0,0 +1,245 @@ +/** + * ApiSurfaceModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ApiSurfaceModule, + ApiSurfaceModuleWithRelations, + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy, + CreateApiSurfaceModuleInput, + UpdateApiSurfaceModuleInput, + ApiSurfaceModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ApiSurfaceModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModule', + document, + variables, + transform: (data: { + apiSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + apiSurfaceModule: data.apiSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModule', + document, + variables, + transform: (data: { + apiSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + apiSurfaceModule: data.apiSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ApiSurfaceModule', + 'createApiSurfaceModule', + 'apiSurfaceModule', + args.select, + args.data, + 'CreateApiSurfaceModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'createApiSurfaceModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + ApiSurfaceModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'ApiSurfaceModule', + 'updateApiSurfaceModule', + 'apiSurfaceModule', + args.select, + args.where.id, + args.data, + 'UpdateApiSurfaceModuleInput', + 'id', + 'apiSurfaceModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'updateApiSurfaceModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'ApiSurfaceModule', + 'deleteApiSurfaceModule', + 'apiSurfaceModule', + { + id: args.where.id, + }, + 'DeleteApiSurfaceModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'deleteApiSurfaceModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/modules/orm/models/appModule.ts b/sdk/constructive-react/src/modules/orm/models/appModule.ts new file mode 100644 index 000000000..78c5786d0 --- /dev/null +++ b/sdk/constructive-react/src/modules/orm/models/appModule.ts @@ -0,0 +1,245 @@ +/** + * AppModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + AppModule, + AppModuleWithRelations, + AppModuleSelect, + AppModuleFilter, + AppModuleOrderBy, + CreateAppModuleInput, + UpdateAppModuleInput, + AppModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class AppModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'AppModule', + 'appModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'AppModule', + 'appModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModule', + document, + variables, + transform: (data: { + appModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + appModule: data.appModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'AppModule', + 'appModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModule', + document, + variables, + transform: (data: { + appModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + appModule: data.appModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'AppModule', + 'createAppModule', + 'appModule', + args.select, + args.data, + 'CreateAppModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'createAppModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + AppModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'AppModule', + 'updateAppModule', + 'appModule', + args.select, + args.where.id, + args.data, + 'UpdateAppModuleInput', + 'id', + 'appModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'updateAppModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'AppModule', + 'deleteAppModule', + 'appModule', + { + id: args.where.id, + }, + 'DeleteAppModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'deleteAppModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/modules/orm/models/catalogModule.ts b/sdk/constructive-react/src/modules/orm/models/catalogModule.ts new file mode 100644 index 000000000..f03b06347 --- /dev/null +++ b/sdk/constructive-react/src/modules/orm/models/catalogModule.ts @@ -0,0 +1,245 @@ +/** + * CatalogModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + CatalogModule, + CatalogModuleWithRelations, + CatalogModuleSelect, + CatalogModuleFilter, + CatalogModuleOrderBy, + CreateCatalogModuleInput, + UpdateCatalogModuleInput, + CatalogModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class CatalogModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModule', + document, + variables, + transform: (data: { + catalogModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + catalogModule: data.catalogModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModule', + document, + variables, + transform: (data: { + catalogModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + catalogModule: data.catalogModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'CatalogModule', + 'createCatalogModule', + 'catalogModule', + args.select, + args.data, + 'CreateCatalogModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'createCatalogModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + CatalogModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'CatalogModule', + 'updateCatalogModule', + 'catalogModule', + args.select, + args.where.id, + args.data, + 'UpdateCatalogModuleInput', + 'id', + 'catalogModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'updateCatalogModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'CatalogModule', + 'deleteCatalogModule', + 'catalogModule', + { + id: args.where.id, + }, + 'DeleteCatalogModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'deleteCatalogModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/modules/orm/models/domainModule.ts b/sdk/constructive-react/src/modules/orm/models/domainModule.ts new file mode 100644 index 000000000..fd1f53622 --- /dev/null +++ b/sdk/constructive-react/src/modules/orm/models/domainModule.ts @@ -0,0 +1,245 @@ +/** + * DomainModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainModule, + DomainModuleWithRelations, + DomainModuleSelect, + DomainModuleFilter, + DomainModuleOrderBy, + CreateDomainModuleInput, + UpdateDomainModuleInput, + DomainModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModule', + document, + variables, + transform: (data: { + domainModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainModule: data.domainModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModule', + document, + variables, + transform: (data: { + domainModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainModule: data.domainModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainModule', + 'createDomainModule', + 'domainModule', + args.select, + args.data, + 'CreateDomainModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'createDomainModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainModule', + 'updateDomainModule', + 'domainModule', + args.select, + args.where.id, + args.data, + 'UpdateDomainModuleInput', + 'id', + 'domainModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'updateDomainModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainModule', + 'deleteDomainModule', + 'domainModule', + { + id: args.where.id, + }, + 'DeleteDomainModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'deleteDomainModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/modules/orm/models/index.ts b/sdk/constructive-react/src/modules/orm/models/index.ts index 4cabf5cd9..2143a553f 100644 --- a/sdk/constructive-react/src/modules/orm/models/index.ts +++ b/sdk/constructive-react/src/modules/orm/models/index.ts @@ -4,11 +4,14 @@ * DO NOT EDIT - changes will be overwritten */ export { AgentModuleModel } from './agentModule'; +export { ApiSurfaceModuleModel } from './apiSurfaceModule'; +export { AppModuleModel } from './appModule'; export { BillingModuleModel } from './billingModule'; export { BillingProviderModuleModel } from './billingProviderModule'; export { BlueprintModel } from './blueprint'; export { BlueprintConstructionModel } from './blueprintConstruction'; export { BlueprintTemplateModel } from './blueprintTemplate'; +export { CatalogModuleModel } from './catalogModule'; export { ComputeLogModuleModel } from './computeLogModule'; export { ConfigSecretsUserModuleModel } from './configSecretsUserModule'; export { ConnectedAccountsModuleModel } from './connectedAccountsModule'; @@ -22,6 +25,7 @@ export { DbUsageModuleModel } from './dbUsageModule'; export { DefaultIdsModuleModel } from './defaultIdsModule'; export { DenormalizedTableFieldModel } from './denormalizedTableField'; export { DevicesModuleModel } from './devicesModule'; +export { DomainModuleModel } from './domainModule'; export { EmailsModuleModel } from './emailsModule'; export { EntityTypeProvisionModel } from './entityTypeProvision'; export { EventsModuleModel } from './eventsModule'; @@ -57,9 +61,11 @@ export { RealtimeModuleModel } from './realtimeModule'; export { RelationProvisionModel } from './relationProvision'; export { ResourceModuleModel } from './resourceModule'; export { RlsModuleModel } from './rlsModule'; +export { RouteModuleModel } from './routeModule'; export { SecureTableProvisionModel } from './secureTableProvision'; export { SessionSecretsModuleModel } from './sessionSecretsModule'; export { SessionsModuleModel } from './sessionsModule'; +export { SiteSurfaceModuleModel } from './siteSurfaceModule'; export { StorageLogModuleModel } from './storageLogModule'; export { StorageModuleModel } from './storageModule'; export { TransferLogModuleModel } from './transferLogModule'; diff --git a/sdk/constructive-react/src/modules/orm/models/routeModule.ts b/sdk/constructive-react/src/modules/orm/models/routeModule.ts new file mode 100644 index 000000000..d57b13cea --- /dev/null +++ b/sdk/constructive-react/src/modules/orm/models/routeModule.ts @@ -0,0 +1,245 @@ +/** + * RouteModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + RouteModule, + RouteModuleWithRelations, + RouteModuleSelect, + RouteModuleFilter, + RouteModuleOrderBy, + CreateRouteModuleInput, + UpdateRouteModuleInput, + RouteModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class RouteModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModule', + document, + variables, + transform: (data: { + routeModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + routeModule: data.routeModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModule', + document, + variables, + transform: (data: { + routeModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + routeModule: data.routeModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'RouteModule', + 'createRouteModule', + 'routeModule', + args.select, + args.data, + 'CreateRouteModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'createRouteModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + RouteModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'RouteModule', + 'updateRouteModule', + 'routeModule', + args.select, + args.where.id, + args.data, + 'UpdateRouteModuleInput', + 'id', + 'routeModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'updateRouteModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'RouteModule', + 'deleteRouteModule', + 'routeModule', + { + id: args.where.id, + }, + 'DeleteRouteModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'deleteRouteModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/modules/orm/models/siteSurfaceModule.ts b/sdk/constructive-react/src/modules/orm/models/siteSurfaceModule.ts new file mode 100644 index 000000000..891f21403 --- /dev/null +++ b/sdk/constructive-react/src/modules/orm/models/siteSurfaceModule.ts @@ -0,0 +1,245 @@ +/** + * SiteSurfaceModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + SiteSurfaceModule, + SiteSurfaceModuleWithRelations, + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy, + CreateSiteSurfaceModuleInput, + UpdateSiteSurfaceModuleInput, + SiteSurfaceModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class SiteSurfaceModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModule', + document, + variables, + transform: (data: { + siteSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + siteSurfaceModule: data.siteSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModule', + document, + variables, + transform: (data: { + siteSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + siteSurfaceModule: data.siteSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'SiteSurfaceModule', + 'createSiteSurfaceModule', + 'siteSurfaceModule', + args.select, + args.data, + 'CreateSiteSurfaceModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'createSiteSurfaceModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + SiteSurfaceModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'SiteSurfaceModule', + 'updateSiteSurfaceModule', + 'siteSurfaceModule', + args.select, + args.where.id, + args.data, + 'UpdateSiteSurfaceModuleInput', + 'id', + 'siteSurfaceModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'updateSiteSurfaceModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'SiteSurfaceModule', + 'deleteSiteSurfaceModule', + 'siteSurfaceModule', + { + id: args.where.id, + }, + 'DeleteSiteSurfaceModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'deleteSiteSurfaceModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-react/src/modules/schema-types.ts b/sdk/constructive-react/src/modules/schema-types.ts index d29d13b8d..17a59a691 100644 --- a/sdk/constructive-react/src/modules/schema-types.ts +++ b/sdk/constructive-react/src/modules/schema-types.ts @@ -6,11 +6,14 @@ import type { AgentModule, + ApiSurfaceModule, + AppModule, BillingModule, BillingProviderModule, Blueprint, BlueprintConstruction, BlueprintTemplate, + CatalogModule, ComputeLogModule, ConfigSecretsUserModule, ConnectedAccountsModule, @@ -24,6 +27,7 @@ import type { DefaultIdsModule, DenormalizedTableField, DevicesModule, + DomainModule, EmailsModule, EntityTypeProvision, EventsModule, @@ -59,9 +63,11 @@ import type { RelationProvision, ResourceModule, RlsModule, + RouteModule, SecureTableProvision, SessionSecretsModule, SessionsModule, + SiteSurfaceModule, StorageLogModule, StorageModule, TransferLogModule, @@ -168,6 +174,88 @@ export type AgentModuleOrderBy = | 'THREAD_TABLE_ID_DESC' | 'THREAD_TABLE_NAME_ASC' | 'THREAD_TABLE_NAME_DESC'; +/** Methods to use when ordering `ApiSurfaceModule`. */ +export type ApiSurfaceModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; +/** Methods to use when ordering `AppModule`. */ +export type AppModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'APP_MEMBERS_TABLE_ID_ASC' + | 'APP_MEMBERS_TABLE_ID_DESC' + | 'APP_MEMBERS_TABLE_NAME_ASC' + | 'APP_MEMBERS_TABLE_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; /** Methods to use when ordering `BillingModule`. */ export type BillingModuleOrderBy = | 'API_NAME_ASC' @@ -377,6 +465,69 @@ export type BlueprintTemplateOrderBy = | 'VERSION_DESC' | 'VISIBILITY_ASC' | 'VISIBILITY_DESC'; +/** Methods to use when ordering `CatalogModule`. */ +export type CatalogModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_ID_ASC' + | 'FUNCTIONS_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_NAME_ASC' + | 'FUNCTIONS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NAMESPACES_TABLE_ID_ASC' + | 'NAMESPACES_TABLE_ID_DESC' + | 'NAMESPACES_TABLE_NAME_ASC' + | 'NAMESPACES_TABLE_NAME_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOURCES_TABLE_ID_ASC' + | 'RESOURCES_TABLE_ID_DESC' + | 'RESOURCES_TABLE_NAME_ASC' + | 'RESOURCES_TABLE_NAME_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; /** Methods to use when ordering `ComputeLogModule`. */ export type ComputeLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' @@ -526,6 +677,8 @@ export type CryptoAuthModuleOrderBy = | 'USER_FIELD_DESC'; /** Methods to use when ordering `DatabaseProvisionModule`. */ export type DatabaseProvisionModuleOrderBy = + | 'ASYNC_ASC' + | 'ASYNC_DESC' | 'BOOTSTRAP_ERROR_ASC' | 'BOOTSTRAP_ERROR_DESC' | 'BOOTSTRAP_STATUS_ASC' @@ -776,6 +929,51 @@ export type DevicesModuleOrderBy = | 'USER_DEVICES_TABLE_ID_DESC' | 'USER_DEVICES_TABLE_NAME_ASC' | 'USER_DEVICES_TABLE_NAME_DESC'; +/** Methods to use when ordering `DomainModule`. */ +export type DomainModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'DOMAIN_EVENTS_TABLE_ID_ASC' + | 'DOMAIN_EVENTS_TABLE_ID_DESC' + | 'DOMAIN_EVENTS_TABLE_NAME_ASC' + | 'DOMAIN_EVENTS_TABLE_NAME_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; /** Methods to use when ordering `EmailsModule`. */ export type EmailsModuleOrderBy = | 'API_NAME_ASC' @@ -1026,6 +1224,10 @@ export type FunctionDeploymentModuleOrderBy = export type FunctionInvocationModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' + | 'ATTEMPTS_TABLE_ID_ASC' + | 'ATTEMPTS_TABLE_ID_DESC' + | 'ATTEMPTS_TABLE_NAME_ASC' + | 'ATTEMPTS_TABLE_NAME_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DEFAULT_PERMISSIONS_ASC' @@ -2377,6 +2579,59 @@ export type RlsModuleOrderBy = | 'SESSION_CREDENTIALS_TABLE_ID_DESC' | 'USERS_TABLE_ID_ASC' | 'USERS_TABLE_ID_DESC'; +/** Methods to use when ordering `RouteModule`. */ +export type RouteModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAIN_MODULE_ID_ASC' + | 'DOMAIN_MODULE_ID_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_ID_ASC' + | 'HOSTNAME_BINDINGS_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_ASC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOLVER_FUNCTION_NAME_ASC' + | 'RESOLVER_FUNCTION_NAME_DESC' + | 'ROUTES_TABLE_ID_ASC' + | 'ROUTES_TABLE_ID_DESC' + | 'ROUTES_TABLE_NAME_ASC' + | 'ROUTES_TABLE_NAME_DESC' + | 'ROUTE_BINDINGS_TABLE_ID_ASC' + | 'ROUTE_BINDINGS_TABLE_ID_DESC' + | 'ROUTE_BINDINGS_TABLE_NAME_ASC' + | 'ROUTE_BINDINGS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; /** Methods to use when ordering `SecureTableProvision`. */ export type SecureTableProvisionOrderBy = | 'DATABASE_ID_ASC' @@ -2448,6 +2703,43 @@ export type SessionsModuleOrderBy = | 'SESSION_CREDENTIALS_TABLE_NAME_DESC' | 'USERS_TABLE_ID_ASC' | 'USERS_TABLE_ID_DESC'; +/** Methods to use when ordering `SiteSurfaceModule`. */ +export type SiteSurfaceModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; /** Methods to use when ordering `StorageLogModule`. */ export type StorageLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' @@ -3032,6 +3324,188 @@ export interface AgentModulePatch { threadTableId?: string; threadTableName?: string; } +/** A filter to be used against `ApiSurfaceModule` object types. All fields are combined with a logical ‘and.’ */ +export interface ApiSurfaceModuleFilter { + /** Checks for all expressions in this list. */ + and?: ApiSurfaceModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: ApiSurfaceModuleFilter; + /** Checks for any expressions in this list. */ + or?: ApiSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} +/** An input for mutations affecting `ApiSurfaceModule` */ +export interface ApiSurfaceModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} +/** Represents an update to a `ApiSurfaceModule`. Fields that are set will be updated. */ +export interface ApiSurfaceModulePatch { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId?: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} +/** A filter to be used against `AppModule` object types. All fields are combined with a logical ‘and.’ */ +export interface AppModuleFilter { + /** Checks for all expressions in this list. */ + and?: AppModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `appMembersTableId` field. */ + appMembersTableId?: UUIDFilter; + /** Filter by the object’s `appMembersTableName` field. */ + appMembersTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: AppModuleFilter; + /** Checks for any expressions in this list. */ + or?: AppModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} +/** An input for mutations affecting `AppModule` */ +export interface AppModuleInput { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: unknown; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} +/** Represents an update to a `AppModule`. Fields that are set will be updated. */ +export interface AppModulePatch { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId?: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: unknown; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} /** A filter to be used against `BillingModule` object types. All fields are combined with a logical ‘and.’ */ export interface BillingModuleFilter { /** Checks for all expressions in this list. */ @@ -3610,6 +4084,137 @@ export interface BlueprintToManyBlueprintConstructionFilter { /** Filters to entities where at least one related entity matches. */ some?: BlueprintConstructionFilter; } +/** A filter to be used against `CatalogModule` object types. All fields are combined with a logical ‘and.’ */ +export interface CatalogModuleFilter { + /** Checks for all expressions in this list. */ + and?: CatalogModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableId` field. */ + functionsTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableName` field. */ + functionsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `namespacesTableId` field. */ + namespacesTableId?: UUIDFilter; + /** Filter by the object’s `namespacesTableName` field. */ + namespacesTableName?: StringFilter; + /** Negates the expression. */ + not?: CatalogModuleFilter; + /** Checks for any expressions in this list. */ + or?: CatalogModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resourceDefinitionsTableId` field. */ + resourceDefinitionsTableId?: UUIDFilter; + /** Filter by the object’s `resourceDefinitionsTableName` field. */ + resourceDefinitionsTableName?: StringFilter; + /** Filter by the object’s `resourceInstallationsTableId` field. */ + resourceInstallationsTableId?: UUIDFilter; + /** Filter by the object’s `resourceInstallationsTableName` field. */ + resourceInstallationsTableName?: StringFilter; + /** Filter by the object’s `resourcesTableId` field. */ + resourcesTableId?: UUIDFilter; + /** Filter by the object’s `resourcesTableName` field. */ + resourcesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} +/** An input for mutations affecting `CatalogModule` */ +export interface CatalogModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + id?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: unknown; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} +/** Represents an update to a `CatalogModule`. Fields that are set will be updated. */ +export interface CatalogModulePatch { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId?: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + id?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: unknown; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** A filter to be used against `ComputeLogModule` object types. All fields are combined with a logical ‘and.’ */ export interface ComputeLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ @@ -3821,6 +4426,16 @@ export interface CreateAgentModuleInput { agentModule: AgentModuleInput; clientMutationId?: string; } +export interface CreateApiSurfaceModuleInput { + /** The `ApiSurfaceModule` to be created by this mutation. */ + apiSurfaceModule: ApiSurfaceModuleInput; + clientMutationId?: string; +} +export interface CreateAppModuleInput { + /** The `AppModule` to be created by this mutation. */ + appModule: AppModuleInput; + clientMutationId?: string; +} export interface CreateBillingModuleInput { /** The `BillingModule` to be created by this mutation. */ billingModule: BillingModuleInput; @@ -3846,6 +4461,11 @@ export interface CreateBlueprintTemplateInput { blueprintTemplate: BlueprintTemplateInput; clientMutationId?: string; } +export interface CreateCatalogModuleInput { + /** The `CatalogModule` to be created by this mutation. */ + catalogModule: CatalogModuleInput; + clientMutationId?: string; +} export interface CreateComputeLogModuleInput { clientMutationId?: string; /** The `ComputeLogModule` to be created by this mutation. */ @@ -3911,6 +4531,11 @@ export interface CreateDevicesModuleInput { /** The `DevicesModule` to be created by this mutation. */ devicesModule: DevicesModuleInput; } +export interface CreateDomainModuleInput { + clientMutationId?: string; + /** The `DomainModule` to be created by this mutation. */ + domainModule: DomainModuleInput; +} export interface CreateEmailsModuleInput { clientMutationId?: string; /** The `EmailsModule` to be created by this mutation. */ @@ -4086,6 +4711,11 @@ export interface CreateRlsModuleInput { /** The `RlsModule` to be created by this mutation. */ rlsModule: RlsModuleInput; } +export interface CreateRouteModuleInput { + clientMutationId?: string; + /** The `RouteModule` to be created by this mutation. */ + routeModule: RouteModuleInput; +} export interface CreateSecureTableProvisionInput { clientMutationId?: string; /** The `SecureTableProvision` to be created by this mutation. */ @@ -4101,6 +4731,11 @@ export interface CreateSessionsModuleInput { /** The `SessionsModule` to be created by this mutation. */ sessionsModule: SessionsModuleInput; } +export interface CreateSiteSurfaceModuleInput { + clientMutationId?: string; + /** The `SiteSurfaceModule` to be created by this mutation. */ + siteSurfaceModule: SiteSurfaceModuleInput; +} export interface CreateStorageLogModuleInput { clientMutationId?: string; /** The `StorageLogModule` to be created by this mutation. */ @@ -4286,6 +4921,8 @@ export interface CryptoAuthModulePatch { export interface DatabaseProvisionModuleFilter { /** Checks for all expressions in this list. */ and?: DatabaseProvisionModuleFilter[]; + /** Filter by the object’s `async` field. */ + async?: BooleanFilter; /** Filter by the object’s `bootstrapError` field. */ bootstrapError?: StringFilter; /** Filter by the object’s `bootstrapStatus` field. */ @@ -4329,6 +4966,8 @@ export interface DatabaseProvisionModuleFilter { } /** An input for mutations affecting `DatabaseProvisionModule` */ export interface DatabaseProvisionModuleInput { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -4363,6 +5002,8 @@ export interface DatabaseProvisionModuleInput { } /** Represents an update to a `DatabaseProvisionModule`. Fields that are set will be updated. */ export interface DatabaseProvisionModulePatch { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -4778,6 +5419,14 @@ export interface DeleteAgentModuleInput { clientMutationId?: string; id: string; } +export interface DeleteApiSurfaceModuleInput { + clientMutationId?: string; + id: string; +} +export interface DeleteAppModuleInput { + clientMutationId?: string; + id: string; +} export interface DeleteBillingModuleInput { clientMutationId?: string; id: string; @@ -4801,6 +5450,10 @@ export interface DeleteBlueprintTemplateInput { /** Unique identifier for this template. */ id: string; } +export interface DeleteCatalogModuleInput { + clientMutationId?: string; + id: string; +} export interface DeleteComputeLogModuleInput { clientMutationId?: string; id: string; @@ -4853,6 +5506,10 @@ export interface DeleteDevicesModuleInput { clientMutationId?: string; id: string; } +export interface DeleteDomainModuleInput { + clientMutationId?: string; + id: string; +} export interface DeleteEmailsModuleInput { clientMutationId?: string; id: string; @@ -4995,6 +5652,10 @@ export interface DeleteRlsModuleInput { clientMutationId?: string; id: string; } +export interface DeleteRouteModuleInput { + clientMutationId?: string; + id: string; +} export interface DeleteSecureTableProvisionInput { clientMutationId?: string; /** Unique identifier for this provision row. */ @@ -5008,6 +5669,10 @@ export interface DeleteSessionsModuleInput { clientMutationId?: string; id: string; } +export interface DeleteSiteSurfaceModuleInput { + clientMutationId?: string; + id: string; +} export interface DeleteStorageLogModuleInput { clientMutationId?: string; id: string; @@ -5138,25 +5803,124 @@ export interface DevicesModuleFilter { /** Filter by the object’s `userDevicesTableName` field. */ userDevicesTableName?: StringFilter; } -/** An input for mutations affecting `DevicesModule` */ -export interface DevicesModuleInput { +/** An input for mutations affecting `DevicesModule` */ +export interface DevicesModuleInput { + databaseId: string; + deviceSettingsTableId?: string; + deviceSettingsTableName?: string; + id?: string; + schemaId?: string; + userDevicesTableId?: string; + userDevicesTableName?: string; +} +/** Represents an update to a `DevicesModule`. Fields that are set will be updated. */ +export interface DevicesModulePatch { + databaseId?: string; + deviceSettingsTableId?: string; + deviceSettingsTableName?: string; + id?: string; + schemaId?: string; + userDevicesTableId?: string; + userDevicesTableName?: string; +} +/** A filter to be used against `DomainModule` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainModuleFilter { + /** Checks for all expressions in this list. */ + and?: DomainModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainEventsTableId` field. */ + domainEventsTableId?: UUIDFilter; + /** Filter by the object’s `domainEventsTableName` field. */ + domainEventsTableName?: StringFilter; + /** Filter by the object’s `domainVerificationsTableId` field. */ + domainVerificationsTableId?: UUIDFilter; + /** Filter by the object’s `domainVerificationsTableName` field. */ + domainVerificationsTableName?: StringFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: DomainModuleFilter; + /** Checks for any expressions in this list. */ + or?: DomainModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} +/** An input for mutations affecting `DomainModule` */ +export interface DomainModuleInput { + apiName?: string; + catalogModuleId?: string; databaseId: string; - deviceSettingsTableId?: string; - deviceSettingsTableName?: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; schemaId?: string; - userDevicesTableId?: string; - userDevicesTableName?: string; + scope?: string; } -/** Represents an update to a `DevicesModule`. Fields that are set will be updated. */ -export interface DevicesModulePatch { +/** Represents an update to a `DomainModule`. Fields that are set will be updated. */ +export interface DomainModulePatch { + apiName?: string; + catalogModuleId?: string; databaseId?: string; - deviceSettingsTableId?: string; - deviceSettingsTableName?: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; schemaId?: string; - userDevicesTableId?: string; - userDevicesTableName?: string; + scope?: string; } /** A filter to be used against `EmailsModule` object types. All fields are combined with a logical ‘and.’ */ export interface EmailsModuleFilter { @@ -6104,6 +6868,10 @@ export interface FunctionInvocationModuleFilter { and?: FunctionInvocationModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; + /** Filter by the object’s `attemptsTableId` field. */ + attemptsTableId?: UUIDFilter; + /** Filter by the object’s `attemptsTableName` field. */ + attemptsTableName?: StringFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `defaultPermissions` field. */ @@ -6148,6 +6916,8 @@ export interface FunctionInvocationModuleFilter { /** An input for mutations affecting `FunctionInvocationModule` */ export interface FunctionInvocationModuleInput { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId: string; defaultPermissions?: string[]; entityField?: string; @@ -6170,6 +6940,8 @@ export interface FunctionInvocationModuleInput { /** Represents an update to a `FunctionInvocationModule`. Fields that are set will be updated. */ export interface FunctionInvocationModulePatch { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId?: string; defaultPermissions?: string[]; entityField?: string; @@ -8599,14 +9371,14 @@ export interface ProvisionRelationInput { } export interface ProvisionSpatialRelationInput { clientMutationId?: string; - pDatabaseId?: string; - pName?: string; - pOperator?: string; - pParamName?: string; - pSourceFieldId?: string; - pSourceTableId?: string; - pTargetFieldId?: string; - pTargetTableId?: string; + databaseId?: string; + name?: string; + operator?: string; + paramName?: string; + sourceFieldId?: string; + sourceTableId?: string; + targetFieldId?: string; + targetTableId?: string; } export interface ProvisionTableInput { clientMutationId?: string; @@ -9374,6 +10146,125 @@ export interface RlsModulePatch { sessionsTableId?: string; usersTableId?: string; } +/** A filter to be used against `RouteModule` object types. All fields are combined with a logical ‘and.’ */ +export interface RouteModuleFilter { + /** Checks for all expressions in this list. */ + and?: RouteModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainModule` relation. */ + domainModule?: DomainModuleFilter; + /** A related `domainModule` exists. */ + domainModuleExists?: boolean; + /** Filter by the object’s `domainModuleId` field. */ + domainModuleId?: UUIDFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableId` field. */ + hostnameBindingsTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableName` field. */ + hostnameBindingsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: RouteModuleFilter; + /** Checks for any expressions in this list. */ + or?: RouteModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resolverFunctionName` field. */ + resolverFunctionName?: StringFilter; + /** Filter by the object’s `routeBindingsTableId` field. */ + routeBindingsTableId?: UUIDFilter; + /** Filter by the object’s `routeBindingsTableName` field. */ + routeBindingsTableName?: StringFilter; + /** Filter by the object’s `routesTableId` field. */ + routesTableId?: UUIDFilter; + /** Filter by the object’s `routesTableName` field. */ + routesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} +/** An input for mutations affecting `RouteModule` */ +export interface RouteModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: unknown; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; +} +/** Represents an update to a `RouteModule`. Fields that are set will be updated. */ +export interface RouteModulePatch { + apiName?: string; + catalogModuleId?: string; + databaseId?: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: unknown; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; +} /** A filter to be used against `SecureTableProvision` object types. All fields are combined with a logical ‘and.’ */ export interface SecureTableProvisionFilter { /** Checks for all expressions in this list. */ @@ -9555,6 +10446,89 @@ export interface SessionsModulePatch { sessionsTableName?: string; usersTableId?: string; } +/** A filter to be used against `SiteSurfaceModule` object types. All fields are combined with a logical ‘and.’ */ +export interface SiteSurfaceModuleFilter { + /** Checks for all expressions in this list. */ + and?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: SiteSurfaceModuleFilter; + /** Checks for any expressions in this list. */ + or?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} +/** An input for mutations affecting `SiteSurfaceModule` */ +export interface SiteSurfaceModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} +/** Represents an update to a `SiteSurfaceModule`. Fields that are set will be updated. */ +export interface SiteSurfaceModulePatch { + apiName?: string; + catalogModuleId?: string; + databaseId?: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: unknown; + prefix?: string; + privateApiName?: string; + provisions?: unknown; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** A filter to be used against `StorageLogModule` object types. All fields are combined with a logical ‘and.’ */ export interface StorageLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ @@ -9926,6 +10900,18 @@ export interface UpdateAgentModuleInput { clientMutationId?: string; id: string; } +export interface UpdateApiSurfaceModuleInput { + /** An object where the defined keys will be set on the `ApiSurfaceModule` being updated. */ + apiSurfaceModulePatch: ApiSurfaceModulePatch; + clientMutationId?: string; + id: string; +} +export interface UpdateAppModuleInput { + /** An object where the defined keys will be set on the `AppModule` being updated. */ + appModulePatch: AppModulePatch; + clientMutationId?: string; + id: string; +} export interface UpdateBillingModuleInput { /** An object where the defined keys will be set on the `BillingModule` being updated. */ billingModulePatch: BillingModulePatch; @@ -9959,6 +10945,12 @@ export interface UpdateBlueprintTemplateInput { /** Unique identifier for this template. */ id: string; } +export interface UpdateCatalogModuleInput { + /** An object where the defined keys will be set on the `CatalogModule` being updated. */ + catalogModulePatch: CatalogModulePatch; + clientMutationId?: string; + id: string; +} export interface UpdateComputeLogModuleInput { clientMutationId?: string; /** An object where the defined keys will be set on the `ComputeLogModule` being updated. */ @@ -10037,6 +11029,12 @@ export interface UpdateDevicesModuleInput { devicesModulePatch: DevicesModulePatch; id: string; } +export interface UpdateDomainModuleInput { + clientMutationId?: string; + /** An object where the defined keys will be set on the `DomainModule` being updated. */ + domainModulePatch: DomainModulePatch; + id: string; +} export interface UpdateEmailsModuleInput { clientMutationId?: string; /** An object where the defined keys will be set on the `EmailsModule` being updated. */ @@ -10249,6 +11247,12 @@ export interface UpdateRlsModuleInput { /** An object where the defined keys will be set on the `RlsModule` being updated. */ rlsModulePatch: RlsModulePatch; } +export interface UpdateRouteModuleInput { + clientMutationId?: string; + id: string; + /** An object where the defined keys will be set on the `RouteModule` being updated. */ + routeModulePatch: RouteModulePatch; +} export interface UpdateSecureTableProvisionInput { clientMutationId?: string; /** Unique identifier for this provision row. */ @@ -10268,6 +11272,12 @@ export interface UpdateSessionsModuleInput { /** An object where the defined keys will be set on the `SessionsModule` being updated. */ sessionsModulePatch: SessionsModulePatch; } +export interface UpdateSiteSurfaceModuleInput { + clientMutationId?: string; + id: string; + /** An object where the defined keys will be set on the `SiteSurfaceModule` being updated. */ + siteSurfaceModulePatch: SiteSurfaceModulePatch; +} export interface UpdateStorageLogModuleInput { clientMutationId?: string; id: string; @@ -10903,6 +11913,20 @@ export interface AgentModuleConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `ApiSurfaceModule` values. */ +export interface ApiSurfaceModuleConnection { + edges: ApiSurfaceModuleEdge[]; + nodes: ApiSurfaceModule[]; + pageInfo: PageInfo; + totalCount: number; +} +/** A connection to a list of `AppModule` values. */ +export interface AppModuleConnection { + edges: AppModuleEdge[]; + nodes: AppModule[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `BillingModule` values. */ export interface BillingModuleConnection { edges: BillingModuleEdge[]; @@ -10938,6 +11962,13 @@ export interface BlueprintConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `CatalogModule` values. */ +export interface CatalogModuleConnection { + edges: CatalogModuleEdge[]; + nodes: CatalogModule[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `ComputeLogModule` values. */ export interface ComputeLogModuleConnection { edges: ComputeLogModuleEdge[]; @@ -11029,6 +12060,13 @@ export interface DevicesModuleConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `DomainModule` values. */ +export interface DomainModuleConnection { + edges: DomainModuleEdge[]; + nodes: DomainModule[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `EmailsModule` values. */ export interface EmailsModuleConnection { edges: EmailsModuleEdge[]; @@ -11274,6 +12312,13 @@ export interface RlsModuleConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `RouteModule` values. */ +export interface RouteModuleConnection { + edges: RouteModuleEdge[]; + nodes: RouteModule[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `SecureTableProvision` values. */ export interface SecureTableProvisionConnection { edges: SecureTableProvisionEdge[]; @@ -11295,6 +12340,13 @@ export interface SessionsModuleConnection { pageInfo: PageInfo; totalCount: number; } +/** A connection to a list of `SiteSurfaceModule` values. */ +export interface SiteSurfaceModuleConnection { + edges: SiteSurfaceModuleEdge[]; + nodes: SiteSurfaceModule[]; + pageInfo: PageInfo; + totalCount: number; +} /** A connection to a list of `StorageLogModule` values. */ export interface StorageLogModuleConnection { edges: StorageLogModuleEdge[]; @@ -11386,6 +12438,18 @@ export interface CreateAgentModulePayload { agentModuleEdge?: AgentModuleEdge | null; clientMutationId?: string | null; } +export interface CreateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was created by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export interface CreateAppModulePayload { + /** The `AppModule` that was created by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} export interface CreateBillingModulePayload { /** The `BillingModule` that was created by this mutation. */ billingModule?: BillingModule | null; @@ -11416,6 +12480,12 @@ export interface CreateBlueprintTemplatePayload { blueprintTemplateEdge?: BlueprintTemplateEdge | null; clientMutationId?: string | null; } +export interface CreateCatalogModulePayload { + /** The `CatalogModule` that was created by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} export interface CreateComputeLogModulePayload { clientMutationId?: string | null; /** The `ComputeLogModule` that was created by this mutation. */ @@ -11494,6 +12564,12 @@ export interface CreateDevicesModulePayload { devicesModule?: DevicesModule | null; devicesModuleEdge?: DevicesModuleEdge | null; } +export interface CreateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was created by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} export interface CreateEmailsModulePayload { clientMutationId?: string | null; /** The `EmailsModule` that was created by this mutation. */ @@ -11704,6 +12780,12 @@ export interface CreateRlsModulePayload { rlsModule?: RlsModule | null; rlsModuleEdge?: RlsModuleEdge | null; } +export interface CreateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was created by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} export interface CreateSecureTableProvisionPayload { clientMutationId?: string | null; /** The `SecureTableProvision` that was created by this mutation. */ @@ -11722,6 +12804,12 @@ export interface CreateSessionsModulePayload { sessionsModule?: SessionsModule | null; sessionsModuleEdge?: SessionsModuleEdge | null; } +export interface CreateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was created by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} export interface CreateStorageLogModulePayload { clientMutationId?: string | null; /** The `StorageLogModule` that was created by this mutation. */ @@ -11794,6 +12882,18 @@ export interface DeleteAgentModulePayload { agentModuleEdge?: AgentModuleEdge | null; clientMutationId?: string | null; } +export interface DeleteApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was deleted by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export interface DeleteAppModulePayload { + /** The `AppModule` that was deleted by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} export interface DeleteBillingModulePayload { /** The `BillingModule` that was deleted by this mutation. */ billingModule?: BillingModule | null; @@ -11824,6 +12924,12 @@ export interface DeleteBlueprintTemplatePayload { blueprintTemplateEdge?: BlueprintTemplateEdge | null; clientMutationId?: string | null; } +export interface DeleteCatalogModulePayload { + /** The `CatalogModule` that was deleted by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} export interface DeleteComputeLogModulePayload { clientMutationId?: string | null; /** The `ComputeLogModule` that was deleted by this mutation. */ @@ -11902,6 +13008,12 @@ export interface DeleteDevicesModulePayload { devicesModule?: DevicesModule | null; devicesModuleEdge?: DevicesModuleEdge | null; } +export interface DeleteDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was deleted by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} export interface DeleteEmailsModulePayload { clientMutationId?: string | null; /** The `EmailsModule` that was deleted by this mutation. */ @@ -12112,6 +13224,12 @@ export interface DeleteRlsModulePayload { rlsModule?: RlsModule | null; rlsModuleEdge?: RlsModuleEdge | null; } +export interface DeleteRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was deleted by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} export interface DeleteSecureTableProvisionPayload { clientMutationId?: string | null; /** The `SecureTableProvision` that was deleted by this mutation. */ @@ -12130,6 +13248,12 @@ export interface DeleteSessionsModulePayload { sessionsModule?: SessionsModule | null; sessionsModuleEdge?: SessionsModuleEdge | null; } +export interface DeleteSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was deleted by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} export interface DeleteStorageLogModulePayload { clientMutationId?: string | null; /** The `StorageLogModule` that was deleted by this mutation. */ @@ -12242,6 +13366,18 @@ export interface UpdateAgentModulePayload { agentModuleEdge?: AgentModuleEdge | null; clientMutationId?: string | null; } +export interface UpdateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was updated by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export interface UpdateAppModulePayload { + /** The `AppModule` that was updated by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} export interface UpdateBillingModulePayload { /** The `BillingModule` that was updated by this mutation. */ billingModule?: BillingModule | null; @@ -12272,6 +13408,12 @@ export interface UpdateBlueprintTemplatePayload { blueprintTemplateEdge?: BlueprintTemplateEdge | null; clientMutationId?: string | null; } +export interface UpdateCatalogModulePayload { + /** The `CatalogModule` that was updated by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} export interface UpdateComputeLogModulePayload { clientMutationId?: string | null; /** The `ComputeLogModule` that was updated by this mutation. */ @@ -12350,6 +13492,12 @@ export interface UpdateDevicesModulePayload { devicesModule?: DevicesModule | null; devicesModuleEdge?: DevicesModuleEdge | null; } +export interface UpdateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was updated by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} export interface UpdateEmailsModulePayload { clientMutationId?: string | null; /** The `EmailsModule` that was updated by this mutation. */ @@ -12560,6 +13708,12 @@ export interface UpdateRlsModulePayload { rlsModule?: RlsModule | null; rlsModuleEdge?: RlsModuleEdge | null; } +export interface UpdateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was updated by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} export interface UpdateSecureTableProvisionPayload { clientMutationId?: string | null; /** The `SecureTableProvision` that was updated by this mutation. */ @@ -12578,6 +13732,12 @@ export interface UpdateSessionsModulePayload { sessionsModule?: SessionsModule | null; sessionsModuleEdge?: SessionsModuleEdge | null; } +export interface UpdateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was updated by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} export interface UpdateStorageLogModulePayload { clientMutationId?: string | null; /** The `StorageLogModule` that was updated by this mutation. */ @@ -12660,6 +13820,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -12683,6 +13845,18 @@ export interface PageInfo { /** When paginating backwards, the cursor to continue. */ startCursor?: string | null; } +/** A `ApiSurfaceModule` edge in the connection. */ +export interface ApiSurfaceModuleEdge { + cursor?: string | null; + /** The `ApiSurfaceModule` at the end of the edge. */ + node?: ApiSurfaceModule | null; +} +/** A `AppModule` edge in the connection. */ +export interface AppModuleEdge { + cursor?: string | null; + /** The `AppModule` at the end of the edge. */ + node?: AppModule | null; +} /** A `BillingModule` edge in the connection. */ export interface BillingModuleEdge { cursor?: string | null; @@ -12713,6 +13887,12 @@ export interface BlueprintEdge { /** The `Blueprint` at the end of the edge. */ node?: Blueprint | null; } +/** A `CatalogModule` edge in the connection. */ +export interface CatalogModuleEdge { + cursor?: string | null; + /** The `CatalogModule` at the end of the edge. */ + node?: CatalogModule | null; +} /** A `ComputeLogModule` edge in the connection. */ export interface ComputeLogModuleEdge { cursor?: string | null; @@ -12791,6 +13971,12 @@ export interface DevicesModuleEdge { /** The `DevicesModule` at the end of the edge. */ node?: DevicesModule | null; } +/** A `DomainModule` edge in the connection. */ +export interface DomainModuleEdge { + cursor?: string | null; + /** The `DomainModule` at the end of the edge. */ + node?: DomainModule | null; +} /** A `EmailsModule` edge in the connection. */ export interface EmailsModuleEdge { cursor?: string | null; @@ -13001,6 +14187,12 @@ export interface RlsModuleEdge { /** The `RlsModule` at the end of the edge. */ node?: RlsModule | null; } +/** A `RouteModule` edge in the connection. */ +export interface RouteModuleEdge { + cursor?: string | null; + /** The `RouteModule` at the end of the edge. */ + node?: RouteModule | null; +} /** A `SecureTableProvision` edge in the connection. */ export interface SecureTableProvisionEdge { cursor?: string | null; @@ -13019,6 +14211,12 @@ export interface SessionsModuleEdge { /** The `SessionsModule` at the end of the edge. */ node?: SessionsModule | null; } +/** A `SiteSurfaceModule` edge in the connection. */ +export interface SiteSurfaceModuleEdge { + cursor?: string | null; + /** The `SiteSurfaceModule` at the end of the edge. */ + node?: SiteSurfaceModule | null; +} /** A `StorageLogModule` edge in the connection. */ export interface StorageLogModuleEdge { cursor?: string | null; @@ -13178,6 +14376,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -13210,6 +14421,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -13275,3 +14488,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/modules/types.ts b/sdk/constructive-react/src/modules/types.ts index 7b6c39689..1267b8cd3 100644 --- a/sdk/constructive-react/src/modules/types.ts +++ b/sdk/constructive-react/src/modules/types.ts @@ -41,6 +41,46 @@ export interface AgentModule { threadTableId: string | null; threadTableName: string | null; } +export interface ApiSurfaceModule { + apiName: string | null; + apisTableId: string | null; + apisTableName: string | null; + catalogModuleId: string | null; + databaseId: string | null; + defaultPermissions: string[] | null; + entityField: string | null; + entityTableId: string | null; + id: string | null; + policies: unknown | null; + prefix: string | null; + privateApiName: string | null; + provisions: unknown | null; + publicSchemaName: string | null; + schemaId: string | null; + scope: string | null; +} +export interface AppModule { + apiName: string | null; + appMembersTableId: string | null; + appMembersTableName: string | null; + appsTableId: string | null; + appsTableName: string | null; + catalogModuleId: string | null; + databaseId: string | null; + defaultPermissions: string[] | null; + entityField: string | null; + entityTableId: string | null; + id: string | null; + policies: unknown | null; + prefix: string | null; + privateApiName: string | null; + privateSchemaId: string | null; + privateSchemaName: string | null; + provisions: unknown | null; + publicSchemaName: string | null; + schemaId: string | null; + scope: string | null; +} export interface BillingModule { apiName: string | null; balancesTableId: string | null; @@ -143,6 +183,37 @@ export interface BlueprintTemplate { version: string | null; visibility: string | null; } +export interface CatalogModule { + apiName: string | null; + apisTableId: string | null; + apisTableName: string | null; + appsTableId: string | null; + appsTableName: string | null; + databaseId: string | null; + defaultPermissions: string[] | null; + domainsTableId: string | null; + domainsTableName: string | null; + entityTableId: string | null; + functionsTableId: string | null; + functionsTableName: string | null; + id: string | null; + namespacesTableId: string | null; + namespacesTableName: string | null; + policies: unknown | null; + privateApiName: string | null; + provisions: unknown | null; + publicSchemaName: string | null; + resourceDefinitionsTableId: string | null; + resourceDefinitionsTableName: string | null; + resourceInstallationsTableId: string | null; + resourceInstallationsTableName: string | null; + resourcesTableId: string | null; + resourcesTableName: string | null; + schemaId: string | null; + scope: string | null; + sitesTableId: string | null; + sitesTableName: string | null; +} export interface ComputeLogModule { actorFkTableId: string | null; apiName: string | null; @@ -215,6 +286,7 @@ export interface CryptoAuthModule { usersTableId: string | null; } export interface DatabaseProvisionModule { + async: boolean | null; bootstrapError: string | null; bootstrapStatus: string | null; bootstrapUser: boolean | null; @@ -336,6 +408,28 @@ export interface DevicesModule { userDevicesTableId: string | null; userDevicesTableName: string | null; } +export interface DomainModule { + apiName: string | null; + catalogModuleId: string | null; + databaseId: string | null; + defaultPermissions: string[] | null; + domainEventsTableId: string | null; + domainEventsTableName: string | null; + domainVerificationsTableId: string | null; + domainVerificationsTableName: string | null; + domainsTableId: string | null; + domainsTableName: string | null; + entityField: string | null; + entityTableId: string | null; + id: string | null; + policies: unknown | null; + prefix: string | null; + privateApiName: string | null; + provisions: unknown | null; + publicSchemaName: string | null; + schemaId: string | null; + scope: string | null; +} export interface EmailsModule { apiName: string | null; databaseId: string | null; @@ -459,6 +553,8 @@ export interface FunctionDeploymentModule { } export interface FunctionInvocationModule { apiName: string | null; + attemptsTableId: string | null; + attemptsTableName: string | null; databaseId: string | null; defaultPermissions: string[] | null; entityField: string | null; @@ -1119,6 +1215,32 @@ export interface RlsModule { sessionsTableId: string | null; usersTableId: string | null; } +export interface RouteModule { + apiName: string | null; + catalogModuleId: string | null; + databaseId: string | null; + defaultPermissions: string[] | null; + domainModuleId: string | null; + entityField: string | null; + entityTableId: string | null; + hostnameBindingsTableId: string | null; + hostnameBindingsTableName: string | null; + id: string | null; + policies: unknown | null; + prefix: string | null; + privateApiName: string | null; + privateSchemaId: string | null; + privateSchemaName: string | null; + provisions: unknown | null; + publicSchemaName: string | null; + resolverFunctionName: string | null; + routeBindingsTableId: string | null; + routeBindingsTableName: string | null; + routesTableId: string | null; + routesTableName: string | null; + schemaId: string | null; + scope: string | null; +} export interface SecureTableProvision { databaseId: string | null; fields: unknown[] | null; @@ -1153,6 +1275,24 @@ export interface SessionsModule { sessionsTableName: string | null; usersTableId: string | null; } +export interface SiteSurfaceModule { + apiName: string | null; + catalogModuleId: string | null; + databaseId: string | null; + defaultPermissions: string[] | null; + entityField: string | null; + entityTableId: string | null; + id: string | null; + policies: unknown | null; + prefix: string | null; + privateApiName: string | null; + provisions: unknown | null; + publicSchemaName: string | null; + schemaId: string | null; + scope: string | null; + sitesTableId: string | null; + sitesTableName: string | null; +} export interface StorageLogModule { actorFkTableId: string | null; apiName: string | null; diff --git a/sdk/constructive-react/src/objects/schema-types.ts b/sdk/constructive-react/src/objects/schema-types.ts index ad3100917..8937edba1 100644 --- a/sdk/constructive-react/src/objects/schema-types.ts +++ b/sdk/constructive-react/src/objects/schema-types.ts @@ -570,6 +570,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -700,6 +702,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -732,6 +747,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -797,3 +814,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-react/src/usage/schema-types.ts b/sdk/constructive-react/src/usage/schema-types.ts index fdb5e2ada..98b3c3c9f 100644 --- a/sdk/constructive-react/src/usage/schema-types.ts +++ b/sdk/constructive-react/src/usage/schema-types.ts @@ -2325,6 +2325,8 @@ export interface MetaTable { realtime?: MetaRealtime | null; relations: MetaRelations; schemaName: string; + /** Provisioning scope metadata (null if no @scope tag) */ + scope?: MetaScope | null; /** Search metadata (null if no search configured) */ search?: MetaSearch | null; /** Storage metadata (null if not a storage table) */ @@ -2533,6 +2535,19 @@ export interface MetaRelations { hasOne: MetaHasRelation[]; manyToMany: MetaManyToManyRelation[]; } +/** Provisioning scope metadata for a table */ +export interface MetaScope { + /** SQL name of the entity table for entity scopes, else null */ + entityTable?: string | null; + /** Inflected scope key column (e.g. databaseId, orgId), null for global tiers */ + keyColumn?: string | null; + /** Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') */ + scope: string; + /** Provenance of the scope metadata (always 'smartTag') */ + source: string; + /** Coarse bucket: 'global', 'database', or 'entity' */ + tier: string; +} /** Search metadata for a table */ export interface MetaSearch { /** Active search algorithms on this table */ @@ -2565,6 +2580,8 @@ export interface MetaEnum { } /** Information about a PostgreSQL type */ export interface MetaType { + /** Scalar serialization contract (null for plain scalars) */ + encoding?: MetaScalarEncoding | null; gqlType: string; hasDefault?: boolean | null; isArray: boolean; @@ -2630,3 +2647,18 @@ export interface MetaSearchConfig { /** JSON-encoded per-adapter score weights */ weights?: string | null; } +/** How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. */ +export interface MetaScalarEncoding { + /** For 'vector': declared length, else null. */ + dimensions?: number | null; + /** For 'ltree': values are dot-separated path strings. */ + dotPath?: boolean | null; + /** For 'vector': element scalar (e.g. 'float'). */ + elementType?: string | null; + /** For 'geojson': Point/LineString/Polygon/…, else null. */ + geometrySubtype?: string | null; + /** Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. */ + kind: string; + /** For 'geojson': spatial reference id, else null. */ + srid?: number | null; +} diff --git a/sdk/constructive-sdk/schemas/admin.graphql b/sdk/constructive-sdk/schemas/admin.graphql index b499b7308..8670d77b8 100644 --- a/sdk/constructive-sdk/schemas/admin.graphql +++ b/sdk/constructive-sdk/schemas/admin.graphql @@ -4330,11 +4330,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -4402,6 +4449,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -4412,6 +4462,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! @@ -8631,15 +8683,15 @@ type Query { """Only read the first `n` values of the set.""" first: Int + maxDepth: Int """ Skip the first `n` values from our `after` cursor, an alternative to cursor based pagination. May not be used with `last`. """ offset: Int - pEntityId: UUID - pMaxDepth: Int - pUserId: UUID + targetEntityId: UUID + targetUserId: UUID ): OrgGetManagersConnection """ @@ -8651,15 +8703,15 @@ type Query { """Only read the first `n` values of the set.""" first: Int + maxDepth: Int """ Skip the first `n` values from our `after` cursor, an alternative to cursor based pagination. May not be used with `last`. """ offset: Int - pEntityId: UUID - pMaxDepth: Int - pUserId: UUID + targetEntityId: UUID + targetUserId: UUID ): OrgGetSubordinatesConnection """Reads and enables pagination through a set of `OrgGrant`.""" @@ -8719,7 +8771,7 @@ type Query { """ where: OrgInviteFilter ): OrgInviteConnection - orgIsManagerOf(pEntityId: UUID, pManagerId: UUID, pMaxDepth: Int, pUserId: UUID): Boolean + orgIsManagerOf(managerId: UUID, maxDepth: Int, targetEntityId: UUID, userId: UUID): Boolean """Reads and enables pagination through a set of `OrgMemberProfile`.""" orgMemberProfiles( diff --git a/sdk/constructive-sdk/schemas/agent.graphql b/sdk/constructive-sdk/schemas/agent.graphql index 71f85bd2a..c9d90ff2e 100644 --- a/sdk/constructive-sdk/schemas/agent.graphql +++ b/sdk/constructive-sdk/schemas/agent.graphql @@ -3577,11 +3577,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -3649,6 +3696,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -3659,6 +3709,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! diff --git a/sdk/constructive-sdk/schemas/api.graphql b/sdk/constructive-sdk/schemas/api.graphql index 7775742db..1b43ad8cb 100644 --- a/sdk/constructive-sdk/schemas/api.graphql +++ b/sdk/constructive-sdk/schemas/api.graphql @@ -2924,6 +2924,41 @@ type CreateDefaultPrivilegePayload { query: Query } +"""All input for the create `DomainEvent` mutation.""" +input CreateDomainEventInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """The `DomainEvent` to be created by this mutation.""" + domainEvent: DomainEventInput! +} + +"""The output of our create `DomainEvent` mutation.""" +type CreateDomainEventPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainEvent` that was created by this mutation.""" + domainEvent: DomainEvent + + """An edge for our `DomainEvent`. May be used by Relay 1.""" + domainEventEdge( + """The method to use when ordering `DomainEvent`.""" + orderBy: [DomainEventOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainEventEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the create `Domain` mutation.""" input CreateDomainInput { """ @@ -2959,6 +2994,41 @@ type CreateDomainPayload { query: Query } +"""All input for the create `DomainVerification` mutation.""" +input CreateDomainVerificationInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """The `DomainVerification` to be created by this mutation.""" + domainVerification: DomainVerificationInput! +} + +"""The output of our create `DomainVerification` mutation.""" +type CreateDomainVerificationPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainVerification` that was created by this mutation.""" + domainVerification: DomainVerification + + """An edge for our `DomainVerification`. May be used by Relay 1.""" + domainVerificationEdge( + """The method to use when ordering `DomainVerification`.""" + orderBy: [DomainVerificationOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainVerificationEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the create `EmbeddingChunk` mutation.""" input CreateEmbeddingChunkInput { """ @@ -5583,6 +5653,11 @@ input DatabasePatch { Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. """ type DatabaseProvisionModule { + """ + When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger + """ + async: Boolean! + """Error message from the most recent failed bootstrap attempt""" bootstrapError: String @@ -7278,6 +7353,41 @@ type DeleteDefaultPrivilegePayload { query: Query } +"""All input for the `deleteDomainEvent` mutation.""" +input DeleteDomainEventInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """Unique event identifier""" + id: UUID! +} + +"""The output of our delete `DomainEvent` mutation.""" +type DeleteDomainEventPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainEvent` that was deleted by this mutation.""" + domainEvent: DomainEvent + + """An edge for our `DomainEvent`. May be used by Relay 1.""" + domainEventEdge( + """The method to use when ordering `DomainEvent`.""" + orderBy: [DomainEventOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainEventEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `deleteDomain` mutation.""" input DeleteDomainInput { """ @@ -7313,6 +7423,41 @@ type DeleteDomainPayload { query: Query } +"""All input for the `deleteDomainVerification` mutation.""" +input DeleteDomainVerificationInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """Unique identifier for this verification challenge""" + id: UUID! +} + +"""The output of our delete `DomainVerification` mutation.""" +type DeleteDomainVerificationPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainVerification` that was deleted by this mutation.""" + domainVerification: DomainVerification + + """An edge for our `DomainVerification`. May be used by Relay 1.""" + domainVerificationEdge( + """The method to use when ordering `DomainVerification`.""" + orderBy: [DomainVerificationOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainVerificationEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `deleteEmbeddingChunk` mutation.""" input DeleteEmbeddingChunkInput { """ @@ -8485,6 +8630,227 @@ type DomainEdge { node: Domain } +""" +Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. +""" +type DomainEvent { + """User who triggered this event (NULL for system/automated transitions)""" + actorId: UUID + + """Event timestamp""" + createdAt: Datetime! + + """ + Reads a single `DomainVerification` that is related to this `DomainEvent`. + """ + domainVerification: DomainVerification + + """The verification challenge this event relates to, when applicable""" + domainVerificationId: UUID + + """ + Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked + """ + eventType: String! + + """Unique event identifier""" + id: UUID! + + """Reads a single `ManagedDomain` that is related to this `DomainEvent`.""" + managedDomain: ManagedDomain + + """The managed_domain this event belongs to""" + managedDomainId: UUID! + + """Human-readable description of the event""" + message: String + + """ + Structured context (challenge record, cert-manager detail, error details, ...) + """ + metadata: JSON! + + """ + Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS + """ + ownerId: UUID! +} + +"""A connection to a list of `DomainEvent` values.""" +type DomainEventConnection { + """ + A list of edges which contains the `DomainEvent` and cursor to aid in pagination. + """ + edges: [DomainEventEdge]! + + """A list of `DomainEvent` objects.""" + nodes: [DomainEvent]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """The count of *all* `DomainEvent` you could get from the connection.""" + totalCount: Int! +} + +"""A `DomainEvent` edge in the connection.""" +type DomainEventEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `DomainEvent` at the end of the edge.""" + node: DomainEvent +} + +""" +A filter to be used against `DomainEvent` object types. All fields are combined with a logical ‘and.’ +""" +input DomainEventFilter { + """Filter by the object’s `actorId` field.""" + actorId: UUIDFilter + + """Checks for all expressions in this list.""" + and: [DomainEventFilter!] + + """Filter by the object’s `createdAt` field.""" + createdAt: DatetimeFilter + + """Filter by the object’s `domainVerification` relation.""" + domainVerification: DomainVerificationFilter + + """A related `domainVerification` exists.""" + domainVerificationExists: Boolean + + """Filter by the object’s `domainVerificationId` field.""" + domainVerificationId: UUIDFilter + + """Filter by the object’s `eventType` field.""" + eventType: StringFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Filter by the object’s `managedDomain` relation.""" + managedDomain: ManagedDomainFilter + + """Filter by the object’s `managedDomainId` field.""" + managedDomainId: UUIDFilter + + """Filter by the object’s `message` field.""" + message: StringFilter + + """Filter by the object’s `metadata` field.""" + metadata: JSONFilter + + """Negates the expression.""" + not: DomainEventFilter + + """Checks for any expressions in this list.""" + or: [DomainEventFilter!] + + """Filter by the object’s `ownerId` field.""" + ownerId: UUIDFilter +} + +"""An input for mutations affecting `DomainEvent`""" +input DomainEventInput { + """User who triggered this event (NULL for system/automated transitions)""" + actorId: UUID + + """Event timestamp""" + createdAt: Datetime + + """The verification challenge this event relates to, when applicable""" + domainVerificationId: UUID + + """ + Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked + """ + eventType: String! + + """Unique event identifier""" + id: UUID + + """The managed_domain this event belongs to""" + managedDomainId: UUID! + + """Human-readable description of the event""" + message: String + + """ + Structured context (challenge record, cert-manager detail, error details, ...) + """ + metadata: JSON + + """ + Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS + """ + ownerId: UUID! +} + +"""Methods to use when ordering `DomainEvent`.""" +enum DomainEventOrderBy { + ACTOR_ID_ASC + ACTOR_ID_DESC + CREATED_AT_ASC + CREATED_AT_DESC + DOMAIN_VERIFICATION_ID_ASC + DOMAIN_VERIFICATION_ID_DESC + EVENT_TYPE_ASC + EVENT_TYPE_DESC + ID_ASC + ID_DESC + MANAGED_DOMAIN_ID_ASC + MANAGED_DOMAIN_ID_DESC + MESSAGE_ASC + MESSAGE_DESC + METADATA_ASC + METADATA_DESC + NATURAL + OWNER_ID_ASC + OWNER_ID_DESC + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC +} + +""" +Represents an update to a `DomainEvent`. Fields that are set will be updated. +""" +input DomainEventPatch { + """User who triggered this event (NULL for system/automated transitions)""" + actorId: UUID + + """Event timestamp""" + createdAt: Datetime + + """The verification challenge this event relates to, when applicable""" + domainVerificationId: UUID + + """ + Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked + """ + eventType: String + + """Unique event identifier""" + id: UUID + + """The managed_domain this event belongs to""" + managedDomainId: UUID + + """Human-readable description of the event""" + message: String + + """ + Structured context (challenge record, cert-manager detail, error details, ...) + """ + metadata: JSON + + """ + Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS + """ + ownerId: UUID +} + """ A filter to be used against `Domain` object types. All fields are combined with a logical ‘and.’ """ @@ -8638,22 +9004,381 @@ input DomainPatch { """ siteId: UUID - """Subdomain portion of the hostname""" - subdomain: ConstructiveInternalTypeHostname + """Subdomain portion of the hostname""" + subdomain: ConstructiveInternalTypeHostname +} + +""" +A filter to be used against many `HttpRoute` object types. All fields are combined with a logical ‘and.’ +""" +input DomainToManyHttpRouteFilter { + """Filters to entities where every related entity matches.""" + every: HttpRouteFilter + + """Filters to entities where no related entity matches.""" + none: HttpRouteFilter + + """Filters to entities where at least one related entity matches.""" + some: HttpRouteFilter +} + +""" +One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. +""" +type DomainVerification { + """ + Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) + """ + attempts: Int! + + """When this challenge was minted (domain:issue_challenge)""" + createdAt: Datetime! + + """Reads and enables pagination through a set of `DomainEvent`.""" + domainEvents( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `DomainEvent`.""" + orderBy: [DomainEventOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: DomainEventFilter + ): DomainEventConnection! + + """Last verification error (mismatch, NXDOMAIN, timeout, ...)""" + error: String + + """When this challenge expires and must be reissued""" + expiresAt: Datetime + + """Unique identifier for this verification challenge""" + id: UUID! + + """When domain:verify last polled DNS/HTTP for this challenge""" + lastCheckedAt: Datetime + + """ + Reads a single `ManagedDomain` that is related to this `DomainVerification`. + """ + managedDomain: ManagedDomain + + """The managed_domain this challenge proves ownership of""" + managedDomainId: UUID! + + """ + Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) + """ + method: String! + + """ + Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. + """ + ownerId: UUID! + + """ + DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 + """ + recordName: String + + """DNS record type to create: TXT | CNAME | A; NULL for http_01""" + recordType: String + + """ + The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. + """ + recordValue: String + + """Challenge lifecycle: pending | checking | verified | failed | expired""" + status: String! + + """When this row was last updated""" + updatedAt: Datetime! + + """When status last became verified""" + verifiedAt: Datetime +} + +"""A connection to a list of `DomainVerification` values.""" +type DomainVerificationConnection { + """ + A list of edges which contains the `DomainVerification` and cursor to aid in pagination. + """ + edges: [DomainVerificationEdge]! + + """A list of `DomainVerification` objects.""" + nodes: [DomainVerification]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `DomainVerification` you could get from the connection. + """ + totalCount: Int! +} + +"""A `DomainVerification` edge in the connection.""" +type DomainVerificationEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `DomainVerification` at the end of the edge.""" + node: DomainVerification +} + +""" +A filter to be used against `DomainVerification` object types. All fields are combined with a logical ‘and.’ +""" +input DomainVerificationFilter { + """Checks for all expressions in this list.""" + and: [DomainVerificationFilter!] + + """Filter by the object’s `attempts` field.""" + attempts: IntFilter + + """Filter by the object’s `createdAt` field.""" + createdAt: DatetimeFilter + + """Filter by the object’s `domainEvents` relation.""" + domainEvents: DomainVerificationToManyDomainEventFilter + + """`domainEvents` exist.""" + domainEventsExist: Boolean + + """Filter by the object’s `error` field.""" + error: StringFilter + + """Filter by the object’s `expiresAt` field.""" + expiresAt: DatetimeFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Filter by the object’s `lastCheckedAt` field.""" + lastCheckedAt: DatetimeFilter + + """Filter by the object’s `managedDomain` relation.""" + managedDomain: ManagedDomainFilter + + """Filter by the object’s `managedDomainId` field.""" + managedDomainId: UUIDFilter + + """Filter by the object’s `method` field.""" + method: StringFilter + + """Negates the expression.""" + not: DomainVerificationFilter + + """Checks for any expressions in this list.""" + or: [DomainVerificationFilter!] + + """Filter by the object’s `ownerId` field.""" + ownerId: UUIDFilter + + """Filter by the object’s `recordName` field.""" + recordName: StringFilter + + """Filter by the object’s `recordType` field.""" + recordType: StringFilter + + """Filter by the object’s `recordValue` field.""" + recordValue: StringFilter + + """Filter by the object’s `status` field.""" + status: StringFilter + + """Filter by the object’s `updatedAt` field.""" + updatedAt: DatetimeFilter + + """Filter by the object’s `verifiedAt` field.""" + verifiedAt: DatetimeFilter +} + +"""An input for mutations affecting `DomainVerification`""" +input DomainVerificationInput { + """ + Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) + """ + attempts: Int + + """When this challenge was minted (domain:issue_challenge)""" + createdAt: Datetime + + """Last verification error (mismatch, NXDOMAIN, timeout, ...)""" + error: String + + """When this challenge expires and must be reissued""" + expiresAt: Datetime + + """Unique identifier for this verification challenge""" + id: UUID + + """When domain:verify last polled DNS/HTTP for this challenge""" + lastCheckedAt: Datetime + + """The managed_domain this challenge proves ownership of""" + managedDomainId: UUID! + + """ + Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) + """ + method: String + + """ + Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. + """ + ownerId: UUID! + + """ + DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 + """ + recordName: String + + """DNS record type to create: TXT | CNAME | A; NULL for http_01""" + recordType: String + + """ + The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. + """ + recordValue: String + + """Challenge lifecycle: pending | checking | verified | failed | expired""" + status: String + + """When this row was last updated""" + updatedAt: Datetime + + """When status last became verified""" + verifiedAt: Datetime +} + +"""Methods to use when ordering `DomainVerification`.""" +enum DomainVerificationOrderBy { + ATTEMPTS_ASC + ATTEMPTS_DESC + CREATED_AT_ASC + CREATED_AT_DESC + ERROR_ASC + ERROR_DESC + EXPIRES_AT_ASC + EXPIRES_AT_DESC + ID_ASC + ID_DESC + LAST_CHECKED_AT_ASC + LAST_CHECKED_AT_DESC + MANAGED_DOMAIN_ID_ASC + MANAGED_DOMAIN_ID_DESC + METHOD_ASC + METHOD_DESC + NATURAL + OWNER_ID_ASC + OWNER_ID_DESC + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + RECORD_NAME_ASC + RECORD_NAME_DESC + RECORD_TYPE_ASC + RECORD_TYPE_DESC + RECORD_VALUE_ASC + RECORD_VALUE_DESC + STATUS_ASC + STATUS_DESC + UPDATED_AT_ASC + UPDATED_AT_DESC + VERIFIED_AT_ASC + VERIFIED_AT_DESC +} + +""" +Represents an update to a `DomainVerification`. Fields that are set will be updated. +""" +input DomainVerificationPatch { + """ + Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) + """ + attempts: Int + + """When this challenge was minted (domain:issue_challenge)""" + createdAt: Datetime + + """Last verification error (mismatch, NXDOMAIN, timeout, ...)""" + error: String + + """When this challenge expires and must be reissued""" + expiresAt: Datetime + + """Unique identifier for this verification challenge""" + id: UUID + + """When domain:verify last polled DNS/HTTP for this challenge""" + lastCheckedAt: Datetime + + """The managed_domain this challenge proves ownership of""" + managedDomainId: UUID + + """ + Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) + """ + method: String + + """ + Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. + """ + ownerId: UUID + + """ + DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 + """ + recordName: String + + """DNS record type to create: TXT | CNAME | A; NULL for http_01""" + recordType: String + + """ + The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. + """ + recordValue: String + + """Challenge lifecycle: pending | checking | verified | failed | expired""" + status: String + + """When this row was last updated""" + updatedAt: Datetime + + """When status last became verified""" + verifiedAt: Datetime } """ -A filter to be used against many `HttpRoute` object types. All fields are combined with a logical ‘and.’ +A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ """ -input DomainToManyHttpRouteFilter { +input DomainVerificationToManyDomainEventFilter { """Filters to entities where every related entity matches.""" - every: HttpRouteFilter + every: DomainEventFilter """Filters to entities where no related entity matches.""" - none: HttpRouteFilter + none: DomainEventFilter """Filters to entities where at least one related entity matches.""" - some: HttpRouteFilter + some: DomainEventFilter } type EmbeddingChunk { @@ -10463,11 +11188,21 @@ input JSONFilter { One row per cert-bearing host or wildcard; tracks domain verification and TLS provisioning independently of services_public.domains. Reconcilers match a route's root domain to a row here by string (no FK/coupling in v1) """ type ManagedDomain { + """ + Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. + """ + allowPublicUsage: Boolean! + """ Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata """ annotations: JSON! + """ + cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error + """ + certStatus: String! + """Reads a single `Database` that is related to this `ManagedDomain`.""" database: Database @@ -10481,6 +11216,64 @@ type ManagedDomain { """ domain: ConstructiveInternalTypeHostname! + """Reads and enables pagination through a set of `DomainEvent`.""" + domainEvents( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `DomainEvent`.""" + orderBy: [DomainEventOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: DomainEventFilter + ): DomainEventConnection! + + """Reads and enables pagination through a set of `DomainVerification`.""" + domainVerifications( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `DomainVerification`.""" + orderBy: [DomainVerificationOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: DomainVerificationFilter + ): DomainVerificationConnection! + """Unique identifier for this managed domain record""" id: UUID! @@ -10492,10 +11285,14 @@ type ManagedDomain { """When tls_status last became active""" tlsReadyAt: Datetime - """TLS/SSL provisioning state: none | provisioning | active | failed""" + """ + TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed + """ tlsStatus: String! - """Domain ownership verification state: pending | verified | failed""" + """ + Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired + """ verificationStatus: String! """When verification_status last became verified""" @@ -10532,12 +11329,18 @@ type ManagedDomainEdge { A filter to be used against `ManagedDomain` object types. All fields are combined with a logical ‘and.’ """ input ManagedDomainFilter { + """Filter by the object’s `allowPublicUsage` field.""" + allowPublicUsage: BooleanFilter + """Checks for all expressions in this list.""" and: [ManagedDomainFilter!] """Filter by the object’s `annotations` field.""" annotations: JSONFilter + """Filter by the object’s `certStatus` field.""" + certStatus: StringFilter + """Filter by the object’s `database` relation.""" database: DatabaseFilter @@ -10547,6 +11350,18 @@ input ManagedDomainFilter { """Filter by the object’s `domain` field.""" domain: ConstructiveInternalTypeHostnameFilter + """Filter by the object’s `domainEvents` relation.""" + domainEvents: ManagedDomainToManyDomainEventFilter + + """`domainEvents` exist.""" + domainEventsExist: Boolean + + """Filter by the object’s `domainVerifications` relation.""" + domainVerifications: ManagedDomainToManyDomainVerificationFilter + + """`domainVerifications` exist.""" + domainVerificationsExist: Boolean + """Filter by the object’s `id` field.""" id: UUIDFilter @@ -10574,11 +11389,21 @@ input ManagedDomainFilter { """An input for mutations affecting `ManagedDomain`""" input ManagedDomainInput { + """ + Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. + """ + allowPublicUsage: Boolean + """ Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata """ annotations: JSON + """ + cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error + """ + certStatus: String + """ Database that owns this cert-bearing host; platform wildcards are owned by the platform database """ @@ -10600,10 +11425,14 @@ input ManagedDomainInput { """When tls_status last became active""" tlsReadyAt: Datetime - """TLS/SSL provisioning state: none | provisioning | active | failed""" + """ + TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed + """ tlsStatus: String - """Domain ownership verification state: pending | verified | failed""" + """ + Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired + """ verificationStatus: String """When verification_status last became verified""" @@ -10612,8 +11441,12 @@ input ManagedDomainInput { """Methods to use when ordering `ManagedDomain`.""" enum ManagedDomainOrderBy { + ALLOW_PUBLIC_USAGE_ASC + ALLOW_PUBLIC_USAGE_DESC ANNOTATIONS_ASC ANNOTATIONS_DESC + CERT_STATUS_ASC + CERT_STATUS_DESC DATABASE_ID_ASC DATABASE_ID_DESC DOMAIN_ASC @@ -10639,11 +11472,21 @@ enum ManagedDomainOrderBy { Represents an update to a `ManagedDomain`. Fields that are set will be updated. """ input ManagedDomainPatch { + """ + Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. + """ + allowPublicUsage: Boolean + """ Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata """ annotations: JSON + """ + cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error + """ + certStatus: String + """ Database that owns this cert-bearing host; platform wildcards are owned by the platform database """ @@ -10665,16 +11508,48 @@ input ManagedDomainPatch { """When tls_status last became active""" tlsReadyAt: Datetime - """TLS/SSL provisioning state: none | provisioning | active | failed""" + """ + TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed + """ tlsStatus: String - """Domain ownership verification state: pending | verified | failed""" + """ + Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired + """ verificationStatus: String """When verification_status last became verified""" verifiedAt: Datetime } +""" +A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ +""" +input ManagedDomainToManyDomainEventFilter { + """Filters to entities where every related entity matches.""" + every: DomainEventFilter + + """Filters to entities where no related entity matches.""" + none: DomainEventFilter + + """Filters to entities where at least one related entity matches.""" + some: DomainEventFilter +} + +""" +A filter to be used against many `DomainVerification` object types. All fields are combined with a logical ‘and.’ +""" +input ManagedDomainToManyDomainVerificationFilter { + """Filters to entities where every related entity matches.""" + every: DomainVerificationFilter + + """Filters to entities where no related entity matches.""" + none: DomainVerificationFilter + + """Filters to entities where at least one related entity matches.""" + some: DomainVerificationFilter +} + """A belongs-to (forward FK) relation""" type MetaBelongsToRelation { fieldName: String @@ -10825,11 +11700,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -10897,6 +11819,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -10907,6 +11832,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! @@ -11048,6 +11975,22 @@ type Mutation { input: CreateDomainInput! ): CreateDomainPayload + """Creates a single `DomainEvent`.""" + createDomainEvent( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateDomainEventInput! + ): CreateDomainEventPayload + + """Creates a single `DomainVerification`.""" + createDomainVerification( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateDomainVerificationInput! + ): CreateDomainVerificationPayload + """Creates a single `EmbeddingChunk`.""" createEmbeddingChunk( """ @@ -11408,6 +12351,22 @@ type Mutation { input: DeleteDomainInput! ): DeleteDomainPayload + """Deletes a single `DomainEvent` using a unique key.""" + deleteDomainEvent( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteDomainEventInput! + ): DeleteDomainEventPayload + + """Deletes a single `DomainVerification` using a unique key.""" + deleteDomainVerification( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteDomainVerificationInput! + ): DeleteDomainVerificationPayload + """Deletes a single `EmbeddingChunk` using a unique key.""" deleteEmbeddingChunk( """ @@ -11686,7 +12645,7 @@ type Mutation { """ Requests a database and returns a ticket (database_provision_module row) to poll. - Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. + Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); @@ -11809,6 +12768,22 @@ type Mutation { input: UpdateDomainInput! ): UpdateDomainPayload + """Updates a single `DomainEvent` using a unique key and a patch.""" + updateDomainEvent( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateDomainEventInput! + ): UpdateDomainEventPayload + + """Updates a single `DomainVerification` using a unique key and a patch.""" + updateDomainVerification( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateDomainVerificationInput! + ): UpdateDomainVerificationPayload + """Updates a single `EmbeddingChunk` using a unique key and a patch.""" updateEmbeddingChunk( """ @@ -13495,6 +14470,64 @@ type Query { where: DefaultPrivilegeFilter ): DefaultPrivilegeConnection + """Reads and enables pagination through a set of `DomainEvent`.""" + domainEvents( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `DomainEvent`.""" + orderBy: [DomainEventOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: DomainEventFilter + ): DomainEventConnection + + """Reads and enables pagination through a set of `DomainVerification`.""" + domainVerifications( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `DomainVerification`.""" + orderBy: [DomainVerificationOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: DomainVerificationFilter + ): DomainVerificationConnection + """Reads and enables pagination through a set of `Domain`.""" domains( """Read all values in the set after (below) this cursor.""" @@ -13929,7 +14962,7 @@ type Query { """ where: PubkeySettingFilter ): PubkeySettingConnection - resolveHttpRoute(pHost: String, pMethod: String, pPath: String): ResolveHttpRouteRecord + resolveHttpRoute(requestHost: String, requestMethod: String, requestPath: String): ResolveHttpRouteRecord """Reads and enables pagination through a set of `RlsSetting`.""" rlsSettings( @@ -19165,6 +20198,46 @@ type UpdateDefaultPrivilegePayload { query: Query } +"""All input for the `updateDomainEvent` mutation.""" +input UpdateDomainEventInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """ + An object where the defined keys will be set on the `DomainEvent` being updated. + """ + domainEventPatch: DomainEventPatch! + + """Unique event identifier""" + id: UUID! +} + +"""The output of our update `DomainEvent` mutation.""" +type UpdateDomainEventPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainEvent` that was updated by this mutation.""" + domainEvent: DomainEvent + + """An edge for our `DomainEvent`. May be used by Relay 1.""" + domainEventEdge( + """The method to use when ordering `DomainEvent`.""" + orderBy: [DomainEventOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainEventEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `updateDomain` mutation.""" input UpdateDomainInput { """ @@ -19205,6 +20278,46 @@ type UpdateDomainPayload { query: Query } +"""All input for the `updateDomainVerification` mutation.""" +input UpdateDomainVerificationInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """ + An object where the defined keys will be set on the `DomainVerification` being updated. + """ + domainVerificationPatch: DomainVerificationPatch! + + """Unique identifier for this verification challenge""" + id: UUID! +} + +"""The output of our update `DomainVerification` mutation.""" +type UpdateDomainVerificationPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainVerification` that was updated by this mutation.""" + domainVerification: DomainVerification + + """An edge for our `DomainVerification`. May be used by Relay 1.""" + domainVerificationEdge( + """The method to use when ordering `DomainVerification`.""" + orderBy: [DomainVerificationOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainVerificationEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `updateEmbeddingChunk` mutation.""" input UpdateEmbeddingChunkInput { """ diff --git a/sdk/constructive-sdk/schemas/auth.graphql b/sdk/constructive-sdk/schemas/auth.graphql index 9a869f0e1..f5097a207 100644 --- a/sdk/constructive-sdk/schemas/auth.graphql +++ b/sdk/constructive-sdk/schemas/auth.graphql @@ -2398,11 +2398,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -2470,6 +2517,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -2480,6 +2530,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! diff --git a/sdk/constructive-sdk/schemas/compute.graphql b/sdk/constructive-sdk/schemas/compute.graphql index 591aec602..02b31ab23 100644 --- a/sdk/constructive-sdk/schemas/compute.graphql +++ b/sdk/constructive-sdk/schemas/compute.graphql @@ -870,6 +870,41 @@ type CreateFunctionGraphStorePayload { query: Query } +"""All input for the create `FunctionInvocationAttempt` mutation.""" +input CreateFunctionInvocationAttemptInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """The `FunctionInvocationAttempt` to be created by this mutation.""" + functionInvocationAttempt: FunctionInvocationAttemptInput! +} + +"""The output of our create `FunctionInvocationAttempt` mutation.""" +type CreateFunctionInvocationAttemptPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `FunctionInvocationAttempt` that was created by this mutation.""" + functionInvocationAttempt: FunctionInvocationAttempt + + """An edge for our `FunctionInvocationAttempt`. May be used by Relay 1.""" + functionInvocationAttemptEdge( + """The method to use when ordering `FunctionInvocationAttempt`.""" + orderBy: [FunctionInvocationAttemptOrderBy!]! = [PRIMARY_KEY_ASC] + ): FunctionInvocationAttemptEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the create `FunctionInvocation` mutation.""" input CreateFunctionInvocationInput { """ @@ -1331,6 +1366,47 @@ type CreatePlatformFunctionExecutionLogPayload { query: Query } +"""All input for the create `PlatformFunctionInvocationAttempt` mutation.""" +input CreatePlatformFunctionInvocationAttemptInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """ + The `PlatformFunctionInvocationAttempt` to be created by this mutation. + """ + platformFunctionInvocationAttempt: PlatformFunctionInvocationAttemptInput! +} + +"""The output of our create `PlatformFunctionInvocationAttempt` mutation.""" +type CreatePlatformFunctionInvocationAttemptPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + The `PlatformFunctionInvocationAttempt` that was created by this mutation. + """ + platformFunctionInvocationAttempt: PlatformFunctionInvocationAttempt + + """ + An edge for our `PlatformFunctionInvocationAttempt`. May be used by Relay 1. + """ + platformFunctionInvocationAttemptEdge( + """The method to use when ordering `PlatformFunctionInvocationAttempt`.""" + orderBy: [PlatformFunctionInvocationAttemptOrderBy!]! = [PRIMARY_KEY_ASC] + ): PlatformFunctionInvocationAttemptEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the create `PlatformFunctionInvocation` mutation.""" input CreatePlatformFunctionInvocationInput { """ @@ -2553,134 +2629,6 @@ input DbPresetPatch { updatedAt: Datetime } -type DeclaredCapacity { - cpuLimitMillicores: BigInt - cpuRequestMillicores: BigInt - installationId: UUID - isTransient: Boolean - kind: String - memoryLimitBytes: BigInt - memoryRequestBytes: BigInt - namespaceId: UUID - podCountMax: Int - podCountMin: Int - source: String - sourceId: UUID - storageSizeBytes: BigInt -} - -"""A connection to a list of `DeclaredCapacity` values.""" -type DeclaredCapacityConnection { - """ - A list of edges which contains the `DeclaredCapacity` and cursor to aid in pagination. - """ - edges: [DeclaredCapacityEdge]! - - """A list of `DeclaredCapacity` objects.""" - nodes: [DeclaredCapacity]! - - """Information to aid in pagination.""" - pageInfo: PageInfo! - - """ - The count of *all* `DeclaredCapacity` you could get from the connection. - """ - totalCount: Int! -} - -"""A `DeclaredCapacity` edge in the connection.""" -type DeclaredCapacityEdge { - """A cursor for use in pagination.""" - cursor: Cursor - - """The `DeclaredCapacity` at the end of the edge.""" - node: DeclaredCapacity -} - -""" -A filter to be used against `DeclaredCapacity` object types. All fields are combined with a logical ‘and.’ -""" -input DeclaredCapacityFilter { - """Checks for all expressions in this list.""" - and: [DeclaredCapacityFilter!] - - """Filter by the object’s `cpuLimitMillicores` field.""" - cpuLimitMillicores: BigIntFilter - - """Filter by the object’s `cpuRequestMillicores` field.""" - cpuRequestMillicores: BigIntFilter - - """Filter by the object’s `installationId` field.""" - installationId: UUIDFilter - - """Filter by the object’s `isTransient` field.""" - isTransient: BooleanFilter - - """Filter by the object’s `kind` field.""" - kind: StringFilter - - """Filter by the object’s `memoryLimitBytes` field.""" - memoryLimitBytes: BigIntFilter - - """Filter by the object’s `memoryRequestBytes` field.""" - memoryRequestBytes: BigIntFilter - - """Filter by the object’s `namespaceId` field.""" - namespaceId: UUIDFilter - - """Negates the expression.""" - not: DeclaredCapacityFilter - - """Checks for any expressions in this list.""" - or: [DeclaredCapacityFilter!] - - """Filter by the object’s `podCountMax` field.""" - podCountMax: IntFilter - - """Filter by the object’s `podCountMin` field.""" - podCountMin: IntFilter - - """Filter by the object’s `source` field.""" - source: StringFilter - - """Filter by the object’s `sourceId` field.""" - sourceId: UUIDFilter - - """Filter by the object’s `storageSizeBytes` field.""" - storageSizeBytes: BigIntFilter -} - -"""Methods to use when ordering `DeclaredCapacity`.""" -enum DeclaredCapacityOrderBy { - CPU_LIMIT_MILLICORES_ASC - CPU_LIMIT_MILLICORES_DESC - CPU_REQUEST_MILLICORES_ASC - CPU_REQUEST_MILLICORES_DESC - INSTALLATION_ID_ASC - INSTALLATION_ID_DESC - IS_TRANSIENT_ASC - IS_TRANSIENT_DESC - KIND_ASC - KIND_DESC - MEMORY_LIMIT_BYTES_ASC - MEMORY_LIMIT_BYTES_DESC - MEMORY_REQUEST_BYTES_ASC - MEMORY_REQUEST_BYTES_DESC - NAMESPACE_ID_ASC - NAMESPACE_ID_DESC - NATURAL - POD_COUNT_MAX_ASC - POD_COUNT_MAX_DESC - POD_COUNT_MIN_ASC - POD_COUNT_MIN_DESC - SOURCE_ASC - SOURCE_DESC - SOURCE_ID_ASC - SOURCE_ID_DESC - STORAGE_SIZE_BYTES_ASC - STORAGE_SIZE_BYTES_DESC -} - """All input for the `deleteDbPreset` mutation.""" input DeleteDbPresetInput { """ @@ -3195,6 +3143,44 @@ type DeleteFunctionGraphStorePayload { query: Query } +"""All input for the `deleteFunctionInvocationAttempt` mutation.""" +input DeleteFunctionInvocationAttemptInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime! + + """Unique attempt identifier""" + id: UUID! +} + +"""The output of our delete `FunctionInvocationAttempt` mutation.""" +type DeleteFunctionInvocationAttemptPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `FunctionInvocationAttempt` that was deleted by this mutation.""" + functionInvocationAttempt: FunctionInvocationAttempt + + """An edge for our `FunctionInvocationAttempt`. May be used by Relay 1.""" + functionInvocationAttemptEdge( + """The method to use when ordering `FunctionInvocationAttempt`.""" + orderBy: [FunctionInvocationAttemptOrderBy!]! = [PRIMARY_KEY_ASC] + ): FunctionInvocationAttemptEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `deleteFunctionInvocation` mutation.""" input DeleteFunctionInvocationInput { """ @@ -3667,6 +3653,48 @@ type DeletePlatformFunctionExecutionLogPayload { query: Query } +"""All input for the `deletePlatformFunctionInvocationAttempt` mutation.""" +input DeletePlatformFunctionInvocationAttemptInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime! + + """Unique attempt identifier""" + id: UUID! +} + +"""The output of our delete `PlatformFunctionInvocationAttempt` mutation.""" +type DeletePlatformFunctionInvocationAttemptPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + The `PlatformFunctionInvocationAttempt` that was deleted by this mutation. + """ + platformFunctionInvocationAttempt: PlatformFunctionInvocationAttempt + + """ + An edge for our `PlatformFunctionInvocationAttempt`. May be used by Relay 1. + """ + platformFunctionInvocationAttemptEdge( + """The method to use when ordering `PlatformFunctionInvocationAttempt`.""" + orderBy: [PlatformFunctionInvocationAttemptOrderBy!]! = [PRIMARY_KEY_ASC] + ): PlatformFunctionInvocationAttemptEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `deletePlatformFunctionInvocation` mutation.""" input DeletePlatformFunctionInvocationInput { """ @@ -4941,9 +4969,9 @@ type FunctionDefinition { targetSchema: String """ - Computed routing slug: category:name (used by Knative job worker for dispatch) + Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) """ - taskIdentifier: String! + taskIdentifier: String """Knative request timeout in seconds""" timeoutSeconds: Int! @@ -5310,11 +5338,6 @@ input FunctionDefinitionInput { """ targetSchema: String - """ - Computed routing slug: category:name (used by Knative job worker for dispatch) - """ - taskIdentifier: String! - """Knative request timeout in seconds""" timeoutSeconds: Int updatedAt: Datetime @@ -5569,11 +5592,6 @@ input FunctionDefinitionPatch { """ targetSchema: String - """ - Computed routing slug: category:name (used by Knative job worker for dispatch) - """ - taskIdentifier: String - """Knative request timeout in seconds""" timeoutSeconds: Int updatedAt: Datetime @@ -8290,7 +8308,9 @@ type FunctionInvocation { """Wall-clock execution time in milliseconds""" durationMs: Int - """Error message when status is failed""" + """ + Error message when status is failed, or the reason the run was skipped when status is skipped + """ error: String """ @@ -8324,7 +8344,9 @@ type FunctionInvocation { """When execution started""" startedAt: Datetime - """Lifecycle: pending → running → completed/failed/cancelled""" + """ + Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) + """ status: String! """ @@ -8333,24 +8355,280 @@ type FunctionInvocation { taskIdentifier: String! } -"""A connection to a list of `FunctionInvocation` values.""" -type FunctionInvocationConnection { - """ - A list of edges which contains the `FunctionInvocation` and cursor to aid in pagination. - """ - edges: [FunctionInvocationEdge]! +""" +Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail +""" +type FunctionInvocationAttempt { + """Who triggered the invocation (NULL for system/cron)""" + actorId: UUID - """A list of `FunctionInvocation` objects.""" - nodes: [FunctionInvocation]! + """1-based attempt number for this invocation""" + attempt: Int! - """Information to aid in pagination.""" - pageInfo: PageInfo! + """When the attempt result was recorded (partition key)""" + createdAt: Datetime! + + """Database that owns this resource (database-scoped isolation)""" + databaseId: UUID! + + """Wall-clock attempt time in milliseconds""" + durationMs: Int + + """Error message when the attempt failed""" + error: String + + """Structured error context (stack, code, provider response)""" + errorDetail: JSON + + """Unique attempt identifier""" + id: UUID! """ - The count of *all* `FunctionInvocation` you could get from the connection. + created_at of the referenced invocation (partition-pruned lookups against the invocations PK) """ - totalCount: Int! -} + invocationCreatedAt: Datetime! + + """ + Invocation this attempt belongs to (soft reference paired with invocation_created_at) + """ + invocationId: UUID! + + """When the attempt began executing""" + startedAt: Datetime + + """Whether this attempt completed successfully""" + success: Boolean! + + """Function routing slug (denormalized from the invocation)""" + taskIdentifier: String! +} + +"""A connection to a list of `FunctionInvocationAttempt` values.""" +type FunctionInvocationAttemptConnection { + """ + A list of edges which contains the `FunctionInvocationAttempt` and cursor to aid in pagination. + """ + edges: [FunctionInvocationAttemptEdge]! + + """A list of `FunctionInvocationAttempt` objects.""" + nodes: [FunctionInvocationAttempt]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `FunctionInvocationAttempt` you could get from the connection. + """ + totalCount: Int! +} + +"""A `FunctionInvocationAttempt` edge in the connection.""" +type FunctionInvocationAttemptEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `FunctionInvocationAttempt` at the end of the edge.""" + node: FunctionInvocationAttempt +} + +""" +A filter to be used against `FunctionInvocationAttempt` object types. All fields are combined with a logical ‘and.’ +""" +input FunctionInvocationAttemptFilter { + """Filter by the object’s `actorId` field.""" + actorId: UUIDFilter + + """Checks for all expressions in this list.""" + and: [FunctionInvocationAttemptFilter!] + + """Filter by the object’s `attempt` field.""" + attempt: IntFilter + + """Filter by the object’s `createdAt` field.""" + createdAt: DatetimeFilter + + """Filter by the object’s `databaseId` field.""" + databaseId: UUIDFilter + + """Filter by the object’s `durationMs` field.""" + durationMs: IntFilter + + """Filter by the object’s `error` field.""" + error: StringFilter + + """Filter by the object’s `errorDetail` field.""" + errorDetail: JSONFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Filter by the object’s `invocationCreatedAt` field.""" + invocationCreatedAt: DatetimeFilter + + """Filter by the object’s `invocationId` field.""" + invocationId: UUIDFilter + + """Negates the expression.""" + not: FunctionInvocationAttemptFilter + + """Checks for any expressions in this list.""" + or: [FunctionInvocationAttemptFilter!] + + """Filter by the object’s `startedAt` field.""" + startedAt: DatetimeFilter + + """Filter by the object’s `success` field.""" + success: BooleanFilter + + """Filter by the object’s `taskIdentifier` field.""" + taskIdentifier: StringFilter +} + +"""An input for mutations affecting `FunctionInvocationAttempt`""" +input FunctionInvocationAttemptInput { + """Who triggered the invocation (NULL for system/cron)""" + actorId: UUID + + """1-based attempt number for this invocation""" + attempt: Int! + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime + + """Database that owns this resource (database-scoped isolation)""" + databaseId: UUID! + + """Wall-clock attempt time in milliseconds""" + durationMs: Int + + """Error message when the attempt failed""" + error: String + + """Structured error context (stack, code, provider response)""" + errorDetail: JSON + + """Unique attempt identifier""" + id: UUID + + """ + created_at of the referenced invocation (partition-pruned lookups against the invocations PK) + """ + invocationCreatedAt: Datetime! + + """ + Invocation this attempt belongs to (soft reference paired with invocation_created_at) + """ + invocationId: UUID! + + """When the attempt began executing""" + startedAt: Datetime + + """Whether this attempt completed successfully""" + success: Boolean! + + """Function routing slug (denormalized from the invocation)""" + taskIdentifier: String! +} + +"""Methods to use when ordering `FunctionInvocationAttempt`.""" +enum FunctionInvocationAttemptOrderBy { + ACTOR_ID_ASC + ACTOR_ID_DESC + ATTEMPT_ASC + ATTEMPT_DESC + CREATED_AT_ASC + CREATED_AT_DESC + DATABASE_ID_ASC + DATABASE_ID_DESC + DURATION_MS_ASC + DURATION_MS_DESC + ERROR_ASC + ERROR_DESC + ERROR_DETAIL_ASC + ERROR_DETAIL_DESC + ID_ASC + ID_DESC + INVOCATION_CREATED_AT_ASC + INVOCATION_CREATED_AT_DESC + INVOCATION_ID_ASC + INVOCATION_ID_DESC + NATURAL + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + STARTED_AT_ASC + STARTED_AT_DESC + SUCCESS_ASC + SUCCESS_DESC + TASK_IDENTIFIER_ASC + TASK_IDENTIFIER_DESC +} + +""" +Represents an update to a `FunctionInvocationAttempt`. Fields that are set will be updated. +""" +input FunctionInvocationAttemptPatch { + """Who triggered the invocation (NULL for system/cron)""" + actorId: UUID + + """1-based attempt number for this invocation""" + attempt: Int + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime + + """Database that owns this resource (database-scoped isolation)""" + databaseId: UUID + + """Wall-clock attempt time in milliseconds""" + durationMs: Int + + """Error message when the attempt failed""" + error: String + + """Structured error context (stack, code, provider response)""" + errorDetail: JSON + + """Unique attempt identifier""" + id: UUID + + """ + created_at of the referenced invocation (partition-pruned lookups against the invocations PK) + """ + invocationCreatedAt: Datetime + + """ + Invocation this attempt belongs to (soft reference paired with invocation_created_at) + """ + invocationId: UUID + + """When the attempt began executing""" + startedAt: Datetime + + """Whether this attempt completed successfully""" + success: Boolean + + """Function routing slug (denormalized from the invocation)""" + taskIdentifier: String +} + +"""A connection to a list of `FunctionInvocation` values.""" +type FunctionInvocationConnection { + """ + A list of edges which contains the `FunctionInvocation` and cursor to aid in pagination. + """ + edges: [FunctionInvocationEdge]! + + """A list of `FunctionInvocation` objects.""" + nodes: [FunctionInvocation]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `FunctionInvocation` you could get from the connection. + """ + totalCount: Int! +} """A `FunctionInvocation` edge in the connection.""" type FunctionInvocationEdge { @@ -8471,7 +8749,9 @@ input FunctionInvocationInput { """Wall-clock execution time in milliseconds""" durationMs: Int - """Error message when status is failed""" + """ + Error message when status is failed, or the reason the run was skipped when status is skipped + """ error: String """ @@ -8505,7 +8785,9 @@ input FunctionInvocationInput { """When execution started""" startedAt: Datetime - """Lifecycle: pending → running → completed/failed/cancelled""" + """ + Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) + """ status: String """ @@ -8593,7 +8875,9 @@ input FunctionInvocationPatch { """Wall-clock execution time in milliseconds""" durationMs: Int - """Error message when status is failed""" + """ + Error message when status is failed, or the reason the run was skipped when status is skipped + """ error: String """ @@ -8627,7 +8911,9 @@ input FunctionInvocationPatch { """When execution started""" startedAt: Datetime - """Lifecycle: pending → running → completed/failed/cancelled""" + """ + Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) + """ status: String """ @@ -10075,11 +10361,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -10147,6 +10480,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -10157,6 +10493,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! @@ -10324,6 +10662,14 @@ type Mutation { input: CreateFunctionInvocationInput! ): CreateFunctionInvocationPayload + """Creates a single `FunctionInvocationAttempt`.""" + createFunctionInvocationAttempt( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateFunctionInvocationAttemptInput! + ): CreateFunctionInvocationAttemptPayload + """Creates a single `InfraCommit`.""" createInfraCommit( """ @@ -10428,6 +10774,14 @@ type Mutation { input: CreatePlatformFunctionInvocationInput! ): CreatePlatformFunctionInvocationPayload + """Creates a single `PlatformFunctionInvocationAttempt`.""" + createPlatformFunctionInvocationAttempt( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreatePlatformFunctionInvocationAttemptInput! + ): CreatePlatformFunctionInvocationAttemptPayload + """Creates a single `PlatformInfraCommit`.""" createPlatformInfraCommit( """ @@ -10740,6 +11094,14 @@ type Mutation { input: DeleteFunctionInvocationInput! ): DeleteFunctionInvocationPayload + """Deletes a single `FunctionInvocationAttempt` using a unique key.""" + deleteFunctionInvocationAttempt( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteFunctionInvocationAttemptInput! + ): DeleteFunctionInvocationAttemptPayload + """Deletes a single `InfraCommit` using a unique key.""" deleteInfraCommit( """ @@ -10844,6 +11206,16 @@ type Mutation { input: DeletePlatformFunctionInvocationInput! ): DeletePlatformFunctionInvocationPayload + """ + Deletes a single `PlatformFunctionInvocationAttempt` using a unique key. + """ + deletePlatformFunctionInvocationAttempt( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeletePlatformFunctionInvocationAttemptInput! + ): DeletePlatformFunctionInvocationAttemptPayload + """Deletes a single `PlatformInfraCommit` using a unique key.""" deletePlatformInfraCommit( """ @@ -11305,6 +11677,16 @@ type Mutation { input: UpdateFunctionInvocationInput! ): UpdateFunctionInvocationPayload + """ + Updates a single `FunctionInvocationAttempt` using a unique key and a patch. + """ + updateFunctionInvocationAttempt( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateFunctionInvocationAttemptInput! + ): UpdateFunctionInvocationAttemptPayload + """Updates a single `InfraCommit` using a unique key and a patch.""" updateInfraCommit( """ @@ -11421,6 +11803,16 @@ type Mutation { input: UpdatePlatformFunctionInvocationInput! ): UpdatePlatformFunctionInvocationPayload + """ + Updates a single `PlatformFunctionInvocationAttempt` using a unique key and a patch. + """ + updatePlatformFunctionInvocationAttempt( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdatePlatformFunctionInvocationAttemptInput! + ): UpdatePlatformFunctionInvocationAttemptPayload + """Updates a single `PlatformInfraCommit` using a unique key and a patch.""" updatePlatformInfraCommit( """ @@ -12322,134 +12714,6 @@ type PageInfo { startCursor: Cursor } -type PlatformDeclaredCapacity { - cpuLimitMillicores: BigInt - cpuRequestMillicores: BigInt - installationId: UUID - isTransient: Boolean - kind: String - memoryLimitBytes: BigInt - memoryRequestBytes: BigInt - namespaceId: UUID - podCountMax: Int - podCountMin: Int - source: String - sourceId: UUID - storageSizeBytes: BigInt -} - -"""A connection to a list of `PlatformDeclaredCapacity` values.""" -type PlatformDeclaredCapacityConnection { - """ - A list of edges which contains the `PlatformDeclaredCapacity` and cursor to aid in pagination. - """ - edges: [PlatformDeclaredCapacityEdge]! - - """A list of `PlatformDeclaredCapacity` objects.""" - nodes: [PlatformDeclaredCapacity]! - - """Information to aid in pagination.""" - pageInfo: PageInfo! - - """ - The count of *all* `PlatformDeclaredCapacity` you could get from the connection. - """ - totalCount: Int! -} - -"""A `PlatformDeclaredCapacity` edge in the connection.""" -type PlatformDeclaredCapacityEdge { - """A cursor for use in pagination.""" - cursor: Cursor - - """The `PlatformDeclaredCapacity` at the end of the edge.""" - node: PlatformDeclaredCapacity -} - -""" -A filter to be used against `PlatformDeclaredCapacity` object types. All fields are combined with a logical ‘and.’ -""" -input PlatformDeclaredCapacityFilter { - """Checks for all expressions in this list.""" - and: [PlatformDeclaredCapacityFilter!] - - """Filter by the object’s `cpuLimitMillicores` field.""" - cpuLimitMillicores: BigIntFilter - - """Filter by the object’s `cpuRequestMillicores` field.""" - cpuRequestMillicores: BigIntFilter - - """Filter by the object’s `installationId` field.""" - installationId: UUIDFilter - - """Filter by the object’s `isTransient` field.""" - isTransient: BooleanFilter - - """Filter by the object’s `kind` field.""" - kind: StringFilter - - """Filter by the object’s `memoryLimitBytes` field.""" - memoryLimitBytes: BigIntFilter - - """Filter by the object’s `memoryRequestBytes` field.""" - memoryRequestBytes: BigIntFilter - - """Filter by the object’s `namespaceId` field.""" - namespaceId: UUIDFilter - - """Negates the expression.""" - not: PlatformDeclaredCapacityFilter - - """Checks for any expressions in this list.""" - or: [PlatformDeclaredCapacityFilter!] - - """Filter by the object’s `podCountMax` field.""" - podCountMax: IntFilter - - """Filter by the object’s `podCountMin` field.""" - podCountMin: IntFilter - - """Filter by the object’s `source` field.""" - source: StringFilter - - """Filter by the object’s `sourceId` field.""" - sourceId: UUIDFilter - - """Filter by the object’s `storageSizeBytes` field.""" - storageSizeBytes: BigIntFilter -} - -"""Methods to use when ordering `PlatformDeclaredCapacity`.""" -enum PlatformDeclaredCapacityOrderBy { - CPU_LIMIT_MILLICORES_ASC - CPU_LIMIT_MILLICORES_DESC - CPU_REQUEST_MILLICORES_ASC - CPU_REQUEST_MILLICORES_DESC - INSTALLATION_ID_ASC - INSTALLATION_ID_DESC - IS_TRANSIENT_ASC - IS_TRANSIENT_DESC - KIND_ASC - KIND_DESC - MEMORY_LIMIT_BYTES_ASC - MEMORY_LIMIT_BYTES_DESC - MEMORY_REQUEST_BYTES_ASC - MEMORY_REQUEST_BYTES_DESC - NAMESPACE_ID_ASC - NAMESPACE_ID_DESC - NATURAL - POD_COUNT_MAX_ASC - POD_COUNT_MAX_DESC - POD_COUNT_MIN_ASC - POD_COUNT_MIN_DESC - SOURCE_ASC - SOURCE_DESC - SOURCE_ID_ASC - SOURCE_ID_DESC - STORAGE_SIZE_BYTES_ASC - STORAGE_SIZE_BYTES_DESC -} - """ Join table binding function definitions to API endpoints with per-binding alias and config """ @@ -12646,6 +12910,11 @@ type PlatformFunctionDefinition { """ accessChannels: [String]! + """ + Whether executions are metered through the invocation ledger and billing quota gate + """ + billable: Boolean! + """Function task category (e.g. email, embed, chunk, custom)""" category: String! @@ -12862,6 +13131,11 @@ type PlatformFunctionDefinition { """Minimum pod count for Knative autoscaling (minScale)""" scaleMin: Int! + """ + Platform system definition: its task_identifier cannot be shadowed by non-platform registration + """ + system: Boolean! + """ Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. """ @@ -12873,9 +13147,9 @@ type PlatformFunctionDefinition { targetSchema: String """ - Computed routing slug: category:name (used by Knative job worker for dispatch) + Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) """ - taskIdentifier: String! + taskIdentifier: String """Knative request timeout in seconds""" timeoutSeconds: Int! @@ -12925,6 +13199,9 @@ input PlatformFunctionDefinitionFilter { """Checks for all expressions in this list.""" and: [PlatformFunctionDefinitionFilter!] + """Filter by the object’s `billable` field.""" + billable: BooleanFilter + """Filter by the object’s `category` field.""" category: StringFilter @@ -13052,6 +13329,9 @@ input PlatformFunctionDefinitionFilter { """Filter by the object’s `scaleMin` field.""" scaleMin: IntFilter + """Filter by the object’s `system` field.""" + system: BooleanFilter + """Filter by the object’s `targetFunction` field.""" targetFunction: StringFilter @@ -13078,6 +13358,11 @@ input PlatformFunctionDefinitionInput { """ accessChannels: [String] + """ + Whether executions are metered through the invocation ledger and billing quota gate + """ + billable: Boolean + """Function task category (e.g. email, embed, chunk, custom)""" category: String! @@ -13207,6 +13492,11 @@ input PlatformFunctionDefinitionInput { """Minimum pod count for Knative autoscaling (minScale)""" scaleMin: Int + """ + Platform system definition: its task_identifier cannot be shadowed by non-platform registration + """ + system: Boolean + """ Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. """ @@ -13217,11 +13507,6 @@ input PlatformFunctionDefinitionInput { """ targetSchema: String - """ - Computed routing slug: category:name (used by Knative job worker for dispatch) - """ - taskIdentifier: String! - """Knative request timeout in seconds""" timeoutSeconds: Int updatedAt: Datetime @@ -13236,6 +13521,8 @@ input PlatformFunctionDefinitionInput { enum PlatformFunctionDefinitionOrderBy { ACCESS_CHANNELS_ASC ACCESS_CHANNELS_DESC + BILLABLE_ASC + BILLABLE_DESC CATEGORY_ASC CATEGORY_DESC CONCURRENCY_ASC @@ -13309,6 +13596,8 @@ enum PlatformFunctionDefinitionOrderBy { SCALE_MAX_DESC SCALE_MIN_ASC SCALE_MIN_DESC + SYSTEM_ASC + SYSTEM_DESC TARGET_FUNCTION_ASC TARGET_FUNCTION_DESC TARGET_SCHEMA_ASC @@ -13332,6 +13621,11 @@ input PlatformFunctionDefinitionPatch { """ accessChannels: [String] + """ + Whether executions are metered through the invocation ledger and billing quota gate + """ + billable: Boolean + """Function task category (e.g. email, embed, chunk, custom)""" category: String @@ -13461,6 +13755,11 @@ input PlatformFunctionDefinitionPatch { """Minimum pod count for Knative autoscaling (minScale)""" scaleMin: Int + """ + Platform system definition: its task_identifier cannot be shadowed by non-platform registration + """ + system: Boolean + """ Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. """ @@ -13471,11 +13770,6 @@ input PlatformFunctionDefinitionPatch { """ targetSchema: String - """ - Computed routing slug: category:name (used by Knative job worker for dispatch) - """ - taskIdentifier: String - """Knative request timeout in seconds""" timeoutSeconds: Int updatedAt: Datetime @@ -14266,61 +14560,307 @@ type PlatformFunctionInvocation { """Invocation trigger channel: api, graph, cron, sync, webhook, or worker""" channel: String - """When execution completed""" - completedAt: Datetime + """When execution completed""" + completedAt: Datetime + + """Invocation creation timestamp (partition key)""" + createdAt: Datetime! + + """ + Scope that owns function_definition_id (e.g. app/org/database/platform) — the per-scope definitions table the resolver selected + """ + definitionScope: String + + """Wall-clock execution time in milliseconds""" + durationMs: Int + + """ + Error message when status is failed, or the reason the run was skipped when status is skipped + """ + error: String + + """ + Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. + """ + functionDefinitionId: UUID + + """Groups all node invocations from a single flow graph execution""" + graphExecutionId: UUID + + """Unique invocation identifier""" + id: UUID! + + """FK to app_jobs.jobs — the underlying transport""" + jobId: BigInt + + """Parent invocation when this is a child node of a flow graph execution""" + parentInvocationId: UUID + + """Function input payload""" + payload: JSON + + """ + Non-secret channel-specific invocation provenance (route/binding/event identifiers only) + """ + provenance: JSON! + + """Function return value (success) or structured error (failure)""" + result: JSON + + """When execution started""" + startedAt: Datetime + + """ + Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) + """ + status: String! + + """ + Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. + """ + taskIdentifier: String! +} + +""" +Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail +""" +type PlatformFunctionInvocationAttempt { + """Who triggered the invocation (NULL for system/cron)""" + actorId: UUID + + """1-based attempt number for this invocation""" + attempt: Int! + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime! + + """Wall-clock attempt time in milliseconds""" + durationMs: Int + + """Error message when the attempt failed""" + error: String + + """Structured error context (stack, code, provider response)""" + errorDetail: JSON + + """Unique attempt identifier""" + id: UUID! + + """ + created_at of the referenced invocation (partition-pruned lookups against the invocations PK) + """ + invocationCreatedAt: Datetime! + + """ + Invocation this attempt belongs to (soft reference paired with invocation_created_at) + """ + invocationId: UUID! + + """When the attempt began executing""" + startedAt: Datetime + + """Whether this attempt completed successfully""" + success: Boolean! + + """Function routing slug (denormalized from the invocation)""" + taskIdentifier: String! +} + +"""A connection to a list of `PlatformFunctionInvocationAttempt` values.""" +type PlatformFunctionInvocationAttemptConnection { + """ + A list of edges which contains the `PlatformFunctionInvocationAttempt` and cursor to aid in pagination. + """ + edges: [PlatformFunctionInvocationAttemptEdge]! + + """A list of `PlatformFunctionInvocationAttempt` objects.""" + nodes: [PlatformFunctionInvocationAttempt]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `PlatformFunctionInvocationAttempt` you could get from the connection. + """ + totalCount: Int! +} + +"""A `PlatformFunctionInvocationAttempt` edge in the connection.""" +type PlatformFunctionInvocationAttemptEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `PlatformFunctionInvocationAttempt` at the end of the edge.""" + node: PlatformFunctionInvocationAttempt +} + +""" +A filter to be used against `PlatformFunctionInvocationAttempt` object types. All fields are combined with a logical ‘and.’ +""" +input PlatformFunctionInvocationAttemptFilter { + """Filter by the object’s `actorId` field.""" + actorId: UUIDFilter + + """Checks for all expressions in this list.""" + and: [PlatformFunctionInvocationAttemptFilter!] + + """Filter by the object’s `attempt` field.""" + attempt: IntFilter + + """Filter by the object’s `createdAt` field.""" + createdAt: DatetimeFilter + + """Filter by the object’s `durationMs` field.""" + durationMs: IntFilter + + """Filter by the object’s `error` field.""" + error: StringFilter + + """Filter by the object’s `errorDetail` field.""" + errorDetail: JSONFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Filter by the object’s `invocationCreatedAt` field.""" + invocationCreatedAt: DatetimeFilter + + """Filter by the object’s `invocationId` field.""" + invocationId: UUIDFilter + + """Negates the expression.""" + not: PlatformFunctionInvocationAttemptFilter + + """Checks for any expressions in this list.""" + or: [PlatformFunctionInvocationAttemptFilter!] + + """Filter by the object’s `startedAt` field.""" + startedAt: DatetimeFilter + + """Filter by the object’s `success` field.""" + success: BooleanFilter + + """Filter by the object’s `taskIdentifier` field.""" + taskIdentifier: StringFilter +} + +"""An input for mutations affecting `PlatformFunctionInvocationAttempt`""" +input PlatformFunctionInvocationAttemptInput { + """Who triggered the invocation (NULL for system/cron)""" + actorId: UUID + + """1-based attempt number for this invocation""" + attempt: Int! + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime + + """Wall-clock attempt time in milliseconds""" + durationMs: Int + + """Error message when the attempt failed""" + error: String + + """Structured error context (stack, code, provider response)""" + errorDetail: JSON + + """Unique attempt identifier""" + id: UUID + + """ + created_at of the referenced invocation (partition-pruned lookups against the invocations PK) + """ + invocationCreatedAt: Datetime! + + """ + Invocation this attempt belongs to (soft reference paired with invocation_created_at) + """ + invocationId: UUID! + + """When the attempt began executing""" + startedAt: Datetime + + """Whether this attempt completed successfully""" + success: Boolean! + + """Function routing slug (denormalized from the invocation)""" + taskIdentifier: String! +} + +"""Methods to use when ordering `PlatformFunctionInvocationAttempt`.""" +enum PlatformFunctionInvocationAttemptOrderBy { + ACTOR_ID_ASC + ACTOR_ID_DESC + ATTEMPT_ASC + ATTEMPT_DESC + CREATED_AT_ASC + CREATED_AT_DESC + DURATION_MS_ASC + DURATION_MS_DESC + ERROR_ASC + ERROR_DESC + ERROR_DETAIL_ASC + ERROR_DETAIL_DESC + ID_ASC + ID_DESC + INVOCATION_CREATED_AT_ASC + INVOCATION_CREATED_AT_DESC + INVOCATION_ID_ASC + INVOCATION_ID_DESC + NATURAL + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + STARTED_AT_ASC + STARTED_AT_DESC + SUCCESS_ASC + SUCCESS_DESC + TASK_IDENTIFIER_ASC + TASK_IDENTIFIER_DESC +} + +""" +Represents an update to a `PlatformFunctionInvocationAttempt`. Fields that are set will be updated. +""" +input PlatformFunctionInvocationAttemptPatch { + """Who triggered the invocation (NULL for system/cron)""" + actorId: UUID - """Invocation creation timestamp (partition key)""" - createdAt: Datetime! + """1-based attempt number for this invocation""" + attempt: Int - """ - Scope that owns function_definition_id (e.g. app/org/database/platform) — the per-scope definitions table the resolver selected - """ - definitionScope: String + """When the attempt result was recorded (partition key)""" + createdAt: Datetime - """Wall-clock execution time in milliseconds""" + """Wall-clock attempt time in milliseconds""" durationMs: Int - """Error message when status is failed""" + """Error message when the attempt failed""" error: String - """ - Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. - """ - functionDefinitionId: UUID - - """Groups all node invocations from a single flow graph execution""" - graphExecutionId: UUID - - """Unique invocation identifier""" - id: UUID! - - """FK to app_jobs.jobs — the underlying transport""" - jobId: BigInt - - """Parent invocation when this is a child node of a flow graph execution""" - parentInvocationId: UUID + """Structured error context (stack, code, provider response)""" + errorDetail: JSON - """Function input payload""" - payload: JSON + """Unique attempt identifier""" + id: UUID """ - Non-secret channel-specific invocation provenance (route/binding/event identifiers only) + created_at of the referenced invocation (partition-pruned lookups against the invocations PK) """ - provenance: JSON! + invocationCreatedAt: Datetime - """Function return value (success) or structured error (failure)""" - result: JSON + """ + Invocation this attempt belongs to (soft reference paired with invocation_created_at) + """ + invocationId: UUID - """When execution started""" + """When the attempt began executing""" startedAt: Datetime - """Lifecycle: pending → running → completed/failed/cancelled""" - status: String! + """Whether this attempt completed successfully""" + success: Boolean - """ - Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. - """ - taskIdentifier: String! + """Function routing slug (denormalized from the invocation)""" + taskIdentifier: String } """A connection to a list of `PlatformFunctionInvocation` values.""" @@ -14455,7 +14995,9 @@ input PlatformFunctionInvocationInput { """Wall-clock execution time in milliseconds""" durationMs: Int - """Error message when status is failed""" + """ + Error message when status is failed, or the reason the run was skipped when status is skipped + """ error: String """ @@ -14489,7 +15031,9 @@ input PlatformFunctionInvocationInput { """When execution started""" startedAt: Datetime - """Lifecycle: pending → running → completed/failed/cancelled""" + """ + Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) + """ status: String """ @@ -14572,7 +15116,9 @@ input PlatformFunctionInvocationPatch { """Wall-clock execution time in milliseconds""" durationMs: Int - """Error message when status is failed""" + """ + Error message when status is failed, or the reason the run was skipped when status is skipped + """ error: String """ @@ -14606,7 +15152,9 @@ input PlatformFunctionInvocationPatch { """When execution started""" startedAt: Datetime - """Lifecycle: pending → running → completed/failed/cancelled""" + """ + Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) + """ status: String """ @@ -16021,7 +16569,7 @@ type PlatformResource { integrations: [String]! """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer """ kind: String! @@ -16165,6 +16713,134 @@ type PlatformResourceConnection { totalCount: Int! } +type PlatformResourceDeclaredCapacity { + cpuLimitMillicores: BigInt + cpuRequestMillicores: BigInt + installationId: UUID + isTransient: Boolean + kind: String + memoryLimitBytes: BigInt + memoryRequestBytes: BigInt + namespaceId: UUID + podCountMax: Int + podCountMin: Int + source: String + sourceId: UUID + storageSizeBytes: BigInt +} + +"""A connection to a list of `PlatformResourceDeclaredCapacity` values.""" +type PlatformResourceDeclaredCapacityConnection { + """ + A list of edges which contains the `PlatformResourceDeclaredCapacity` and cursor to aid in pagination. + """ + edges: [PlatformResourceDeclaredCapacityEdge]! + + """A list of `PlatformResourceDeclaredCapacity` objects.""" + nodes: [PlatformResourceDeclaredCapacity]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `PlatformResourceDeclaredCapacity` you could get from the connection. + """ + totalCount: Int! +} + +"""A `PlatformResourceDeclaredCapacity` edge in the connection.""" +type PlatformResourceDeclaredCapacityEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `PlatformResourceDeclaredCapacity` at the end of the edge.""" + node: PlatformResourceDeclaredCapacity +} + +""" +A filter to be used against `PlatformResourceDeclaredCapacity` object types. All fields are combined with a logical ‘and.’ +""" +input PlatformResourceDeclaredCapacityFilter { + """Checks for all expressions in this list.""" + and: [PlatformResourceDeclaredCapacityFilter!] + + """Filter by the object’s `cpuLimitMillicores` field.""" + cpuLimitMillicores: BigIntFilter + + """Filter by the object’s `cpuRequestMillicores` field.""" + cpuRequestMillicores: BigIntFilter + + """Filter by the object’s `installationId` field.""" + installationId: UUIDFilter + + """Filter by the object’s `isTransient` field.""" + isTransient: BooleanFilter + + """Filter by the object’s `kind` field.""" + kind: StringFilter + + """Filter by the object’s `memoryLimitBytes` field.""" + memoryLimitBytes: BigIntFilter + + """Filter by the object’s `memoryRequestBytes` field.""" + memoryRequestBytes: BigIntFilter + + """Filter by the object’s `namespaceId` field.""" + namespaceId: UUIDFilter + + """Negates the expression.""" + not: PlatformResourceDeclaredCapacityFilter + + """Checks for any expressions in this list.""" + or: [PlatformResourceDeclaredCapacityFilter!] + + """Filter by the object’s `podCountMax` field.""" + podCountMax: IntFilter + + """Filter by the object’s `podCountMin` field.""" + podCountMin: IntFilter + + """Filter by the object’s `source` field.""" + source: StringFilter + + """Filter by the object’s `sourceId` field.""" + sourceId: UUIDFilter + + """Filter by the object’s `storageSizeBytes` field.""" + storageSizeBytes: BigIntFilter +} + +"""Methods to use when ordering `PlatformResourceDeclaredCapacity`.""" +enum PlatformResourceDeclaredCapacityOrderBy { + CPU_LIMIT_MILLICORES_ASC + CPU_LIMIT_MILLICORES_DESC + CPU_REQUEST_MILLICORES_ASC + CPU_REQUEST_MILLICORES_DESC + INSTALLATION_ID_ASC + INSTALLATION_ID_DESC + IS_TRANSIENT_ASC + IS_TRANSIENT_DESC + KIND_ASC + KIND_DESC + MEMORY_LIMIT_BYTES_ASC + MEMORY_LIMIT_BYTES_DESC + MEMORY_REQUEST_BYTES_ASC + MEMORY_REQUEST_BYTES_DESC + NAMESPACE_ID_ASC + NAMESPACE_ID_DESC + NATURAL + POD_COUNT_MAX_ASC + POD_COUNT_MAX_DESC + POD_COUNT_MIN_ASC + POD_COUNT_MIN_DESC + SOURCE_ASC + SOURCE_DESC + SOURCE_ID_ASC + SOURCE_ID_DESC + STORAGE_SIZE_BYTES_ASC + STORAGE_SIZE_BYTES_DESC +} + """ Resource definitions — templates for resource kinds declaring default spec and secret/config requirements """ @@ -16187,7 +16863,7 @@ type PlatformResourceDefinition { integrations: [String]! """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds """ kind: String! @@ -16375,7 +17051,7 @@ input PlatformResourceDefinitionInput { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds """ kind: String! @@ -16474,7 +17150,7 @@ input PlatformResourceDefinitionPatch { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds """ kind: String @@ -16839,7 +17515,7 @@ input PlatformResourceInput { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer """ kind: String! @@ -17206,10 +17882,10 @@ input PlatformResourceInstallationsInstallInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pName: String - pNamespaceId: UUID - pParams: JSON - pSlug: String + name: String + namespaceId: UUID + newParams: JSON + slug: String } """The output of our `platformResourceInstallationsInstall` mutation.""" @@ -17234,8 +17910,8 @@ input PlatformResourceInstallationsRollbackInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pCommitId: UUID - pInstallationId: UUID + commitId: UUID + targetInstallationId: UUID } """The output of our `platformResourceInstallationsRollback` mutation.""" @@ -17259,7 +17935,7 @@ input PlatformResourceInstallationsUninstallInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pInstallationId: UUID + targetInstallationId: UUID } """The output of our `platformResourceInstallationsUninstall` mutation.""" @@ -17283,8 +17959,8 @@ input PlatformResourceInstallationsUpgradeInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pInstallationId: UUID - pParams: JSON + newParams: JSON + targetInstallationId: UUID } """The output of our `platformResourceInstallationsUpgrade` mutation.""" @@ -17390,7 +18066,7 @@ input PlatformResourcePatch { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer """ kind: String @@ -17632,7 +18308,7 @@ input PlatformResourceToManyPlatformResourceStatusCheckFilter { } """ -Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) +Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) """ type PlatformResourceUsageLog { """CPU gauge in millicores at sample time (NULL when unknown)""" @@ -17663,7 +18339,9 @@ type PlatformResourceUsageLog { """Sample timestamp (partition key) — end of the measured interval""" sampledAt: Datetime! - """Sample producer: self (workload heartbeat) or observer (reconciler)""" + """ + Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) + """ source: String! } @@ -17766,7 +18444,9 @@ input PlatformResourceUsageLogInput { """Sample timestamp (partition key) — end of the measured interval""" sampledAt: Datetime - """Sample producer: self (workload heartbeat) or observer (reconciler)""" + """ + Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) + """ source: String! } @@ -17827,7 +18507,9 @@ input PlatformResourceUsageLogPatch { """Sample timestamp (partition key) — end of the measured interval""" sampledAt: Datetime - """Sample producer: self (workload heartbeat) or observer (reconciler)""" + """ + Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) + """ source: String } @@ -18037,7 +18719,7 @@ input PlatformResourceUsageSummaryPatch { sampleCount: Int } -type PlatformResourceUtilizationDaily { +type PlatformResourceUtilization { avgMemoryBytes: BigInt cpuLimitMillicores: BigInt cpuPeakUtilization: BigFloat @@ -18059,40 +18741,40 @@ type PlatformResourceUtilizationDaily { sampleCount: Int } -"""A connection to a list of `PlatformResourceUtilizationDaily` values.""" -type PlatformResourceUtilizationDailyConnection { +"""A connection to a list of `PlatformResourceUtilization` values.""" +type PlatformResourceUtilizationConnection { """ - A list of edges which contains the `PlatformResourceUtilizationDaily` and cursor to aid in pagination. + A list of edges which contains the `PlatformResourceUtilization` and cursor to aid in pagination. """ - edges: [PlatformResourceUtilizationDailyEdge]! + edges: [PlatformResourceUtilizationEdge]! - """A list of `PlatformResourceUtilizationDaily` objects.""" - nodes: [PlatformResourceUtilizationDaily]! + """A list of `PlatformResourceUtilization` objects.""" + nodes: [PlatformResourceUtilization]! """Information to aid in pagination.""" pageInfo: PageInfo! """ - The count of *all* `PlatformResourceUtilizationDaily` you could get from the connection. + The count of *all* `PlatformResourceUtilization` you could get from the connection. """ totalCount: Int! } -"""A `PlatformResourceUtilizationDaily` edge in the connection.""" -type PlatformResourceUtilizationDailyEdge { +"""A `PlatformResourceUtilization` edge in the connection.""" +type PlatformResourceUtilizationEdge { """A cursor for use in pagination.""" cursor: Cursor - """The `PlatformResourceUtilizationDaily` at the end of the edge.""" - node: PlatformResourceUtilizationDaily + """The `PlatformResourceUtilization` at the end of the edge.""" + node: PlatformResourceUtilization } """ -A filter to be used against `PlatformResourceUtilizationDaily` object types. All fields are combined with a logical ‘and.’ +A filter to be used against `PlatformResourceUtilization` object types. All fields are combined with a logical ‘and.’ """ -input PlatformResourceUtilizationDailyFilter { +input PlatformResourceUtilizationFilter { """Checks for all expressions in this list.""" - and: [PlatformResourceUtilizationDailyFilter!] + and: [PlatformResourceUtilizationFilter!] """Filter by the object’s `avgMemoryBytes` field.""" avgMemoryBytes: BigIntFilter @@ -18140,10 +18822,10 @@ input PlatformResourceUtilizationDailyFilter { namespaceId: UUIDFilter """Negates the expression.""" - not: PlatformResourceUtilizationDailyFilter + not: PlatformResourceUtilizationFilter """Checks for any expressions in this list.""" - or: [PlatformResourceUtilizationDailyFilter!] + or: [PlatformResourceUtilizationFilter!] """Filter by the object’s `replicas` field.""" replicas: IntFilter @@ -18158,8 +18840,8 @@ input PlatformResourceUtilizationDailyFilter { sampleCount: IntFilter } -"""Methods to use when ordering `PlatformResourceUtilizationDaily`.""" -enum PlatformResourceUtilizationDailyOrderBy { +"""Methods to use when ordering `PlatformResourceUtilization`.""" +enum PlatformResourceUtilizationOrderBy { AVG_MEMORY_BYTES_ASC AVG_MEMORY_BYTES_DESC CPU_LIMIT_MILLICORES_ASC @@ -19252,35 +19934,6 @@ type Query { where: DbPresetFilter ): DbPresetConnection - """Reads and enables pagination through a set of `DeclaredCapacity`.""" - declaredCapacities( - """Read all values in the set after (below) this cursor.""" - after: Cursor - - """Read all values in the set before (above) this cursor.""" - before: Cursor - - """Only read the first `n` values of the set.""" - first: Int - - """Only read the last `n` values of the set.""" - last: Int - - """ - Skip the first `n` values from our `after` cursor, an alternative to cursor - based pagination. May not be used with `last`. - """ - offset: Int - - """The method to use when ordering `DeclaredCapacity`.""" - orderBy: [DeclaredCapacityOrderBy!] = [NATURAL] - - """ - A filter to be used in determining which values should be returned by the collection. - """ - where: DeclaredCapacityFilter - ): DeclaredCapacityConnection - """Reads and enables pagination through a set of `FunctionApiBinding`.""" functionApiBindings( """Read all values in the set after (below) this cursor.""" @@ -19666,6 +20319,37 @@ type Query { where: FunctionGraphFilter ): FunctionGraphConnection + """ + Reads and enables pagination through a set of `FunctionInvocationAttempt`. + """ + functionInvocationAttempts( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `FunctionInvocationAttempt`.""" + orderBy: [FunctionInvocationAttemptOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: FunctionInvocationAttemptFilter + ): FunctionInvocationAttemptConnection + """Reads and enables pagination through a set of `FunctionInvocation`.""" functionInvocations( """Read all values in the set after (below) this cursor.""" @@ -19936,37 +20620,6 @@ type Query { where: NamespaceFilter ): NamespaceConnection - """ - Reads and enables pagination through a set of `PlatformDeclaredCapacity`. - """ - platformDeclaredCapacities( - """Read all values in the set after (below) this cursor.""" - after: Cursor - - """Read all values in the set before (above) this cursor.""" - before: Cursor - - """Only read the first `n` values of the set.""" - first: Int - - """Only read the last `n` values of the set.""" - last: Int - - """ - Skip the first `n` values from our `after` cursor, an alternative to cursor - based pagination. May not be used with `last`. - """ - offset: Int - - """The method to use when ordering `PlatformDeclaredCapacity`.""" - orderBy: [PlatformDeclaredCapacityOrderBy!] = [NATURAL] - - """ - A filter to be used in determining which values should be returned by the collection. - """ - where: PlatformDeclaredCapacityFilter - ): PlatformDeclaredCapacityConnection - """ Reads and enables pagination through a set of `PlatformFunctionApiBinding`. """ @@ -20122,6 +20775,37 @@ type Query { where: PlatformFunctionExecutionLogFilter ): PlatformFunctionExecutionLogConnection + """ + Reads and enables pagination through a set of `PlatformFunctionInvocationAttempt`. + """ + platformFunctionInvocationAttempts( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `PlatformFunctionInvocationAttempt`.""" + orderBy: [PlatformFunctionInvocationAttemptOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: PlatformFunctionInvocationAttemptFilter + ): PlatformFunctionInvocationAttemptConnection + """ Reads and enables pagination through a set of `PlatformFunctionInvocation`. """ @@ -20349,6 +21033,37 @@ type Query { where: PlatformNamespaceFilter ): PlatformNamespaceConnection + """ + Reads and enables pagination through a set of `PlatformResourceDeclaredCapacity`. + """ + platformResourceDeclaredCapacities( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `PlatformResourceDeclaredCapacity`.""" + orderBy: [PlatformResourceDeclaredCapacityOrderBy!] = [NATURAL] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: PlatformResourceDeclaredCapacityFilter + ): PlatformResourceDeclaredCapacityConnection + """ Reads and enables pagination through a set of `PlatformResourceDefinition`. """ @@ -20534,9 +21249,9 @@ type Query { ): PlatformResourceUsageSummaryConnection """ - Reads and enables pagination through a set of `PlatformResourceUtilizationDaily`. + Reads and enables pagination through a set of `PlatformResourceUtilization`. """ - platformResourceUtilizationDailies( + platformResourceUtilizations( """Read all values in the set after (below) this cursor.""" after: Cursor @@ -20555,14 +21270,14 @@ type Query { """ offset: Int - """The method to use when ordering `PlatformResourceUtilizationDaily`.""" - orderBy: [PlatformResourceUtilizationDailyOrderBy!] = [NATURAL] + """The method to use when ordering `PlatformResourceUtilization`.""" + orderBy: [PlatformResourceUtilizationOrderBy!] = [NATURAL] """ A filter to be used in determining which values should be returned by the collection. """ - where: PlatformResourceUtilizationDailyFilter - ): PlatformResourceUtilizationDailyConnection + where: PlatformResourceUtilizationFilter + ): PlatformResourceUtilizationConnection """Reads and enables pagination through a set of `PlatformResource`.""" platformResources( @@ -20749,6 +21464,37 @@ type Query { ): PlatformWebhookEventConnection readFunctionGraph(graphId: UUID): JSON + """ + Reads and enables pagination through a set of `ResourceDeclaredCapacity`. + """ + resourceDeclaredCapacities( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `ResourceDeclaredCapacity`.""" + orderBy: [ResourceDeclaredCapacityOrderBy!] = [NATURAL] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: ResourceDeclaredCapacityFilter + ): ResourceDeclaredCapacityConnection + """Reads and enables pagination through a set of `ResourceDefinition`.""" resourceDefinitions( """Read all values in the set after (below) this cursor.""" @@ -20923,10 +21669,8 @@ type Query { where: ResourceUsageSummaryFilter ): ResourceUsageSummaryConnection - """ - Reads and enables pagination through a set of `ResourceUtilizationDaily`. - """ - resourceUtilizationDailies( + """Reads and enables pagination through a set of `ResourceUtilization`.""" + resourceUtilizations( """Read all values in the set after (below) this cursor.""" after: Cursor @@ -20945,14 +21689,14 @@ type Query { """ offset: Int - """The method to use when ordering `ResourceUtilizationDaily`.""" - orderBy: [ResourceUtilizationDailyOrderBy!] = [NATURAL] + """The method to use when ordering `ResourceUtilization`.""" + orderBy: [ResourceUtilizationOrderBy!] = [NATURAL] """ A filter to be used in determining which values should be returned by the collection. """ - where: ResourceUtilizationDailyFilter - ): ResourceUtilizationDailyConnection + where: ResourceUtilizationFilter + ): ResourceUtilizationConnection """Reads and enables pagination through a set of `Resource`.""" resources( @@ -21175,7 +21919,7 @@ type Resource { integrations: [String]! """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer """ kind: String! @@ -21313,6 +22057,134 @@ type ResourceConnection { totalCount: Int! } +type ResourceDeclaredCapacity { + cpuLimitMillicores: BigInt + cpuRequestMillicores: BigInt + installationId: UUID + isTransient: Boolean + kind: String + memoryLimitBytes: BigInt + memoryRequestBytes: BigInt + namespaceId: UUID + podCountMax: Int + podCountMin: Int + source: String + sourceId: UUID + storageSizeBytes: BigInt +} + +"""A connection to a list of `ResourceDeclaredCapacity` values.""" +type ResourceDeclaredCapacityConnection { + """ + A list of edges which contains the `ResourceDeclaredCapacity` and cursor to aid in pagination. + """ + edges: [ResourceDeclaredCapacityEdge]! + + """A list of `ResourceDeclaredCapacity` objects.""" + nodes: [ResourceDeclaredCapacity]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `ResourceDeclaredCapacity` you could get from the connection. + """ + totalCount: Int! +} + +"""A `ResourceDeclaredCapacity` edge in the connection.""" +type ResourceDeclaredCapacityEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `ResourceDeclaredCapacity` at the end of the edge.""" + node: ResourceDeclaredCapacity +} + +""" +A filter to be used against `ResourceDeclaredCapacity` object types. All fields are combined with a logical ‘and.’ +""" +input ResourceDeclaredCapacityFilter { + """Checks for all expressions in this list.""" + and: [ResourceDeclaredCapacityFilter!] + + """Filter by the object’s `cpuLimitMillicores` field.""" + cpuLimitMillicores: BigIntFilter + + """Filter by the object’s `cpuRequestMillicores` field.""" + cpuRequestMillicores: BigIntFilter + + """Filter by the object’s `installationId` field.""" + installationId: UUIDFilter + + """Filter by the object’s `isTransient` field.""" + isTransient: BooleanFilter + + """Filter by the object’s `kind` field.""" + kind: StringFilter + + """Filter by the object’s `memoryLimitBytes` field.""" + memoryLimitBytes: BigIntFilter + + """Filter by the object’s `memoryRequestBytes` field.""" + memoryRequestBytes: BigIntFilter + + """Filter by the object’s `namespaceId` field.""" + namespaceId: UUIDFilter + + """Negates the expression.""" + not: ResourceDeclaredCapacityFilter + + """Checks for any expressions in this list.""" + or: [ResourceDeclaredCapacityFilter!] + + """Filter by the object’s `podCountMax` field.""" + podCountMax: IntFilter + + """Filter by the object’s `podCountMin` field.""" + podCountMin: IntFilter + + """Filter by the object’s `source` field.""" + source: StringFilter + + """Filter by the object’s `sourceId` field.""" + sourceId: UUIDFilter + + """Filter by the object’s `storageSizeBytes` field.""" + storageSizeBytes: BigIntFilter +} + +"""Methods to use when ordering `ResourceDeclaredCapacity`.""" +enum ResourceDeclaredCapacityOrderBy { + CPU_LIMIT_MILLICORES_ASC + CPU_LIMIT_MILLICORES_DESC + CPU_REQUEST_MILLICORES_ASC + CPU_REQUEST_MILLICORES_DESC + INSTALLATION_ID_ASC + INSTALLATION_ID_DESC + IS_TRANSIENT_ASC + IS_TRANSIENT_DESC + KIND_ASC + KIND_DESC + MEMORY_LIMIT_BYTES_ASC + MEMORY_LIMIT_BYTES_DESC + MEMORY_REQUEST_BYTES_ASC + MEMORY_REQUEST_BYTES_DESC + NAMESPACE_ID_ASC + NAMESPACE_ID_DESC + NATURAL + POD_COUNT_MAX_ASC + POD_COUNT_MAX_DESC + POD_COUNT_MIN_ASC + POD_COUNT_MIN_DESC + SOURCE_ASC + SOURCE_DESC + SOURCE_ID_ASC + SOURCE_ID_DESC + STORAGE_SIZE_BYTES_ASC + STORAGE_SIZE_BYTES_DESC +} + """ Resource definitions — templates for resource kinds declaring default spec and secret/config requirements """ @@ -21338,7 +22210,7 @@ type ResourceDefinition { integrations: [String]! """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds """ kind: String! @@ -21530,7 +22402,7 @@ input ResourceDefinitionInput { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds """ kind: String! @@ -21634,7 +22506,7 @@ input ResourceDefinitionPatch { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds """ kind: String @@ -22015,7 +22887,7 @@ input ResourceInput { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer """ kind: String! @@ -22396,10 +23268,10 @@ input ResourceInstallationsInstallInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pName: String - pNamespaceId: UUID - pParams: JSON - pSlug: String + name: String + namespaceId: UUID + newParams: JSON + slug: String } """The output of our `resourceInstallationsInstall` mutation.""" @@ -22424,8 +23296,8 @@ input ResourceInstallationsRollbackInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pCommitId: UUID - pInstallationId: UUID + commitId: UUID + targetInstallationId: UUID } """The output of our `resourceInstallationsRollback` mutation.""" @@ -22449,7 +23321,7 @@ input ResourceInstallationsUninstallInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pInstallationId: UUID + targetInstallationId: UUID } """The output of our `resourceInstallationsUninstall` mutation.""" @@ -22473,8 +23345,8 @@ input ResourceInstallationsUpgradeInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pInstallationId: UUID - pParams: JSON + newParams: JSON + targetInstallationId: UUID } """The output of our `resourceInstallationsUpgrade` mutation.""" @@ -22585,7 +23457,7 @@ input ResourcePatch { integrations: [String] """ - Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate + Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer """ kind: String @@ -22854,7 +23726,7 @@ input ResourceToManyResourceStatusCheckFilter { } """ -Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) +Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) """ type ResourceUsageLog { """CPU gauge in millicores at sample time (NULL when unknown)""" @@ -22888,7 +23760,9 @@ type ResourceUsageLog { """Sample timestamp (partition key) — end of the measured interval""" sampledAt: Datetime! - """Sample producer: self (workload heartbeat) or observer (reconciler)""" + """ + Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) + """ source: String! } @@ -22997,7 +23871,9 @@ input ResourceUsageLogInput { """Sample timestamp (partition key) — end of the measured interval""" sampledAt: Datetime - """Sample producer: self (workload heartbeat) or observer (reconciler)""" + """ + Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) + """ source: String! } @@ -23063,7 +23939,9 @@ input ResourceUsageLogPatch { """Sample timestamp (partition key) — end of the measured interval""" sampledAt: Datetime - """Sample producer: self (workload heartbeat) or observer (reconciler)""" + """ + Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) + """ source: String } @@ -23287,7 +24165,7 @@ input ResourceUsageSummaryPatch { sampleCount: Int } -type ResourceUtilizationDaily { +type ResourceUtilization { avgMemoryBytes: BigInt cpuLimitMillicores: BigInt cpuPeakUtilization: BigFloat @@ -23309,40 +24187,40 @@ type ResourceUtilizationDaily { sampleCount: Int } -"""A connection to a list of `ResourceUtilizationDaily` values.""" -type ResourceUtilizationDailyConnection { +"""A connection to a list of `ResourceUtilization` values.""" +type ResourceUtilizationConnection { """ - A list of edges which contains the `ResourceUtilizationDaily` and cursor to aid in pagination. + A list of edges which contains the `ResourceUtilization` and cursor to aid in pagination. """ - edges: [ResourceUtilizationDailyEdge]! + edges: [ResourceUtilizationEdge]! - """A list of `ResourceUtilizationDaily` objects.""" - nodes: [ResourceUtilizationDaily]! + """A list of `ResourceUtilization` objects.""" + nodes: [ResourceUtilization]! """Information to aid in pagination.""" pageInfo: PageInfo! """ - The count of *all* `ResourceUtilizationDaily` you could get from the connection. + The count of *all* `ResourceUtilization` you could get from the connection. """ totalCount: Int! } -"""A `ResourceUtilizationDaily` edge in the connection.""" -type ResourceUtilizationDailyEdge { +"""A `ResourceUtilization` edge in the connection.""" +type ResourceUtilizationEdge { """A cursor for use in pagination.""" cursor: Cursor - """The `ResourceUtilizationDaily` at the end of the edge.""" - node: ResourceUtilizationDaily + """The `ResourceUtilization` at the end of the edge.""" + node: ResourceUtilization } """ -A filter to be used against `ResourceUtilizationDaily` object types. All fields are combined with a logical ‘and.’ +A filter to be used against `ResourceUtilization` object types. All fields are combined with a logical ‘and.’ """ -input ResourceUtilizationDailyFilter { +input ResourceUtilizationFilter { """Checks for all expressions in this list.""" - and: [ResourceUtilizationDailyFilter!] + and: [ResourceUtilizationFilter!] """Filter by the object’s `avgMemoryBytes` field.""" avgMemoryBytes: BigIntFilter @@ -23390,10 +24268,10 @@ input ResourceUtilizationDailyFilter { namespaceId: UUIDFilter """Negates the expression.""" - not: ResourceUtilizationDailyFilter + not: ResourceUtilizationFilter """Checks for any expressions in this list.""" - or: [ResourceUtilizationDailyFilter!] + or: [ResourceUtilizationFilter!] """Filter by the object’s `replicas` field.""" replicas: IntFilter @@ -23408,8 +24286,8 @@ input ResourceUtilizationDailyFilter { sampleCount: IntFilter } -"""Methods to use when ordering `ResourceUtilizationDaily`.""" -enum ResourceUtilizationDailyOrderBy { +"""Methods to use when ordering `ResourceUtilization`.""" +enum ResourceUtilizationOrderBy { AVG_MEMORY_BYTES_ASC AVG_MEMORY_BYTES_DESC CPU_LIMIT_MILLICORES_ASC @@ -24861,6 +25739,49 @@ type UpdateFunctionGraphStorePayload { query: Query } +"""All input for the `updateFunctionInvocationAttempt` mutation.""" +input UpdateFunctionInvocationAttemptInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime! + + """ + An object where the defined keys will be set on the `FunctionInvocationAttempt` being updated. + """ + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch! + + """Unique attempt identifier""" + id: UUID! +} + +"""The output of our update `FunctionInvocationAttempt` mutation.""" +type UpdateFunctionInvocationAttemptPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `FunctionInvocationAttempt` that was updated by this mutation.""" + functionInvocationAttempt: FunctionInvocationAttempt + + """An edge for our `FunctionInvocationAttempt`. May be used by Relay 1.""" + functionInvocationAttemptEdge( + """The method to use when ordering `FunctionInvocationAttempt`.""" + orderBy: [FunctionInvocationAttemptOrderBy!]! = [PRIMARY_KEY_ASC] + ): FunctionInvocationAttemptEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `updateFunctionInvocation` mutation.""" input UpdateFunctionInvocationInput { """ @@ -25398,6 +26319,53 @@ type UpdatePlatformFunctionExecutionLogPayload { query: Query } +"""All input for the `updatePlatformFunctionInvocationAttempt` mutation.""" +input UpdatePlatformFunctionInvocationAttemptInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """When the attempt result was recorded (partition key)""" + createdAt: Datetime! + + """Unique attempt identifier""" + id: UUID! + + """ + An object where the defined keys will be set on the `PlatformFunctionInvocationAttempt` being updated. + """ + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch! +} + +"""The output of our update `PlatformFunctionInvocationAttempt` mutation.""" +type UpdatePlatformFunctionInvocationAttemptPayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + The `PlatformFunctionInvocationAttempt` that was updated by this mutation. + """ + platformFunctionInvocationAttempt: PlatformFunctionInvocationAttempt + + """ + An edge for our `PlatformFunctionInvocationAttempt`. May be used by Relay 1. + """ + platformFunctionInvocationAttemptEdge( + """The method to use when ordering `PlatformFunctionInvocationAttempt`.""" + orderBy: [PlatformFunctionInvocationAttemptOrderBy!]! = [PRIMARY_KEY_ASC] + ): PlatformFunctionInvocationAttemptEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `updatePlatformFunctionInvocation` mutation.""" input UpdatePlatformFunctionInvocationInput { """ diff --git a/sdk/constructive-sdk/schemas/config.graphql b/sdk/constructive-sdk/schemas/config.graphql index f50958001..ba4ef5788 100644 --- a/sdk/constructive-sdk/schemas/config.graphql +++ b/sdk/constructive-sdk/schemas/config.graphql @@ -626,11 +626,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -698,6 +745,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -708,6 +758,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! diff --git a/sdk/constructive-sdk/schemas/infra.graphql b/sdk/constructive-sdk/schemas/infra.graphql index 652a3e301..2e6d966ea 100644 --- a/sdk/constructive-sdk/schemas/infra.graphql +++ b/sdk/constructive-sdk/schemas/infra.graphql @@ -1191,11 +1191,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -1263,6 +1310,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -1273,6 +1323,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! diff --git a/sdk/constructive-sdk/schemas/modules.graphql b/sdk/constructive-sdk/schemas/modules.graphql index 554541ece..a105f322a 100644 --- a/sdk/constructive-sdk/schemas/modules.graphql +++ b/sdk/constructive-sdk/schemas/modules.graphql @@ -346,6 +346,436 @@ input AgentModulePatch { threadTableName: String } +type ApiSurfaceModule { + apiName: String + apisTableId: UUID! + apisTableName: String! + + """ + Reads a single `CatalogModule` that is related to this `ApiSurfaceModule`. + """ + catalogModule: CatalogModule + catalogModuleId: UUID + databaseId: UUID! + defaultPermissions: [String] + entityField: String + entityTableId: UUID + id: UUID! + policies: JSON + prefix: String! + privateApiName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID! + scope: String! +} + +"""A connection to a list of `ApiSurfaceModule` values.""" +type ApiSurfaceModuleConnection { + """ + A list of edges which contains the `ApiSurfaceModule` and cursor to aid in pagination. + """ + edges: [ApiSurfaceModuleEdge]! + + """A list of `ApiSurfaceModule` objects.""" + nodes: [ApiSurfaceModule]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `ApiSurfaceModule` you could get from the connection. + """ + totalCount: Int! +} + +"""A `ApiSurfaceModule` edge in the connection.""" +type ApiSurfaceModuleEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `ApiSurfaceModule` at the end of the edge.""" + node: ApiSurfaceModule +} + +""" +A filter to be used against `ApiSurfaceModule` object types. All fields are combined with a logical ‘and.’ +""" +input ApiSurfaceModuleFilter { + """Checks for all expressions in this list.""" + and: [ApiSurfaceModuleFilter!] + + """Filter by the object’s `apiName` field.""" + apiName: StringFilter + + """Filter by the object’s `apisTableId` field.""" + apisTableId: UUIDFilter + + """Filter by the object’s `apisTableName` field.""" + apisTableName: StringFilter + + """Filter by the object’s `catalogModule` relation.""" + catalogModule: CatalogModuleFilter + + """A related `catalogModule` exists.""" + catalogModuleExists: Boolean + + """Filter by the object’s `catalogModuleId` field.""" + catalogModuleId: UUIDFilter + + """Filter by the object’s `databaseId` field.""" + databaseId: UUIDFilter + + """Filter by the object’s `defaultPermissions` field.""" + defaultPermissions: StringListFilter + + """Filter by the object’s `entityField` field.""" + entityField: StringFilter + + """Filter by the object’s `entityTableId` field.""" + entityTableId: UUIDFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Negates the expression.""" + not: ApiSurfaceModuleFilter + + """Checks for any expressions in this list.""" + or: [ApiSurfaceModuleFilter!] + + """Filter by the object’s `policies` field.""" + policies: JSONFilter + + """Filter by the object’s `prefix` field.""" + prefix: StringFilter + + """Filter by the object’s `privateApiName` field.""" + privateApiName: StringFilter + + """Filter by the object’s `provisions` field.""" + provisions: JSONFilter + + """Filter by the object’s `publicSchemaName` field.""" + publicSchemaName: StringFilter + + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter + + """Filter by the object’s `scope` field.""" + scope: StringFilter +} + +"""An input for mutations affecting `ApiSurfaceModule`""" +input ApiSurfaceModuleInput { + apiName: String + apisTableId: UUID + apisTableName: String + catalogModuleId: UUID + databaseId: UUID! + defaultPermissions: [String] + entityField: String + entityTableId: UUID + id: UUID + policies: JSON + prefix: String + privateApiName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID + scope: String +} + +"""Methods to use when ordering `ApiSurfaceModule`.""" +enum ApiSurfaceModuleOrderBy { + APIS_TABLE_ID_ASC + APIS_TABLE_ID_DESC + APIS_TABLE_NAME_ASC + APIS_TABLE_NAME_DESC + API_NAME_ASC + API_NAME_DESC + CATALOG_MODULE_ID_ASC + CATALOG_MODULE_ID_DESC + DATABASE_ID_ASC + DATABASE_ID_DESC + DEFAULT_PERMISSIONS_ASC + DEFAULT_PERMISSIONS_DESC + ENTITY_FIELD_ASC + ENTITY_FIELD_DESC + ENTITY_TABLE_ID_ASC + ENTITY_TABLE_ID_DESC + ID_ASC + ID_DESC + NATURAL + POLICIES_ASC + POLICIES_DESC + PREFIX_ASC + PREFIX_DESC + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + PRIVATE_API_NAME_ASC + PRIVATE_API_NAME_DESC + PROVISIONS_ASC + PROVISIONS_DESC + PUBLIC_SCHEMA_NAME_ASC + PUBLIC_SCHEMA_NAME_DESC + SCHEMA_ID_ASC + SCHEMA_ID_DESC + SCOPE_ASC + SCOPE_DESC +} + +""" +Represents an update to a `ApiSurfaceModule`. Fields that are set will be updated. +""" +input ApiSurfaceModulePatch { + apiName: String + apisTableId: UUID + apisTableName: String + catalogModuleId: UUID + databaseId: UUID + defaultPermissions: [String] + entityField: String + entityTableId: UUID + id: UUID + policies: JSON + prefix: String + privateApiName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID + scope: String +} + +type AppModule { + apiName: String + appMembersTableId: UUID! + appMembersTableName: String! + appsTableId: UUID! + appsTableName: String! + + """Reads a single `CatalogModule` that is related to this `AppModule`.""" + catalogModule: CatalogModule + catalogModuleId: UUID + databaseId: UUID! + defaultPermissions: [String] + entityField: String + entityTableId: UUID + id: UUID! + policies: JSON + prefix: String! + privateApiName: String + privateSchemaId: UUID! + privateSchemaName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID! + scope: String! +} + +"""A connection to a list of `AppModule` values.""" +type AppModuleConnection { + """ + A list of edges which contains the `AppModule` and cursor to aid in pagination. + """ + edges: [AppModuleEdge]! + + """A list of `AppModule` objects.""" + nodes: [AppModule]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """The count of *all* `AppModule` you could get from the connection.""" + totalCount: Int! +} + +"""A `AppModule` edge in the connection.""" +type AppModuleEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `AppModule` at the end of the edge.""" + node: AppModule +} + +""" +A filter to be used against `AppModule` object types. All fields are combined with a logical ‘and.’ +""" +input AppModuleFilter { + """Checks for all expressions in this list.""" + and: [AppModuleFilter!] + + """Filter by the object’s `apiName` field.""" + apiName: StringFilter + + """Filter by the object’s `appMembersTableId` field.""" + appMembersTableId: UUIDFilter + + """Filter by the object’s `appMembersTableName` field.""" + appMembersTableName: StringFilter + + """Filter by the object’s `appsTableId` field.""" + appsTableId: UUIDFilter + + """Filter by the object’s `appsTableName` field.""" + appsTableName: StringFilter + + """Filter by the object’s `catalogModule` relation.""" + catalogModule: CatalogModuleFilter + + """A related `catalogModule` exists.""" + catalogModuleExists: Boolean + + """Filter by the object’s `catalogModuleId` field.""" + catalogModuleId: UUIDFilter + + """Filter by the object’s `databaseId` field.""" + databaseId: UUIDFilter + + """Filter by the object’s `defaultPermissions` field.""" + defaultPermissions: StringListFilter + + """Filter by the object’s `entityField` field.""" + entityField: StringFilter + + """Filter by the object’s `entityTableId` field.""" + entityTableId: UUIDFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Negates the expression.""" + not: AppModuleFilter + + """Checks for any expressions in this list.""" + or: [AppModuleFilter!] + + """Filter by the object’s `policies` field.""" + policies: JSONFilter + + """Filter by the object’s `prefix` field.""" + prefix: StringFilter + + """Filter by the object’s `privateApiName` field.""" + privateApiName: StringFilter + + """Filter by the object’s `privateSchemaId` field.""" + privateSchemaId: UUIDFilter + + """Filter by the object’s `privateSchemaName` field.""" + privateSchemaName: StringFilter + + """Filter by the object’s `provisions` field.""" + provisions: JSONFilter + + """Filter by the object’s `publicSchemaName` field.""" + publicSchemaName: StringFilter + + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter + + """Filter by the object’s `scope` field.""" + scope: StringFilter +} + +"""An input for mutations affecting `AppModule`""" +input AppModuleInput { + apiName: String + appMembersTableId: UUID + appMembersTableName: String + appsTableId: UUID + appsTableName: String + catalogModuleId: UUID + databaseId: UUID! + defaultPermissions: [String] + entityField: String + entityTableId: UUID + id: UUID + policies: JSON + prefix: String + privateApiName: String + privateSchemaId: UUID + privateSchemaName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID + scope: String +} + +"""Methods to use when ordering `AppModule`.""" +enum AppModuleOrderBy { + API_NAME_ASC + API_NAME_DESC + APPS_TABLE_ID_ASC + APPS_TABLE_ID_DESC + APPS_TABLE_NAME_ASC + APPS_TABLE_NAME_DESC + APP_MEMBERS_TABLE_ID_ASC + APP_MEMBERS_TABLE_ID_DESC + APP_MEMBERS_TABLE_NAME_ASC + APP_MEMBERS_TABLE_NAME_DESC + CATALOG_MODULE_ID_ASC + CATALOG_MODULE_ID_DESC + DATABASE_ID_ASC + DATABASE_ID_DESC + DEFAULT_PERMISSIONS_ASC + DEFAULT_PERMISSIONS_DESC + ENTITY_FIELD_ASC + ENTITY_FIELD_DESC + ENTITY_TABLE_ID_ASC + ENTITY_TABLE_ID_DESC + ID_ASC + ID_DESC + NATURAL + POLICIES_ASC + POLICIES_DESC + PREFIX_ASC + PREFIX_DESC + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + PRIVATE_API_NAME_ASC + PRIVATE_API_NAME_DESC + PRIVATE_SCHEMA_ID_ASC + PRIVATE_SCHEMA_ID_DESC + PRIVATE_SCHEMA_NAME_ASC + PRIVATE_SCHEMA_NAME_DESC + PROVISIONS_ASC + PROVISIONS_DESC + PUBLIC_SCHEMA_NAME_ASC + PUBLIC_SCHEMA_NAME_DESC + SCHEMA_ID_ASC + SCHEMA_ID_DESC + SCOPE_ASC + SCOPE_DESC +} + +""" +Represents an update to a `AppModule`. Fields that are set will be updated. +""" +input AppModulePatch { + apiName: String + appMembersTableId: UUID + appMembersTableName: String + appsTableId: UUID + appsTableName: String + catalogModuleId: UUID + databaseId: UUID + defaultPermissions: [String] + entityField: String + entityTableId: UUID + id: UUID + policies: JSON + prefix: String + privateApiName: String + privateSchemaId: UUID + privateSchemaName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID + scope: String +} + """ A signed eight-byte integer. The upper big integer values are greater than the max value for a JavaScript number. Therefore all big integers will be output as @@ -2025,37 +2455,329 @@ input BooleanFilter { """ distinctFrom: Boolean - """Equal to the specified value.""" - equalTo: Boolean + """Equal to the specified value.""" + equalTo: Boolean + + """Greater than the specified value.""" + greaterThan: Boolean + + """Greater than or equal to the specified value.""" + greaterThanOrEqualTo: Boolean + + """Included in the specified list.""" + in: [Boolean!] + + """ + Is null (if `true` is specified) or is not null (if `false` is specified). + """ + isNull: Boolean + + """Less than the specified value.""" + lessThan: Boolean + + """Less than or equal to the specified value.""" + lessThanOrEqualTo: Boolean + + """Equal to the specified value, treating null like an ordinary value.""" + notDistinctFrom: Boolean + + """Not equal to the specified value.""" + notEqualTo: Boolean + + """Not included in the specified list.""" + notIn: [Boolean!] +} + +type CatalogModule { + apiName: String + apisTableId: UUID! + apisTableName: String! + appsTableId: UUID! + appsTableName: String! + databaseId: UUID! + defaultPermissions: [String] + domainsTableId: UUID! + domainsTableName: String! + entityTableId: UUID + functionsTableId: UUID! + functionsTableName: String! + id: UUID! + namespacesTableId: UUID! + namespacesTableName: String! + policies: JSON + privateApiName: String + provisions: JSON + publicSchemaName: String + resourceDefinitionsTableId: UUID! + resourceDefinitionsTableName: String! + resourceInstallationsTableId: UUID! + resourceInstallationsTableName: String! + resourcesTableId: UUID! + resourcesTableName: String! + schemaId: UUID! + scope: String! + sitesTableId: UUID! + sitesTableName: String! +} + +"""A connection to a list of `CatalogModule` values.""" +type CatalogModuleConnection { + """ + A list of edges which contains the `CatalogModule` and cursor to aid in pagination. + """ + edges: [CatalogModuleEdge]! + + """A list of `CatalogModule` objects.""" + nodes: [CatalogModule]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """The count of *all* `CatalogModule` you could get from the connection.""" + totalCount: Int! +} + +"""A `CatalogModule` edge in the connection.""" +type CatalogModuleEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `CatalogModule` at the end of the edge.""" + node: CatalogModule +} + +""" +A filter to be used against `CatalogModule` object types. All fields are combined with a logical ‘and.’ +""" +input CatalogModuleFilter { + """Checks for all expressions in this list.""" + and: [CatalogModuleFilter!] + + """Filter by the object’s `apiName` field.""" + apiName: StringFilter + + """Filter by the object’s `apisTableId` field.""" + apisTableId: UUIDFilter + + """Filter by the object’s `apisTableName` field.""" + apisTableName: StringFilter + + """Filter by the object’s `appsTableId` field.""" + appsTableId: UUIDFilter + + """Filter by the object’s `appsTableName` field.""" + appsTableName: StringFilter + + """Filter by the object’s `databaseId` field.""" + databaseId: UUIDFilter + + """Filter by the object’s `defaultPermissions` field.""" + defaultPermissions: StringListFilter + + """Filter by the object’s `domainsTableId` field.""" + domainsTableId: UUIDFilter + + """Filter by the object’s `domainsTableName` field.""" + domainsTableName: StringFilter + + """Filter by the object’s `entityTableId` field.""" + entityTableId: UUIDFilter + + """Filter by the object’s `functionsTableId` field.""" + functionsTableId: UUIDFilter + + """Filter by the object’s `functionsTableName` field.""" + functionsTableName: StringFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Filter by the object’s `namespacesTableId` field.""" + namespacesTableId: UUIDFilter + + """Filter by the object’s `namespacesTableName` field.""" + namespacesTableName: StringFilter + + """Negates the expression.""" + not: CatalogModuleFilter + + """Checks for any expressions in this list.""" + or: [CatalogModuleFilter!] + + """Filter by the object’s `policies` field.""" + policies: JSONFilter + + """Filter by the object’s `privateApiName` field.""" + privateApiName: StringFilter + + """Filter by the object’s `provisions` field.""" + provisions: JSONFilter + + """Filter by the object’s `publicSchemaName` field.""" + publicSchemaName: StringFilter + + """Filter by the object’s `resourceDefinitionsTableId` field.""" + resourceDefinitionsTableId: UUIDFilter - """Greater than the specified value.""" - greaterThan: Boolean + """Filter by the object’s `resourceDefinitionsTableName` field.""" + resourceDefinitionsTableName: StringFilter - """Greater than or equal to the specified value.""" - greaterThanOrEqualTo: Boolean + """Filter by the object’s `resourceInstallationsTableId` field.""" + resourceInstallationsTableId: UUIDFilter - """Included in the specified list.""" - in: [Boolean!] + """Filter by the object’s `resourceInstallationsTableName` field.""" + resourceInstallationsTableName: StringFilter - """ - Is null (if `true` is specified) or is not null (if `false` is specified). - """ - isNull: Boolean + """Filter by the object’s `resourcesTableId` field.""" + resourcesTableId: UUIDFilter - """Less than the specified value.""" - lessThan: Boolean + """Filter by the object’s `resourcesTableName` field.""" + resourcesTableName: StringFilter - """Less than or equal to the specified value.""" - lessThanOrEqualTo: Boolean + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter - """Equal to the specified value, treating null like an ordinary value.""" - notDistinctFrom: Boolean + """Filter by the object’s `scope` field.""" + scope: StringFilter - """Not equal to the specified value.""" - notEqualTo: Boolean + """Filter by the object’s `sitesTableId` field.""" + sitesTableId: UUIDFilter - """Not included in the specified list.""" - notIn: [Boolean!] + """Filter by the object’s `sitesTableName` field.""" + sitesTableName: StringFilter +} + +"""An input for mutations affecting `CatalogModule`""" +input CatalogModuleInput { + apiName: String + apisTableId: UUID + apisTableName: String + appsTableId: UUID + appsTableName: String + databaseId: UUID! + defaultPermissions: [String] + domainsTableId: UUID + domainsTableName: String + entityTableId: UUID + functionsTableId: UUID + functionsTableName: String + id: UUID + namespacesTableId: UUID + namespacesTableName: String + policies: JSON + privateApiName: String + provisions: JSON + publicSchemaName: String + resourceDefinitionsTableId: UUID + resourceDefinitionsTableName: String + resourceInstallationsTableId: UUID + resourceInstallationsTableName: String + resourcesTableId: UUID + resourcesTableName: String + schemaId: UUID + scope: String + sitesTableId: UUID + sitesTableName: String +} + +"""Methods to use when ordering `CatalogModule`.""" +enum CatalogModuleOrderBy { + APIS_TABLE_ID_ASC + APIS_TABLE_ID_DESC + APIS_TABLE_NAME_ASC + APIS_TABLE_NAME_DESC + API_NAME_ASC + API_NAME_DESC + APPS_TABLE_ID_ASC + APPS_TABLE_ID_DESC + APPS_TABLE_NAME_ASC + APPS_TABLE_NAME_DESC + DATABASE_ID_ASC + DATABASE_ID_DESC + DEFAULT_PERMISSIONS_ASC + DEFAULT_PERMISSIONS_DESC + DOMAINS_TABLE_ID_ASC + DOMAINS_TABLE_ID_DESC + DOMAINS_TABLE_NAME_ASC + DOMAINS_TABLE_NAME_DESC + ENTITY_TABLE_ID_ASC + ENTITY_TABLE_ID_DESC + FUNCTIONS_TABLE_ID_ASC + FUNCTIONS_TABLE_ID_DESC + FUNCTIONS_TABLE_NAME_ASC + FUNCTIONS_TABLE_NAME_DESC + ID_ASC + ID_DESC + NAMESPACES_TABLE_ID_ASC + NAMESPACES_TABLE_ID_DESC + NAMESPACES_TABLE_NAME_ASC + NAMESPACES_TABLE_NAME_DESC + NATURAL + POLICIES_ASC + POLICIES_DESC + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + PRIVATE_API_NAME_ASC + PRIVATE_API_NAME_DESC + PROVISIONS_ASC + PROVISIONS_DESC + PUBLIC_SCHEMA_NAME_ASC + PUBLIC_SCHEMA_NAME_DESC + RESOURCES_TABLE_ID_ASC + RESOURCES_TABLE_ID_DESC + RESOURCES_TABLE_NAME_ASC + RESOURCES_TABLE_NAME_DESC + RESOURCE_DEFINITIONS_TABLE_ID_ASC + RESOURCE_DEFINITIONS_TABLE_ID_DESC + RESOURCE_DEFINITIONS_TABLE_NAME_ASC + RESOURCE_DEFINITIONS_TABLE_NAME_DESC + RESOURCE_INSTALLATIONS_TABLE_ID_ASC + RESOURCE_INSTALLATIONS_TABLE_ID_DESC + RESOURCE_INSTALLATIONS_TABLE_NAME_ASC + RESOURCE_INSTALLATIONS_TABLE_NAME_DESC + SCHEMA_ID_ASC + SCHEMA_ID_DESC + SCOPE_ASC + SCOPE_DESC + SITES_TABLE_ID_ASC + SITES_TABLE_ID_DESC + SITES_TABLE_NAME_ASC + SITES_TABLE_NAME_DESC +} + +""" +Represents an update to a `CatalogModule`. Fields that are set will be updated. +""" +input CatalogModulePatch { + apiName: String + apisTableId: UUID + apisTableName: String + appsTableId: UUID + appsTableName: String + databaseId: UUID + defaultPermissions: [String] + domainsTableId: UUID + domainsTableName: String + entityTableId: UUID + functionsTableId: UUID + functionsTableName: String + id: UUID + namespacesTableId: UUID + namespacesTableName: String + policies: JSON + privateApiName: String + provisions: JSON + publicSchemaName: String + resourceDefinitionsTableId: UUID + resourceDefinitionsTableName: String + resourceInstallationsTableId: UUID + resourceInstallationsTableName: String + resourcesTableId: UUID + resourcesTableName: String + schemaId: UUID + scope: String + sitesTableId: UUID + sitesTableName: String } type ComputeLogModule { @@ -2631,6 +3353,76 @@ type CreateAgentModulePayload { query: Query } +"""All input for the create `ApiSurfaceModule` mutation.""" +input CreateApiSurfaceModuleInput { + """The `ApiSurfaceModule` to be created by this mutation.""" + apiSurfaceModule: ApiSurfaceModuleInput! + + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String +} + +"""The output of our create `ApiSurfaceModule` mutation.""" +type CreateApiSurfaceModulePayload { + """The `ApiSurfaceModule` that was created by this mutation.""" + apiSurfaceModule: ApiSurfaceModule + + """An edge for our `ApiSurfaceModule`. May be used by Relay 1.""" + apiSurfaceModuleEdge( + """The method to use when ordering `ApiSurfaceModule`.""" + orderBy: [ApiSurfaceModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): ApiSurfaceModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + +"""All input for the create `AppModule` mutation.""" +input CreateAppModuleInput { + """The `AppModule` to be created by this mutation.""" + appModule: AppModuleInput! + + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String +} + +"""The output of our create `AppModule` mutation.""" +type CreateAppModulePayload { + """The `AppModule` that was created by this mutation.""" + appModule: AppModule + + """An edge for our `AppModule`. May be used by Relay 1.""" + appModuleEdge( + """The method to use when ordering `AppModule`.""" + orderBy: [AppModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): AppModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the create `BillingModule` mutation.""" input CreateBillingModuleInput { """The `BillingModule` to be created by this mutation.""" @@ -2806,6 +3598,41 @@ type CreateBlueprintTemplatePayload { query: Query } +"""All input for the create `CatalogModule` mutation.""" +input CreateCatalogModuleInput { + """The `CatalogModule` to be created by this mutation.""" + catalogModule: CatalogModuleInput! + + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String +} + +"""The output of our create `CatalogModule` mutation.""" +type CreateCatalogModulePayload { + """The `CatalogModule` that was created by this mutation.""" + catalogModule: CatalogModule + + """An edge for our `CatalogModule`. May be used by Relay 1.""" + catalogModuleEdge( + """The method to use when ordering `CatalogModule`.""" + orderBy: [CatalogModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): CatalogModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the create `ComputeLogModule` mutation.""" input CreateComputeLogModuleInput { """ @@ -3261,6 +4088,41 @@ type CreateDevicesModulePayload { query: Query } +"""All input for the create `DomainModule` mutation.""" +input CreateDomainModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """The `DomainModule` to be created by this mutation.""" + domainModule: DomainModuleInput! +} + +"""The output of our create `DomainModule` mutation.""" +type CreateDomainModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainModule` that was created by this mutation.""" + domainModule: DomainModule + + """An edge for our `DomainModule`. May be used by Relay 1.""" + domainModuleEdge( + """The method to use when ordering `DomainModule`.""" + orderBy: [DomainModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainModuleEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the create `EmailsModule` mutation.""" input CreateEmailsModuleInput { """ @@ -4486,6 +5348,41 @@ type CreateRlsModulePayload { ): RlsModuleEdge } +"""All input for the create `RouteModule` mutation.""" +input CreateRouteModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """The `RouteModule` to be created by this mutation.""" + routeModule: RouteModuleInput! +} + +"""The output of our create `RouteModule` mutation.""" +type CreateRouteModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query + + """The `RouteModule` that was created by this mutation.""" + routeModule: RouteModule + + """An edge for our `RouteModule`. May be used by Relay 1.""" + routeModuleEdge( + """The method to use when ordering `RouteModule`.""" + orderBy: [RouteModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): RouteModuleEdge +} + """All input for the create `SecureTableProvision` mutation.""" input CreateSecureTableProvisionInput { """ @@ -4591,6 +5488,41 @@ type CreateSessionsModulePayload { ): SessionsModuleEdge } +"""All input for the create `SiteSurfaceModule` mutation.""" +input CreateSiteSurfaceModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """The `SiteSurfaceModule` to be created by this mutation.""" + siteSurfaceModule: SiteSurfaceModuleInput! +} + +"""The output of our create `SiteSurfaceModule` mutation.""" +type CreateSiteSurfaceModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query + + """The `SiteSurfaceModule` that was created by this mutation.""" + siteSurfaceModule: SiteSurfaceModule + + """An edge for our `SiteSurfaceModule`. May be used by Relay 1.""" + siteSurfaceModuleEdge( + """The method to use when ordering `SiteSurfaceModule`.""" + orderBy: [SiteSurfaceModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): SiteSurfaceModuleEdge +} + """All input for the create `StorageLogModule` mutation.""" input CreateStorageLogModuleInput { """ @@ -5299,6 +6231,11 @@ scalar Cursor Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. """ type DatabaseProvisionModule { + """ + When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger + """ + async: Boolean! + """Error message from the most recent failed bootstrap attempt""" bootstrapError: String @@ -5391,6 +6328,9 @@ input DatabaseProvisionModuleFilter { """Checks for all expressions in this list.""" and: [DatabaseProvisionModuleFilter!] + """Filter by the object’s `async` field.""" + async: BooleanFilter + """Filter by the object’s `bootstrapError` field.""" bootstrapError: StringFilter @@ -5454,6 +6394,11 @@ input DatabaseProvisionModuleFilter { """An input for mutations affecting `DatabaseProvisionModule`""" input DatabaseProvisionModuleInput { + """ + When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger + """ + async: Boolean + """Error message from the most recent failed bootstrap attempt""" bootstrapError: String @@ -5513,6 +6458,8 @@ input DatabaseProvisionModuleInput { """Methods to use when ordering `DatabaseProvisionModule`.""" enum DatabaseProvisionModuleOrderBy { + ASYNC_ASC + ASYNC_DESC BOOTSTRAP_ERROR_ASC BOOTSTRAP_ERROR_DESC BOOTSTRAP_STATUS_ASC @@ -5558,6 +6505,11 @@ enum DatabaseProvisionModuleOrderBy { Represents an update to a `DatabaseProvisionModule`. Fields that are set will be updated. """ input DatabaseProvisionModulePatch { + """ + When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger + """ + async: Boolean + """Error message from the most recent failed bootstrap attempt""" bootstrapError: String @@ -6675,6 +7627,72 @@ type DeleteAgentModulePayload { query: Query } +"""All input for the `deleteApiSurfaceModule` mutation.""" +input DeleteApiSurfaceModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our delete `ApiSurfaceModule` mutation.""" +type DeleteApiSurfaceModulePayload { + """The `ApiSurfaceModule` that was deleted by this mutation.""" + apiSurfaceModule: ApiSurfaceModule + + """An edge for our `ApiSurfaceModule`. May be used by Relay 1.""" + apiSurfaceModuleEdge( + """The method to use when ordering `ApiSurfaceModule`.""" + orderBy: [ApiSurfaceModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): ApiSurfaceModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + +"""All input for the `deleteAppModule` mutation.""" +input DeleteAppModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our delete `AppModule` mutation.""" +type DeleteAppModulePayload { + """The `AppModule` that was deleted by this mutation.""" + appModule: AppModule + + """An edge for our `AppModule`. May be used by Relay 1.""" + appModuleEdge( + """The method to use when ordering `AppModule`.""" + orderBy: [AppModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): AppModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `deleteBillingModule` mutation.""" input DeleteBillingModuleInput { """ @@ -6846,6 +7864,39 @@ type DeleteBlueprintTemplatePayload { query: Query } +"""All input for the `deleteCatalogModule` mutation.""" +input DeleteCatalogModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our delete `CatalogModule` mutation.""" +type DeleteCatalogModulePayload { + """The `CatalogModule` that was deleted by this mutation.""" + catalogModule: CatalogModule + + """An edge for our `CatalogModule`. May be used by Relay 1.""" + catalogModuleEdge( + """The method to use when ordering `CatalogModule`.""" + orderBy: [CatalogModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): CatalogModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `deleteComputeLogModule` mutation.""" input DeleteComputeLogModuleInput { """ @@ -7275,6 +8326,39 @@ type DeleteDevicesModulePayload { query: Query } +"""All input for the `deleteDomainModule` mutation.""" +input DeleteDomainModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our delete `DomainModule` mutation.""" +type DeleteDomainModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainModule` that was deleted by this mutation.""" + domainModule: DomainModule + + """An edge for our `DomainModule`. May be used by Relay 1.""" + domainModuleEdge( + """The method to use when ordering `DomainModule`.""" + orderBy: [DomainModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainModuleEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `deleteEmailsModule` mutation.""" input DeleteEmailsModuleInput { """ @@ -8434,6 +9518,39 @@ type DeleteRlsModulePayload { ): RlsModuleEdge } +"""All input for the `deleteRouteModule` mutation.""" +input DeleteRouteModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our delete `RouteModule` mutation.""" +type DeleteRouteModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query + + """The `RouteModule` that was deleted by this mutation.""" + routeModule: RouteModule + + """An edge for our `RouteModule`. May be used by Relay 1.""" + routeModuleEdge( + """The method to use when ordering `RouteModule`.""" + orderBy: [RouteModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): RouteModuleEdge +} + """All input for the `deleteSecureTableProvision` mutation.""" input DeleteSecureTableProvisionInput { """ @@ -8535,6 +9652,39 @@ type DeleteSessionsModulePayload { ): SessionsModuleEdge } +"""All input for the `deleteSiteSurfaceModule` mutation.""" +input DeleteSiteSurfaceModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our delete `SiteSurfaceModule` mutation.""" +type DeleteSiteSurfaceModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query + + """The `SiteSurfaceModule` that was deleted by this mutation.""" + siteSurfaceModule: SiteSurfaceModule + + """An edge for our `SiteSurfaceModule`. May be used by Relay 1.""" + siteSurfaceModuleEdge( + """The method to use when ordering `SiteSurfaceModule`.""" + orderBy: [SiteSurfaceModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): SiteSurfaceModuleEdge +} + """All input for the `deleteStorageLogModule` mutation.""" input DeleteStorageLogModuleInput { """ @@ -9102,74 +10252,303 @@ input DevicesModuleFilter { """Filter by the object’s `databaseId` field.""" databaseId: UUIDFilter - """Filter by the object’s `deviceSettingsTableId` field.""" - deviceSettingsTableId: UUIDFilter + """Filter by the object’s `deviceSettingsTableId` field.""" + deviceSettingsTableId: UUIDFilter + + """Filter by the object’s `deviceSettingsTableName` field.""" + deviceSettingsTableName: StringFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Negates the expression.""" + not: DevicesModuleFilter + + """Checks for any expressions in this list.""" + or: [DevicesModuleFilter!] + + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter + + """Filter by the object’s `userDevicesTableId` field.""" + userDevicesTableId: UUIDFilter + + """Filter by the object’s `userDevicesTableName` field.""" + userDevicesTableName: StringFilter +} + +"""An input for mutations affecting `DevicesModule`""" +input DevicesModuleInput { + databaseId: UUID! + deviceSettingsTableId: UUID + deviceSettingsTableName: String + id: UUID + schemaId: UUID + userDevicesTableId: UUID + userDevicesTableName: String +} + +"""Methods to use when ordering `DevicesModule`.""" +enum DevicesModuleOrderBy { + DATABASE_ID_ASC + DATABASE_ID_DESC + DEVICE_SETTINGS_TABLE_ID_ASC + DEVICE_SETTINGS_TABLE_ID_DESC + DEVICE_SETTINGS_TABLE_NAME_ASC + DEVICE_SETTINGS_TABLE_NAME_DESC + ID_ASC + ID_DESC + NATURAL + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + SCHEMA_ID_ASC + SCHEMA_ID_DESC + USER_DEVICES_TABLE_ID_ASC + USER_DEVICES_TABLE_ID_DESC + USER_DEVICES_TABLE_NAME_ASC + USER_DEVICES_TABLE_NAME_DESC +} + +""" +Represents an update to a `DevicesModule`. Fields that are set will be updated. +""" +input DevicesModulePatch { + databaseId: UUID + deviceSettingsTableId: UUID + deviceSettingsTableName: String + id: UUID + schemaId: UUID + userDevicesTableId: UUID + userDevicesTableName: String +} + +type DomainModule { + apiName: String + + """Reads a single `CatalogModule` that is related to this `DomainModule`.""" + catalogModule: CatalogModule + catalogModuleId: UUID + databaseId: UUID! + defaultPermissions: [String] + domainEventsTableId: UUID! + domainEventsTableName: String! + domainVerificationsTableId: UUID! + domainVerificationsTableName: String! + domainsTableId: UUID! + domainsTableName: String! + entityField: String + entityTableId: UUID + id: UUID! + policies: JSON + prefix: String! + privateApiName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID! + scope: String! +} + +"""A connection to a list of `DomainModule` values.""" +type DomainModuleConnection { + """ + A list of edges which contains the `DomainModule` and cursor to aid in pagination. + """ + edges: [DomainModuleEdge]! + + """A list of `DomainModule` objects.""" + nodes: [DomainModule]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """The count of *all* `DomainModule` you could get from the connection.""" + totalCount: Int! +} + +"""A `DomainModule` edge in the connection.""" +type DomainModuleEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `DomainModule` at the end of the edge.""" + node: DomainModule +} + +""" +A filter to be used against `DomainModule` object types. All fields are combined with a logical ‘and.’ +""" +input DomainModuleFilter { + """Checks for all expressions in this list.""" + and: [DomainModuleFilter!] + + """Filter by the object’s `apiName` field.""" + apiName: StringFilter + + """Filter by the object’s `catalogModule` relation.""" + catalogModule: CatalogModuleFilter + + """A related `catalogModule` exists.""" + catalogModuleExists: Boolean + + """Filter by the object’s `catalogModuleId` field.""" + catalogModuleId: UUIDFilter + + """Filter by the object’s `databaseId` field.""" + databaseId: UUIDFilter + + """Filter by the object’s `defaultPermissions` field.""" + defaultPermissions: StringListFilter - """Filter by the object’s `deviceSettingsTableName` field.""" - deviceSettingsTableName: StringFilter + """Filter by the object’s `domainEventsTableId` field.""" + domainEventsTableId: UUIDFilter + + """Filter by the object’s `domainEventsTableName` field.""" + domainEventsTableName: StringFilter + + """Filter by the object’s `domainVerificationsTableId` field.""" + domainVerificationsTableId: UUIDFilter + + """Filter by the object’s `domainVerificationsTableName` field.""" + domainVerificationsTableName: StringFilter + + """Filter by the object’s `domainsTableId` field.""" + domainsTableId: UUIDFilter + + """Filter by the object’s `domainsTableName` field.""" + domainsTableName: StringFilter + + """Filter by the object’s `entityField` field.""" + entityField: StringFilter + + """Filter by the object’s `entityTableId` field.""" + entityTableId: UUIDFilter """Filter by the object’s `id` field.""" id: UUIDFilter """Negates the expression.""" - not: DevicesModuleFilter + not: DomainModuleFilter """Checks for any expressions in this list.""" - or: [DevicesModuleFilter!] + or: [DomainModuleFilter!] + + """Filter by the object’s `policies` field.""" + policies: JSONFilter + + """Filter by the object’s `prefix` field.""" + prefix: StringFilter + + """Filter by the object’s `privateApiName` field.""" + privateApiName: StringFilter + + """Filter by the object’s `provisions` field.""" + provisions: JSONFilter + + """Filter by the object’s `publicSchemaName` field.""" + publicSchemaName: StringFilter """Filter by the object’s `schemaId` field.""" schemaId: UUIDFilter - """Filter by the object’s `userDevicesTableId` field.""" - userDevicesTableId: UUIDFilter - - """Filter by the object’s `userDevicesTableName` field.""" - userDevicesTableName: StringFilter + """Filter by the object’s `scope` field.""" + scope: StringFilter } -"""An input for mutations affecting `DevicesModule`""" -input DevicesModuleInput { +"""An input for mutations affecting `DomainModule`""" +input DomainModuleInput { + apiName: String + catalogModuleId: UUID databaseId: UUID! - deviceSettingsTableId: UUID - deviceSettingsTableName: String + defaultPermissions: [String] + domainEventsTableId: UUID + domainEventsTableName: String + domainVerificationsTableId: UUID + domainVerificationsTableName: String + domainsTableId: UUID + domainsTableName: String + entityField: String + entityTableId: UUID id: UUID + policies: JSON + prefix: String + privateApiName: String + provisions: JSON + publicSchemaName: String schemaId: UUID - userDevicesTableId: UUID - userDevicesTableName: String + scope: String } -"""Methods to use when ordering `DevicesModule`.""" -enum DevicesModuleOrderBy { +"""Methods to use when ordering `DomainModule`.""" +enum DomainModuleOrderBy { + API_NAME_ASC + API_NAME_DESC + CATALOG_MODULE_ID_ASC + CATALOG_MODULE_ID_DESC DATABASE_ID_ASC DATABASE_ID_DESC - DEVICE_SETTINGS_TABLE_ID_ASC - DEVICE_SETTINGS_TABLE_ID_DESC - DEVICE_SETTINGS_TABLE_NAME_ASC - DEVICE_SETTINGS_TABLE_NAME_DESC + DEFAULT_PERMISSIONS_ASC + DEFAULT_PERMISSIONS_DESC + DOMAINS_TABLE_ID_ASC + DOMAINS_TABLE_ID_DESC + DOMAINS_TABLE_NAME_ASC + DOMAINS_TABLE_NAME_DESC + DOMAIN_EVENTS_TABLE_ID_ASC + DOMAIN_EVENTS_TABLE_ID_DESC + DOMAIN_EVENTS_TABLE_NAME_ASC + DOMAIN_EVENTS_TABLE_NAME_DESC + DOMAIN_VERIFICATIONS_TABLE_ID_ASC + DOMAIN_VERIFICATIONS_TABLE_ID_DESC + DOMAIN_VERIFICATIONS_TABLE_NAME_ASC + DOMAIN_VERIFICATIONS_TABLE_NAME_DESC + ENTITY_FIELD_ASC + ENTITY_FIELD_DESC + ENTITY_TABLE_ID_ASC + ENTITY_TABLE_ID_DESC ID_ASC ID_DESC NATURAL + POLICIES_ASC + POLICIES_DESC + PREFIX_ASC + PREFIX_DESC PRIMARY_KEY_ASC PRIMARY_KEY_DESC + PRIVATE_API_NAME_ASC + PRIVATE_API_NAME_DESC + PROVISIONS_ASC + PROVISIONS_DESC + PUBLIC_SCHEMA_NAME_ASC + PUBLIC_SCHEMA_NAME_DESC SCHEMA_ID_ASC SCHEMA_ID_DESC - USER_DEVICES_TABLE_ID_ASC - USER_DEVICES_TABLE_ID_DESC - USER_DEVICES_TABLE_NAME_ASC - USER_DEVICES_TABLE_NAME_DESC + SCOPE_ASC + SCOPE_DESC } """ -Represents an update to a `DevicesModule`. Fields that are set will be updated. +Represents an update to a `DomainModule`. Fields that are set will be updated. """ -input DevicesModulePatch { +input DomainModulePatch { + apiName: String + catalogModuleId: UUID databaseId: UUID - deviceSettingsTableId: UUID - deviceSettingsTableName: String + defaultPermissions: [String] + domainEventsTableId: UUID + domainEventsTableName: String + domainVerificationsTableId: UUID + domainVerificationsTableName: String + domainsTableId: UUID + domainsTableName: String + entityField: String + entityTableId: UUID id: UUID + policies: JSON + prefix: String + privateApiName: String + provisions: JSON + publicSchemaName: String schemaId: UUID - userDevicesTableId: UUID - userDevicesTableName: String + scope: String } type EmailsModule { @@ -11104,6 +12483,8 @@ input FunctionDeploymentModulePatch { type FunctionInvocationModule { apiName: String + attemptsTableId: UUID! + attemptsTableName: String! databaseId: UUID! defaultPermissions: [String] entityField: String @@ -11162,6 +12543,12 @@ input FunctionInvocationModuleFilter { """Filter by the object’s `apiName` field.""" apiName: StringFilter + """Filter by the object’s `attemptsTableId` field.""" + attemptsTableId: UUIDFilter + + """Filter by the object’s `attemptsTableName` field.""" + attemptsTableName: StringFilter + """Filter by the object’s `databaseId` field.""" databaseId: UUIDFilter @@ -11226,6 +12613,8 @@ input FunctionInvocationModuleFilter { """An input for mutations affecting `FunctionInvocationModule`""" input FunctionInvocationModuleInput { apiName: String + attemptsTableId: UUID + attemptsTableName: String databaseId: UUID! defaultPermissions: [String] entityField: String @@ -11250,6 +12639,10 @@ input FunctionInvocationModuleInput { enum FunctionInvocationModuleOrderBy { API_NAME_ASC API_NAME_DESC + ATTEMPTS_TABLE_ID_ASC + ATTEMPTS_TABLE_ID_DESC + ATTEMPTS_TABLE_NAME_ASC + ATTEMPTS_TABLE_NAME_DESC DATABASE_ID_ASC DATABASE_ID_DESC DEFAULT_PERMISSIONS_ASC @@ -11296,6 +12689,8 @@ Represents an update to a `FunctionInvocationModule`. Fields that are set will b """ input FunctionInvocationModulePatch { apiName: String + attemptsTableId: UUID + attemptsTableName: String databaseId: UUID defaultPermissions: [String] entityField: String @@ -15599,11 +16994,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -15671,6 +17113,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -15681,6 +17126,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! @@ -15727,6 +17174,22 @@ type Mutation { input: CreateAgentModuleInput! ): CreateAgentModulePayload + """Creates a single `ApiSurfaceModule`.""" + createApiSurfaceModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateApiSurfaceModuleInput! + ): CreateApiSurfaceModulePayload + + """Creates a single `AppModule`.""" + createAppModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateAppModuleInput! + ): CreateAppModulePayload + """Creates a single `BillingModule`.""" createBillingModule( """ @@ -15767,6 +17230,14 @@ type Mutation { input: CreateBlueprintTemplateInput! ): CreateBlueprintTemplatePayload + """Creates a single `CatalogModule`.""" + createCatalogModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateCatalogModuleInput! + ): CreateCatalogModulePayload + """Creates a single `ComputeLogModule`.""" createComputeLogModule( """ @@ -15871,6 +17342,14 @@ type Mutation { input: CreateDevicesModuleInput! ): CreateDevicesModulePayload + """Creates a single `DomainModule`.""" + createDomainModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateDomainModuleInput! + ): CreateDomainModulePayload + """Creates a single `EmailsModule`.""" createEmailsModule( """ @@ -16151,6 +17630,14 @@ type Mutation { input: CreateRlsModuleInput! ): CreateRlsModulePayload + """Creates a single `RouteModule`.""" + createRouteModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateRouteModuleInput! + ): CreateRouteModulePayload + """Creates a single `SecureTableProvision`.""" createSecureTableProvision( """ @@ -16175,6 +17662,14 @@ type Mutation { input: CreateSessionsModuleInput! ): CreateSessionsModulePayload + """Creates a single `SiteSurfaceModule`.""" + createSiteSurfaceModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: CreateSiteSurfaceModuleInput! + ): CreateSiteSurfaceModulePayload + """Creates a single `StorageLogModule`.""" createStorageLogModule( """ @@ -16271,6 +17766,22 @@ type Mutation { input: DeleteAgentModuleInput! ): DeleteAgentModulePayload + """Deletes a single `ApiSurfaceModule` using a unique key.""" + deleteApiSurfaceModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteApiSurfaceModuleInput! + ): DeleteApiSurfaceModulePayload + + """Deletes a single `AppModule` using a unique key.""" + deleteAppModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteAppModuleInput! + ): DeleteAppModulePayload + """Deletes a single `BillingModule` using a unique key.""" deleteBillingModule( """ @@ -16311,6 +17822,14 @@ type Mutation { input: DeleteBlueprintTemplateInput! ): DeleteBlueprintTemplatePayload + """Deletes a single `CatalogModule` using a unique key.""" + deleteCatalogModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteCatalogModuleInput! + ): DeleteCatalogModulePayload + """Deletes a single `ComputeLogModule` using a unique key.""" deleteComputeLogModule( """ @@ -16415,6 +17934,14 @@ type Mutation { input: DeleteDevicesModuleInput! ): DeleteDevicesModulePayload + """Deletes a single `DomainModule` using a unique key.""" + deleteDomainModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteDomainModuleInput! + ): DeleteDomainModulePayload + """Deletes a single `EmailsModule` using a unique key.""" deleteEmailsModule( """ @@ -16695,6 +18222,14 @@ type Mutation { input: DeleteRlsModuleInput! ): DeleteRlsModulePayload + """Deletes a single `RouteModule` using a unique key.""" + deleteRouteModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteRouteModuleInput! + ): DeleteRouteModulePayload + """Deletes a single `SecureTableProvision` using a unique key.""" deleteSecureTableProvision( """ @@ -16719,6 +18254,14 @@ type Mutation { input: DeleteSessionsModuleInput! ): DeleteSessionsModulePayload + """Deletes a single `SiteSurfaceModule` using a unique key.""" + deleteSiteSurfaceModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: DeleteSiteSurfaceModuleInput! + ): DeleteSiteSurfaceModulePayload + """Deletes a single `StorageLogModule` using a unique key.""" deleteStorageLogModule( """ @@ -16898,6 +18441,22 @@ type Mutation { input: UpdateAgentModuleInput! ): UpdateAgentModulePayload + """Updates a single `ApiSurfaceModule` using a unique key and a patch.""" + updateApiSurfaceModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateApiSurfaceModuleInput! + ): UpdateApiSurfaceModulePayload + + """Updates a single `AppModule` using a unique key and a patch.""" + updateAppModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateAppModuleInput! + ): UpdateAppModulePayload + """Updates a single `BillingModule` using a unique key and a patch.""" updateBillingModule( """ @@ -16942,6 +18501,14 @@ type Mutation { input: UpdateBlueprintTemplateInput! ): UpdateBlueprintTemplatePayload + """Updates a single `CatalogModule` using a unique key and a patch.""" + updateCatalogModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateCatalogModuleInput! + ): UpdateCatalogModulePayload + """Updates a single `ComputeLogModule` using a unique key and a patch.""" updateComputeLogModule( """ @@ -17056,6 +18623,14 @@ type Mutation { input: UpdateDevicesModuleInput! ): UpdateDevicesModulePayload + """Updates a single `DomainModule` using a unique key and a patch.""" + updateDomainModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateDomainModuleInput! + ): UpdateDomainModulePayload + """Updates a single `EmailsModule` using a unique key and a patch.""" updateEmailsModule( """ @@ -17352,6 +18927,14 @@ type Mutation { input: UpdateRlsModuleInput! ): UpdateRlsModulePayload + """Updates a single `RouteModule` using a unique key and a patch.""" + updateRouteModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateRouteModuleInput! + ): UpdateRouteModulePayload + """ Updates a single `SecureTableProvision` using a unique key and a patch. """ @@ -17380,6 +18963,14 @@ type Mutation { input: UpdateSessionsModuleInput! ): UpdateSessionsModulePayload + """Updates a single `SiteSurfaceModule` using a unique key and a patch.""" + updateSiteSurfaceModule( + """ + The exclusive input argument for this mutation. An object type, make sure to see documentation for this object’s fields. + """ + input: UpdateSiteSurfaceModuleInput! + ): UpdateSiteSurfaceModulePayload + """Updates a single `StorageLogModule` using a unique key and a patch.""" updateStorageLogModule( """ @@ -19194,14 +20785,14 @@ input ProvisionSpatialRelationInput { payload verbatim. May be used to track mutations by the client. """ clientMutationId: String - pDatabaseId: UUID - pName: String - pOperator: String - pParamName: String - pSourceFieldId: UUID - pSourceTableId: UUID - pTargetFieldId: UUID - pTargetTableId: UUID + databaseId: UUID + name: String + operator: String + paramName: String + sourceFieldId: UUID + sourceTableId: UUID + targetFieldId: UUID + targetTableId: UUID } """The output of our `provisionSpatialRelation` mutation.""" @@ -19314,14 +20905,72 @@ type Query { """ offset: Int - """The method to use when ordering `AgentModule`.""" - orderBy: [AgentModuleOrderBy!] = [PRIMARY_KEY_ASC] + """The method to use when ordering `AgentModule`.""" + orderBy: [AgentModuleOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: AgentModuleFilter + ): AgentModuleConnection + + """Reads and enables pagination through a set of `ApiSurfaceModule`.""" + apiSurfaceModules( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `ApiSurfaceModule`.""" + orderBy: [ApiSurfaceModuleOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: ApiSurfaceModuleFilter + ): ApiSurfaceModuleConnection + + """Reads and enables pagination through a set of `AppModule`.""" + appModules( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `AppModule`.""" + orderBy: [AppModuleOrderBy!] = [PRIMARY_KEY_ASC] """ A filter to be used in determining which values should be returned by the collection. """ - where: AgentModuleFilter - ): AgentModuleConnection + where: AppModuleFilter + ): AppModuleConnection """Reads and enables pagination through a set of `BillingModule`.""" billingModules( @@ -19468,6 +21117,35 @@ type Query { where: BlueprintFilter ): BlueprintConnection + """Reads and enables pagination through a set of `CatalogModule`.""" + catalogModules( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `CatalogModule`.""" + orderBy: [CatalogModuleOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: CatalogModuleFilter + ): CatalogModuleConnection + """Reads and enables pagination through a set of `ComputeLogModule`.""" computeLogModules( """Read all values in the set after (below) this cursor.""" @@ -19853,6 +21531,35 @@ type Query { where: DevicesModuleFilter ): DevicesModuleConnection + """Reads and enables pagination through a set of `DomainModule`.""" + domainModules( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `DomainModule`.""" + orderBy: [DomainModuleOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: DomainModuleFilter + ): DomainModuleConnection + """Reads and enables pagination through a set of `EmailsModule`.""" emailsModules( """Read all values in the set after (below) this cursor.""" @@ -20886,6 +22593,35 @@ type Query { where: RlsModuleFilter ): RlsModuleConnection + """Reads and enables pagination through a set of `RouteModule`.""" + routeModules( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `RouteModule`.""" + orderBy: [RouteModuleOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: RouteModuleFilter + ): RouteModuleConnection + """Reads and enables pagination through a set of `SecureTableProvision`.""" secureTableProvisions( """Read all values in the set after (below) this cursor.""" @@ -20973,6 +22709,35 @@ type Query { where: SessionsModuleFilter ): SessionsModuleConnection + """Reads and enables pagination through a set of `SiteSurfaceModule`.""" + siteSurfaceModules( + """Read all values in the set after (below) this cursor.""" + after: Cursor + + """Read all values in the set before (above) this cursor.""" + before: Cursor + + """Only read the first `n` values of the set.""" + first: Int + + """Only read the last `n` values of the set.""" + last: Int + + """ + Skip the first `n` values from our `after` cursor, an alternative to cursor + based pagination. May not be used with `last`. + """ + offset: Int + + """The method to use when ordering `SiteSurfaceModule`.""" + orderBy: [SiteSurfaceModuleOrderBy!] = [PRIMARY_KEY_ASC] + + """ + A filter to be used in determining which values should be returned by the collection. + """ + where: SiteSurfaceModuleFilter + ): SiteSurfaceModuleConnection + """Reads and enables pagination through a set of `StorageLogModule`.""" storageLogModules( """Read all values in the set after (below) this cursor.""" @@ -22941,86 +24706,356 @@ input RlsModuleFilter { """Filter by the object’s `privateSchemaId` field.""" privateSchemaId: UUIDFilter - """Filter by the object’s `schemaId` field.""" - schemaId: UUIDFilter + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter + + """Filter by the object’s `sessionCredentialsTableId` field.""" + sessionCredentialsTableId: UUIDFilter + + """Filter by the object’s `sessionsTableId` field.""" + sessionsTableId: UUIDFilter + + """Filter by the object’s `usersTableId` field.""" + usersTableId: UUIDFilter +} + +"""An input for mutations affecting `RlsModule`""" +input RlsModuleInput { + apiName: String + authenticate: String + authenticateStrict: String + currentRole: String + currentRoleId: String + databaseId: UUID! + id: UUID + privateApiName: String + privateSchemaId: UUID + schemaId: UUID + sessionCredentialsTableId: UUID + sessionsTableId: UUID + usersTableId: UUID +} + +"""Methods to use when ordering `RlsModule`.""" +enum RlsModuleOrderBy { + API_NAME_ASC + API_NAME_DESC + AUTHENTICATE_ASC + AUTHENTICATE_DESC + AUTHENTICATE_STRICT_ASC + AUTHENTICATE_STRICT_DESC + CURRENT_ROLE_ASC + CURRENT_ROLE_DESC + CURRENT_ROLE_ID_ASC + CURRENT_ROLE_ID_DESC + DATABASE_ID_ASC + DATABASE_ID_DESC + ID_ASC + ID_DESC + NATURAL + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + PRIVATE_API_NAME_ASC + PRIVATE_API_NAME_DESC + PRIVATE_SCHEMA_ID_ASC + PRIVATE_SCHEMA_ID_DESC + SCHEMA_ID_ASC + SCHEMA_ID_DESC + SESSIONS_TABLE_ID_ASC + SESSIONS_TABLE_ID_DESC + SESSION_CREDENTIALS_TABLE_ID_ASC + SESSION_CREDENTIALS_TABLE_ID_DESC + USERS_TABLE_ID_ASC + USERS_TABLE_ID_DESC +} + +""" +Represents an update to a `RlsModule`. Fields that are set will be updated. +""" +input RlsModulePatch { + apiName: String + authenticate: String + authenticateStrict: String + currentRole: String + currentRoleId: String + databaseId: UUID + id: UUID + privateApiName: String + privateSchemaId: UUID + schemaId: UUID + sessionCredentialsTableId: UUID + sessionsTableId: UUID + usersTableId: UUID +} + +type RouteModule { + apiName: String + + """Reads a single `CatalogModule` that is related to this `RouteModule`.""" + catalogModule: CatalogModule + catalogModuleId: UUID + databaseId: UUID! + defaultPermissions: [String] + + """Reads a single `DomainModule` that is related to this `RouteModule`.""" + domainModule: DomainModule + domainModuleId: UUID + entityField: String + entityTableId: UUID + hostnameBindingsTableId: UUID! + hostnameBindingsTableName: String! + id: UUID! + policies: JSON + prefix: String! + privateApiName: String + privateSchemaId: UUID! + privateSchemaName: String + provisions: JSON + publicSchemaName: String + resolverFunctionName: String + routeBindingsTableId: UUID! + routeBindingsTableName: String! + routesTableId: UUID! + routesTableName: String! + schemaId: UUID! + scope: String! +} + +"""A connection to a list of `RouteModule` values.""" +type RouteModuleConnection { + """ + A list of edges which contains the `RouteModule` and cursor to aid in pagination. + """ + edges: [RouteModuleEdge]! + + """A list of `RouteModule` objects.""" + nodes: [RouteModule]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """The count of *all* `RouteModule` you could get from the connection.""" + totalCount: Int! +} + +"""A `RouteModule` edge in the connection.""" +type RouteModuleEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `RouteModule` at the end of the edge.""" + node: RouteModule +} + +""" +A filter to be used against `RouteModule` object types. All fields are combined with a logical ‘and.’ +""" +input RouteModuleFilter { + """Checks for all expressions in this list.""" + and: [RouteModuleFilter!] + + """Filter by the object’s `apiName` field.""" + apiName: StringFilter + + """Filter by the object’s `catalogModule` relation.""" + catalogModule: CatalogModuleFilter + + """A related `catalogModule` exists.""" + catalogModuleExists: Boolean + + """Filter by the object’s `catalogModuleId` field.""" + catalogModuleId: UUIDFilter + + """Filter by the object’s `databaseId` field.""" + databaseId: UUIDFilter + + """Filter by the object’s `defaultPermissions` field.""" + defaultPermissions: StringListFilter + + """Filter by the object’s `domainModule` relation.""" + domainModule: DomainModuleFilter + + """A related `domainModule` exists.""" + domainModuleExists: Boolean + + """Filter by the object’s `domainModuleId` field.""" + domainModuleId: UUIDFilter + + """Filter by the object’s `entityField` field.""" + entityField: StringFilter + + """Filter by the object’s `entityTableId` field.""" + entityTableId: UUIDFilter + + """Filter by the object’s `hostnameBindingsTableId` field.""" + hostnameBindingsTableId: UUIDFilter + + """Filter by the object’s `hostnameBindingsTableName` field.""" + hostnameBindingsTableName: StringFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Negates the expression.""" + not: RouteModuleFilter + + """Checks for any expressions in this list.""" + or: [RouteModuleFilter!] + + """Filter by the object’s `policies` field.""" + policies: JSONFilter + + """Filter by the object’s `prefix` field.""" + prefix: StringFilter + + """Filter by the object’s `privateApiName` field.""" + privateApiName: StringFilter + + """Filter by the object’s `privateSchemaId` field.""" + privateSchemaId: UUIDFilter + + """Filter by the object’s `privateSchemaName` field.""" + privateSchemaName: StringFilter - """Filter by the object’s `sessionCredentialsTableId` field.""" - sessionCredentialsTableId: UUIDFilter + """Filter by the object’s `provisions` field.""" + provisions: JSONFilter - """Filter by the object’s `sessionsTableId` field.""" - sessionsTableId: UUIDFilter + """Filter by the object’s `publicSchemaName` field.""" + publicSchemaName: StringFilter - """Filter by the object’s `usersTableId` field.""" - usersTableId: UUIDFilter + """Filter by the object’s `resolverFunctionName` field.""" + resolverFunctionName: StringFilter + + """Filter by the object’s `routeBindingsTableId` field.""" + routeBindingsTableId: UUIDFilter + + """Filter by the object’s `routeBindingsTableName` field.""" + routeBindingsTableName: StringFilter + + """Filter by the object’s `routesTableId` field.""" + routesTableId: UUIDFilter + + """Filter by the object’s `routesTableName` field.""" + routesTableName: StringFilter + + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter + + """Filter by the object’s `scope` field.""" + scope: StringFilter } -"""An input for mutations affecting `RlsModule`""" -input RlsModuleInput { +"""An input for mutations affecting `RouteModule`""" +input RouteModuleInput { apiName: String - authenticate: String - authenticateStrict: String - currentRole: String - currentRoleId: String + catalogModuleId: UUID databaseId: UUID! + defaultPermissions: [String] + domainModuleId: UUID + entityField: String + entityTableId: UUID + hostnameBindingsTableId: UUID + hostnameBindingsTableName: String id: UUID + policies: JSON + prefix: String privateApiName: String privateSchemaId: UUID + privateSchemaName: String + provisions: JSON + publicSchemaName: String + resolverFunctionName: String + routeBindingsTableId: UUID + routeBindingsTableName: String + routesTableId: UUID + routesTableName: String schemaId: UUID - sessionCredentialsTableId: UUID - sessionsTableId: UUID - usersTableId: UUID + scope: String } -"""Methods to use when ordering `RlsModule`.""" -enum RlsModuleOrderBy { +"""Methods to use when ordering `RouteModule`.""" +enum RouteModuleOrderBy { API_NAME_ASC API_NAME_DESC - AUTHENTICATE_ASC - AUTHENTICATE_DESC - AUTHENTICATE_STRICT_ASC - AUTHENTICATE_STRICT_DESC - CURRENT_ROLE_ASC - CURRENT_ROLE_DESC - CURRENT_ROLE_ID_ASC - CURRENT_ROLE_ID_DESC + CATALOG_MODULE_ID_ASC + CATALOG_MODULE_ID_DESC DATABASE_ID_ASC DATABASE_ID_DESC + DEFAULT_PERMISSIONS_ASC + DEFAULT_PERMISSIONS_DESC + DOMAIN_MODULE_ID_ASC + DOMAIN_MODULE_ID_DESC + ENTITY_FIELD_ASC + ENTITY_FIELD_DESC + ENTITY_TABLE_ID_ASC + ENTITY_TABLE_ID_DESC + HOSTNAME_BINDINGS_TABLE_ID_ASC + HOSTNAME_BINDINGS_TABLE_ID_DESC + HOSTNAME_BINDINGS_TABLE_NAME_ASC + HOSTNAME_BINDINGS_TABLE_NAME_DESC ID_ASC ID_DESC NATURAL + POLICIES_ASC + POLICIES_DESC + PREFIX_ASC + PREFIX_DESC PRIMARY_KEY_ASC PRIMARY_KEY_DESC PRIVATE_API_NAME_ASC PRIVATE_API_NAME_DESC PRIVATE_SCHEMA_ID_ASC PRIVATE_SCHEMA_ID_DESC + PRIVATE_SCHEMA_NAME_ASC + PRIVATE_SCHEMA_NAME_DESC + PROVISIONS_ASC + PROVISIONS_DESC + PUBLIC_SCHEMA_NAME_ASC + PUBLIC_SCHEMA_NAME_DESC + RESOLVER_FUNCTION_NAME_ASC + RESOLVER_FUNCTION_NAME_DESC + ROUTES_TABLE_ID_ASC + ROUTES_TABLE_ID_DESC + ROUTES_TABLE_NAME_ASC + ROUTES_TABLE_NAME_DESC + ROUTE_BINDINGS_TABLE_ID_ASC + ROUTE_BINDINGS_TABLE_ID_DESC + ROUTE_BINDINGS_TABLE_NAME_ASC + ROUTE_BINDINGS_TABLE_NAME_DESC SCHEMA_ID_ASC SCHEMA_ID_DESC - SESSIONS_TABLE_ID_ASC - SESSIONS_TABLE_ID_DESC - SESSION_CREDENTIALS_TABLE_ID_ASC - SESSION_CREDENTIALS_TABLE_ID_DESC - USERS_TABLE_ID_ASC - USERS_TABLE_ID_DESC + SCOPE_ASC + SCOPE_DESC } """ -Represents an update to a `RlsModule`. Fields that are set will be updated. +Represents an update to a `RouteModule`. Fields that are set will be updated. """ -input RlsModulePatch { +input RouteModulePatch { apiName: String - authenticate: String - authenticateStrict: String - currentRole: String - currentRoleId: String + catalogModuleId: UUID databaseId: UUID + defaultPermissions: [String] + domainModuleId: UUID + entityField: String + entityTableId: UUID + hostnameBindingsTableId: UUID + hostnameBindingsTableName: String id: UUID + policies: JSON + prefix: String privateApiName: String privateSchemaId: UUID + privateSchemaName: String + provisions: JSON + publicSchemaName: String + resolverFunctionName: String + routeBindingsTableId: UUID + routeBindingsTableName: String + routesTableId: UUID + routesTableName: String schemaId: UUID - sessionCredentialsTableId: UUID - sessionsTableId: UUID - usersTableId: UUID + scope: String } """ @@ -23480,90 +25515,291 @@ input SessionsModuleFilter { """Negates the expression.""" not: SessionsModuleFilter - """Checks for any expressions in this list.""" - or: [SessionsModuleFilter!] + """Checks for any expressions in this list.""" + or: [SessionsModuleFilter!] + + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter + + """Filter by the object’s `sessionCredentialsTableId` field.""" + sessionCredentialsTableId: UUIDFilter + + """Filter by the object’s `sessionCredentialsTableName` field.""" + sessionCredentialsTableName: StringFilter + + """Filter by the object’s `sessionsDefaultExpiration` field.""" + sessionsDefaultExpiration: IntervalFilter + + """Filter by the object’s `sessionsTableId` field.""" + sessionsTableId: UUIDFilter + + """Filter by the object’s `sessionsTableName` field.""" + sessionsTableName: StringFilter + + """Filter by the object’s `usersTableId` field.""" + usersTableId: UUIDFilter +} + +"""An input for mutations affecting `SessionsModule`""" +input SessionsModuleInput { + authSettingsTableId: UUID + authSettingsTableName: String + databaseId: UUID! + id: UUID + schemaId: UUID + sessionCredentialsTableId: UUID + sessionCredentialsTableName: String + sessionsDefaultExpiration: IntervalInput + sessionsTableId: UUID + sessionsTableName: String + usersTableId: UUID +} + +"""Methods to use when ordering `SessionsModule`.""" +enum SessionsModuleOrderBy { + AUTH_SETTINGS_TABLE_ID_ASC + AUTH_SETTINGS_TABLE_ID_DESC + AUTH_SETTINGS_TABLE_NAME_ASC + AUTH_SETTINGS_TABLE_NAME_DESC + DATABASE_ID_ASC + DATABASE_ID_DESC + ID_ASC + ID_DESC + NATURAL + PRIMARY_KEY_ASC + PRIMARY_KEY_DESC + SCHEMA_ID_ASC + SCHEMA_ID_DESC + SESSIONS_DEFAULT_EXPIRATION_ASC + SESSIONS_DEFAULT_EXPIRATION_DESC + SESSIONS_TABLE_ID_ASC + SESSIONS_TABLE_ID_DESC + SESSIONS_TABLE_NAME_ASC + SESSIONS_TABLE_NAME_DESC + SESSION_CREDENTIALS_TABLE_ID_ASC + SESSION_CREDENTIALS_TABLE_ID_DESC + SESSION_CREDENTIALS_TABLE_NAME_ASC + SESSION_CREDENTIALS_TABLE_NAME_DESC + USERS_TABLE_ID_ASC + USERS_TABLE_ID_DESC +} + +""" +Represents an update to a `SessionsModule`. Fields that are set will be updated. +""" +input SessionsModulePatch { + authSettingsTableId: UUID + authSettingsTableName: String + databaseId: UUID + id: UUID + schemaId: UUID + sessionCredentialsTableId: UUID + sessionCredentialsTableName: String + sessionsDefaultExpiration: IntervalInput + sessionsTableId: UUID + sessionsTableName: String + usersTableId: UUID +} + +type SiteSurfaceModule { + apiName: String + + """ + Reads a single `CatalogModule` that is related to this `SiteSurfaceModule`. + """ + catalogModule: CatalogModule + catalogModuleId: UUID + databaseId: UUID! + defaultPermissions: [String] + entityField: String + entityTableId: UUID + id: UUID! + policies: JSON + prefix: String! + privateApiName: String + provisions: JSON + publicSchemaName: String + schemaId: UUID! + scope: String! + sitesTableId: UUID! + sitesTableName: String! +} + +"""A connection to a list of `SiteSurfaceModule` values.""" +type SiteSurfaceModuleConnection { + """ + A list of edges which contains the `SiteSurfaceModule` and cursor to aid in pagination. + """ + edges: [SiteSurfaceModuleEdge]! + + """A list of `SiteSurfaceModule` objects.""" + nodes: [SiteSurfaceModule]! + + """Information to aid in pagination.""" + pageInfo: PageInfo! + + """ + The count of *all* `SiteSurfaceModule` you could get from the connection. + """ + totalCount: Int! +} + +"""A `SiteSurfaceModule` edge in the connection.""" +type SiteSurfaceModuleEdge { + """A cursor for use in pagination.""" + cursor: Cursor + + """The `SiteSurfaceModule` at the end of the edge.""" + node: SiteSurfaceModule +} + +""" +A filter to be used against `SiteSurfaceModule` object types. All fields are combined with a logical ‘and.’ +""" +input SiteSurfaceModuleFilter { + """Checks for all expressions in this list.""" + and: [SiteSurfaceModuleFilter!] + + """Filter by the object’s `apiName` field.""" + apiName: StringFilter + + """Filter by the object’s `catalogModule` relation.""" + catalogModule: CatalogModuleFilter + + """A related `catalogModule` exists.""" + catalogModuleExists: Boolean + + """Filter by the object’s `catalogModuleId` field.""" + catalogModuleId: UUIDFilter + + """Filter by the object’s `databaseId` field.""" + databaseId: UUIDFilter + + """Filter by the object’s `defaultPermissions` field.""" + defaultPermissions: StringListFilter + + """Filter by the object’s `entityField` field.""" + entityField: StringFilter + + """Filter by the object’s `entityTableId` field.""" + entityTableId: UUIDFilter + + """Filter by the object’s `id` field.""" + id: UUIDFilter + + """Negates the expression.""" + not: SiteSurfaceModuleFilter + + """Checks for any expressions in this list.""" + or: [SiteSurfaceModuleFilter!] + + """Filter by the object’s `policies` field.""" + policies: JSONFilter + + """Filter by the object’s `prefix` field.""" + prefix: StringFilter - """Filter by the object’s `schemaId` field.""" - schemaId: UUIDFilter + """Filter by the object’s `privateApiName` field.""" + privateApiName: StringFilter - """Filter by the object’s `sessionCredentialsTableId` field.""" - sessionCredentialsTableId: UUIDFilter + """Filter by the object’s `provisions` field.""" + provisions: JSONFilter - """Filter by the object’s `sessionCredentialsTableName` field.""" - sessionCredentialsTableName: StringFilter + """Filter by the object’s `publicSchemaName` field.""" + publicSchemaName: StringFilter - """Filter by the object’s `sessionsDefaultExpiration` field.""" - sessionsDefaultExpiration: IntervalFilter + """Filter by the object’s `schemaId` field.""" + schemaId: UUIDFilter - """Filter by the object’s `sessionsTableId` field.""" - sessionsTableId: UUIDFilter + """Filter by the object’s `scope` field.""" + scope: StringFilter - """Filter by the object’s `sessionsTableName` field.""" - sessionsTableName: StringFilter + """Filter by the object’s `sitesTableId` field.""" + sitesTableId: UUIDFilter - """Filter by the object’s `usersTableId` field.""" - usersTableId: UUIDFilter + """Filter by the object’s `sitesTableName` field.""" + sitesTableName: StringFilter } -"""An input for mutations affecting `SessionsModule`""" -input SessionsModuleInput { - authSettingsTableId: UUID - authSettingsTableName: String +"""An input for mutations affecting `SiteSurfaceModule`""" +input SiteSurfaceModuleInput { + apiName: String + catalogModuleId: UUID databaseId: UUID! + defaultPermissions: [String] + entityField: String + entityTableId: UUID id: UUID + policies: JSON + prefix: String + privateApiName: String + provisions: JSON + publicSchemaName: String schemaId: UUID - sessionCredentialsTableId: UUID - sessionCredentialsTableName: String - sessionsDefaultExpiration: IntervalInput - sessionsTableId: UUID - sessionsTableName: String - usersTableId: UUID + scope: String + sitesTableId: UUID + sitesTableName: String } -"""Methods to use when ordering `SessionsModule`.""" -enum SessionsModuleOrderBy { - AUTH_SETTINGS_TABLE_ID_ASC - AUTH_SETTINGS_TABLE_ID_DESC - AUTH_SETTINGS_TABLE_NAME_ASC - AUTH_SETTINGS_TABLE_NAME_DESC +"""Methods to use when ordering `SiteSurfaceModule`.""" +enum SiteSurfaceModuleOrderBy { + API_NAME_ASC + API_NAME_DESC + CATALOG_MODULE_ID_ASC + CATALOG_MODULE_ID_DESC DATABASE_ID_ASC DATABASE_ID_DESC + DEFAULT_PERMISSIONS_ASC + DEFAULT_PERMISSIONS_DESC + ENTITY_FIELD_ASC + ENTITY_FIELD_DESC + ENTITY_TABLE_ID_ASC + ENTITY_TABLE_ID_DESC ID_ASC ID_DESC NATURAL + POLICIES_ASC + POLICIES_DESC + PREFIX_ASC + PREFIX_DESC PRIMARY_KEY_ASC PRIMARY_KEY_DESC + PRIVATE_API_NAME_ASC + PRIVATE_API_NAME_DESC + PROVISIONS_ASC + PROVISIONS_DESC + PUBLIC_SCHEMA_NAME_ASC + PUBLIC_SCHEMA_NAME_DESC SCHEMA_ID_ASC SCHEMA_ID_DESC - SESSIONS_DEFAULT_EXPIRATION_ASC - SESSIONS_DEFAULT_EXPIRATION_DESC - SESSIONS_TABLE_ID_ASC - SESSIONS_TABLE_ID_DESC - SESSIONS_TABLE_NAME_ASC - SESSIONS_TABLE_NAME_DESC - SESSION_CREDENTIALS_TABLE_ID_ASC - SESSION_CREDENTIALS_TABLE_ID_DESC - SESSION_CREDENTIALS_TABLE_NAME_ASC - SESSION_CREDENTIALS_TABLE_NAME_DESC - USERS_TABLE_ID_ASC - USERS_TABLE_ID_DESC + SCOPE_ASC + SCOPE_DESC + SITES_TABLE_ID_ASC + SITES_TABLE_ID_DESC + SITES_TABLE_NAME_ASC + SITES_TABLE_NAME_DESC } """ -Represents an update to a `SessionsModule`. Fields that are set will be updated. +Represents an update to a `SiteSurfaceModule`. Fields that are set will be updated. """ -input SessionsModulePatch { - authSettingsTableId: UUID - authSettingsTableName: String +input SiteSurfaceModulePatch { + apiName: String + catalogModuleId: UUID databaseId: UUID + defaultPermissions: [String] + entityField: String + entityTableId: UUID id: UUID + policies: JSON + prefix: String + privateApiName: String + provisions: JSON + publicSchemaName: String schemaId: UUID - sessionCredentialsTableId: UUID - sessionCredentialsTableName: String - sessionsDefaultExpiration: IntervalInput - sessionsTableId: UUID - sessionsTableName: String - usersTableId: UUID + scope: String + sitesTableId: UUID + sitesTableName: String } type StorageLogModule { @@ -24733,6 +26969,82 @@ type UpdateAgentModulePayload { query: Query } +"""All input for the `updateApiSurfaceModule` mutation.""" +input UpdateApiSurfaceModuleInput { + """ + An object where the defined keys will be set on the `ApiSurfaceModule` being updated. + """ + apiSurfaceModulePatch: ApiSurfaceModulePatch! + + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our update `ApiSurfaceModule` mutation.""" +type UpdateApiSurfaceModulePayload { + """The `ApiSurfaceModule` that was updated by this mutation.""" + apiSurfaceModule: ApiSurfaceModule + + """An edge for our `ApiSurfaceModule`. May be used by Relay 1.""" + apiSurfaceModuleEdge( + """The method to use when ordering `ApiSurfaceModule`.""" + orderBy: [ApiSurfaceModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): ApiSurfaceModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + +"""All input for the `updateAppModule` mutation.""" +input UpdateAppModuleInput { + """ + An object where the defined keys will be set on the `AppModule` being updated. + """ + appModulePatch: AppModulePatch! + + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our update `AppModule` mutation.""" +type UpdateAppModulePayload { + """The `AppModule` that was updated by this mutation.""" + appModule: AppModule + + """An edge for our `AppModule`. May be used by Relay 1.""" + appModuleEdge( + """The method to use when ordering `AppModule`.""" + orderBy: [AppModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): AppModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `updateBillingModule` mutation.""" input UpdateBillingModuleInput { """ @@ -24929,6 +27241,44 @@ type UpdateBlueprintTemplatePayload { query: Query } +"""All input for the `updateCatalogModule` mutation.""" +input UpdateCatalogModuleInput { + """ + An object where the defined keys will be set on the `CatalogModule` being updated. + """ + catalogModulePatch: CatalogModulePatch! + + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! +} + +"""The output of our update `CatalogModule` mutation.""" +type UpdateCatalogModulePayload { + """The `CatalogModule` that was updated by this mutation.""" + catalogModule: CatalogModule + + """An edge for our `CatalogModule`. May be used by Relay 1.""" + catalogModuleEdge( + """The method to use when ordering `CatalogModule`.""" + orderBy: [CatalogModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): CatalogModuleEdge + + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `updateComputeLogModule` mutation.""" input UpdateComputeLogModuleInput { """ @@ -25423,6 +27773,44 @@ type UpdateDevicesModulePayload { query: Query } +"""All input for the `updateDomainModule` mutation.""" +input UpdateDomainModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + + """ + An object where the defined keys will be set on the `DomainModule` being updated. + """ + domainModulePatch: DomainModulePatch! + id: UUID! +} + +"""The output of our update `DomainModule` mutation.""" +type UpdateDomainModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """The `DomainModule` that was updated by this mutation.""" + domainModule: DomainModule + + """An edge for our `DomainModule`. May be used by Relay 1.""" + domainModuleEdge( + """The method to use when ordering `DomainModule`.""" + orderBy: [DomainModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): DomainModuleEdge + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query +} + """All input for the `updateEmailsModule` mutation.""" input UpdateEmailsModuleInput { """ @@ -26757,6 +29145,44 @@ type UpdateRlsModulePayload { ): RlsModuleEdge } +"""All input for the `updateRouteModule` mutation.""" +input UpdateRouteModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! + + """ + An object where the defined keys will be set on the `RouteModule` being updated. + """ + routeModulePatch: RouteModulePatch! +} + +"""The output of our update `RouteModule` mutation.""" +type UpdateRouteModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query + + """The `RouteModule` that was updated by this mutation.""" + routeModule: RouteModule + + """An edge for our `RouteModule`. May be used by Relay 1.""" + routeModuleEdge( + """The method to use when ordering `RouteModule`.""" + orderBy: [RouteModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): RouteModuleEdge +} + """All input for the `updateSecureTableProvision` mutation.""" input UpdateSecureTableProvisionInput { """ @@ -26873,6 +29299,44 @@ type UpdateSessionsModulePayload { ): SessionsModuleEdge } +"""All input for the `updateSiteSurfaceModule` mutation.""" +input UpdateSiteSurfaceModuleInput { + """ + An arbitrary string value with no semantic meaning. Will be included in the + payload verbatim. May be used to track mutations by the client. + """ + clientMutationId: String + id: UUID! + + """ + An object where the defined keys will be set on the `SiteSurfaceModule` being updated. + """ + siteSurfaceModulePatch: SiteSurfaceModulePatch! +} + +"""The output of our update `SiteSurfaceModule` mutation.""" +type UpdateSiteSurfaceModulePayload { + """ + The exact same `clientMutationId` that was provided in the mutation input, + unchanged and unused. May be used by a client to track mutations. + """ + clientMutationId: String + + """ + Our root query field type. Allows us to run any query from our mutation payload. + """ + query: Query + + """The `SiteSurfaceModule` that was updated by this mutation.""" + siteSurfaceModule: SiteSurfaceModule + + """An edge for our `SiteSurfaceModule`. May be used by Relay 1.""" + siteSurfaceModuleEdge( + """The method to use when ordering `SiteSurfaceModule`.""" + orderBy: [SiteSurfaceModuleOrderBy!]! = [PRIMARY_KEY_ASC] + ): SiteSurfaceModuleEdge +} + """All input for the `updateStorageLogModule` mutation.""" input UpdateStorageLogModuleInput { """ diff --git a/sdk/constructive-sdk/schemas/objects.graphql b/sdk/constructive-sdk/schemas/objects.graphql index c4abda9cb..9a431254d 100644 --- a/sdk/constructive-sdk/schemas/objects.graphql +++ b/sdk/constructive-sdk/schemas/objects.graphql @@ -825,11 +825,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -897,6 +944,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -907,6 +957,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! diff --git a/sdk/constructive-sdk/schemas/usage.graphql b/sdk/constructive-sdk/schemas/usage.graphql index a321ff57d..a2931b55d 100644 --- a/sdk/constructive-sdk/schemas/usage.graphql +++ b/sdk/constructive-sdk/schemas/usage.graphql @@ -3392,11 +3392,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -3464,6 +3511,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -3474,6 +3524,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean! diff --git a/sdk/constructive-sdk/src/admin/orm/README.md b/sdk/constructive-sdk/src/admin/orm/README.md index af0e170ff..c5a36159a 100644 --- a/sdk/constructive-sdk/src/admin/orm/README.md +++ b/sdk/constructive-sdk/src/admin/orm/README.md @@ -1196,13 +1196,13 @@ orgIsManagerOf | Argument | Type | |----------|------| - | `pEntityId` | UUID | - | `pManagerId` | UUID | - | `pMaxDepth` | Int | - | `pUserId` | UUID | + | `managerId` | UUID | + | `maxDepth` | Int | + | `targetEntityId` | UUID | + | `userId` | UUID | ```typescript -const result = await db.query.orgIsManagerOf({ pEntityId: '', pManagerId: '', pMaxDepth: '', pUserId: '' }).execute(); +const result = await db.query.orgIsManagerOf({ managerId: '', maxDepth: '', targetEntityId: '', userId: '' }).execute(); ``` ### `db.query.orgPermissionsGetByMask` diff --git a/sdk/constructive-sdk/src/admin/orm/query/index.ts b/sdk/constructive-sdk/src/admin/orm/query/index.ts index 79642089b..6d5f48130 100644 --- a/sdk/constructive-sdk/src/admin/orm/query/index.ts +++ b/sdk/constructive-sdk/src/admin/orm/query/index.ts @@ -30,10 +30,10 @@ export interface AppPermissionsGetPaddedMaskVariables { mask?: string; } export interface OrgIsManagerOfVariables { - pEntityId?: string; - pManagerId?: string; - pMaxDepth?: number; - pUserId?: string; + managerId?: string; + maxDepth?: number; + targetEntityId?: string; + userId?: string; } export interface OrgPermissionsGetByMaskVariables { /** Read all values in the set after (below) this cursor. */ @@ -207,19 +207,19 @@ export function createQueryOperations(client: OrmClient) { args, [ { - name: 'pEntityId', + name: 'managerId', type: 'UUID', }, { - name: 'pManagerId', - type: 'UUID', + name: 'maxDepth', + type: 'Int', }, { - name: 'pMaxDepth', - type: 'Int', + name: 'targetEntityId', + type: 'UUID', }, { - name: 'pUserId', + name: 'userId', type: 'UUID', }, ], diff --git a/sdk/constructive-sdk/src/api/README.md b/sdk/constructive-sdk/src/api/README.md index d50648dcb..ec44e18c3 100644 --- a/sdk/constructive-sdk/src/api/README.md +++ b/sdk/constructive-sdk/src/api/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 47 +- **Tables:** 49 - **Custom queries:** 2 - **Custom mutations:** 7 diff --git a/sdk/constructive-sdk/src/api/orm/README.md b/sdk/constructive-sdk/src/api/orm/README.md index eaebbb607..05e83f6ea 100644 --- a/sdk/constructive-sdk/src/api/orm/README.md +++ b/sdk/constructive-sdk/src/api/orm/README.md @@ -35,6 +35,8 @@ const db = createClient({ | `databaseTransfer` | findMany, findOne, create, update, delete | | `defaultPrivilege` | findMany, findOne, create, update, delete | | `domain` | findMany, findOne, create, update, delete | +| `domainEvent` | findMany, findOne, create, update, delete | +| `domainVerification` | findMany, findOne, create, update, delete | | `embeddingChunk` | findMany, findOne, create, update, delete | | `enum` | findMany, findOne, create, update, delete | | `field` | findMany, findOne, create, update, delete | @@ -601,6 +603,86 @@ const updated = await db.domain.update({ where: { id: '' }, data: { annota const deleted = await db.domain.delete({ where: { id: '' } }).execute(); ``` +### `db.domainEvent` + +CRUD operations for DomainEvent records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `createdAt` | Datetime | No | +| `domainVerificationId` | UUID | Yes | +| `eventType` | String | Yes | +| `id` | UUID | No | +| `managedDomainId` | UUID | Yes | +| `message` | String | Yes | +| `metadata` | JSON | Yes | +| `ownerId` | UUID | Yes | + +**Operations:** + +```typescript +// List all domainEvent records +const items = await db.domainEvent.findMany({ select: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }).execute(); + +// Get one by id +const item = await db.domainEvent.findOne({ id: '', select: { actorId: true, createdAt: true, domainVerificationId: true, eventType: true, id: true, managedDomainId: true, message: true, metadata: true, ownerId: true } }).execute(); + +// Create +const created = await db.domainEvent.create({ data: { actorId: '', domainVerificationId: '', eventType: '', managedDomainId: '', message: '', metadata: '', ownerId: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainEvent.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainEvent.delete({ where: { id: '' } }).execute(); +``` + +### `db.domainVerification` + +CRUD operations for DomainVerification records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `attempts` | Int | Yes | +| `createdAt` | Datetime | No | +| `error` | String | Yes | +| `expiresAt` | Datetime | Yes | +| `id` | UUID | No | +| `lastCheckedAt` | Datetime | Yes | +| `managedDomainId` | UUID | Yes | +| `method` | String | Yes | +| `ownerId` | UUID | Yes | +| `recordName` | String | Yes | +| `recordType` | String | Yes | +| `recordValue` | String | Yes | +| `status` | String | Yes | +| `updatedAt` | Datetime | No | +| `verifiedAt` | Datetime | Yes | + +**Operations:** + +```typescript +// List all domainVerification records +const items = await db.domainVerification.findMany({ select: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }).execute(); + +// Get one by id +const item = await db.domainVerification.findOne({ id: '', select: { attempts: true, createdAt: true, error: true, expiresAt: true, id: true, lastCheckedAt: true, managedDomainId: true, method: true, ownerId: true, recordName: true, recordType: true, recordValue: true, status: true, updatedAt: true, verifiedAt: true } }).execute(); + +// Create +const created = await db.domainVerification.create({ data: { attempts: '', error: '', expiresAt: '', lastCheckedAt: '', managedDomainId: '', method: '', ownerId: '', recordName: '', recordType: '', recordValue: '', status: '', verifiedAt: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainVerification.update({ where: { id: '' }, data: { attempts: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainVerification.delete({ where: { id: '' } }).execute(); +``` + ### `db.embeddingChunk` CRUD operations for EmbeddingChunk records. @@ -947,7 +1029,9 @@ CRUD operations for ManagedDomain records. | Field | Type | Editable | |-------|------|----------| +| `allowPublicUsage` | Boolean | Yes | | `annotations` | JSON | Yes | +| `certStatus` | String | Yes | | `databaseId` | UUID | Yes | | `domain` | ConstructiveInternalTypeHostname | Yes | | `id` | UUID | No | @@ -961,16 +1045,16 @@ CRUD operations for ManagedDomain records. ```typescript // List all managedDomain records -const items = await db.managedDomain.findMany({ select: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); +const items = await db.managedDomain.findMany({ select: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); // Get one by id -const item = await db.managedDomain.findOne({ id: '', select: { annotations: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); +const item = await db.managedDomain.findOne({ id: '', select: { allowPublicUsage: true, annotations: true, certStatus: true, databaseId: true, domain: true, id: true, isWildcard: true, tlsReadyAt: true, tlsStatus: true, verificationStatus: true, verifiedAt: true } }).execute(); // Create -const created = await db.managedDomain.create({ data: { annotations: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute(); +const created = await db.managedDomain.create({ data: { allowPublicUsage: '', annotations: '', certStatus: '', databaseId: '', domain: '', isWildcard: '', tlsReadyAt: '', tlsStatus: '', verificationStatus: '', verifiedAt: '' }, select: { id: true } }).execute(); // Update -const updated = await db.managedDomain.update({ where: { id: '' }, data: { annotations: '' }, select: { id: true } }).execute(); +const updated = await db.managedDomain.update({ where: { id: '' }, data: { allowPublicUsage: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.managedDomain.delete({ where: { id: '' } }).execute(); @@ -1922,12 +2006,12 @@ resolveHttpRoute | Argument | Type | |----------|------| - | `pHost` | String | - | `pMethod` | String | - | `pPath` | String | + | `requestHost` | String | + | `requestMethod` | String | + | `requestPath` | String | ```typescript -const result = await db.query.resolveHttpRoute({ pHost: '', pMethod: '', pPath: '' }).execute(); +const result = await db.query.resolveHttpRoute({ requestHost: '', requestMethod: '', requestPath: '' }).execute(); ``` ### `db.mutation.acceptDatabaseTransfer` @@ -2012,7 +2096,7 @@ const result = await db.mutation.rejectDatabaseTransfer({ input: { transferId: ' Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-sdk/src/api/orm/index.ts b/sdk/constructive-sdk/src/api/orm/index.ts index bc2913d21..4d3130d87 100644 --- a/sdk/constructive-sdk/src/api/orm/index.ts +++ b/sdk/constructive-sdk/src/api/orm/index.ts @@ -19,6 +19,8 @@ import { DatabaseSettingModel } from './models/databaseSetting'; import { DatabaseTransferModel } from './models/databaseTransfer'; import { DefaultPrivilegeModel } from './models/defaultPrivilege'; import { DomainModel } from './models/domain'; +import { DomainEventModel } from './models/domainEvent'; +import { DomainVerificationModel } from './models/domainVerification'; import { EmbeddingChunkModel } from './models/embeddingChunk'; import { EnumModel } from './models/enum'; import { FieldModel } from './models/field'; @@ -101,6 +103,8 @@ export function createClient(config: OrmClientConfig) { databaseTransfer: new DatabaseTransferModel(client), defaultPrivilege: new DefaultPrivilegeModel(client), domain: new DomainModel(client), + domainEvent: new DomainEventModel(client), + domainVerification: new DomainVerificationModel(client), embeddingChunk: new EmbeddingChunkModel(client), enum: new EnumModel(client), field: new FieldModel(client), diff --git a/sdk/constructive-sdk/src/api/orm/input-types.ts b/sdk/constructive-sdk/src/api/orm/input-types.ts index b4c236a86..1180c3e08 100644 --- a/sdk/constructive-sdk/src/api/orm/input-types.ts +++ b/sdk/constructive-sdk/src/api/orm/input-types.ts @@ -486,6 +486,60 @@ export interface Domain { /** Subdomain portion of the hostname */ subdomain?: ConstructiveInternalTypeHostname | null; } +/** Append-only audit trail of the domain verify->DNS->issue lifecycle, mirroring resource_events / cluster_events. One row per state transition emitted by the domain:* functions. */ +export interface DomainEvent { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string | null; + /** Event timestamp */ + createdAt?: string | null; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string | null; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType?: string | null; + /** Unique event identifier */ + id: string; + /** The managed_domain this event belongs to */ + managedDomainId?: string | null; + /** Human-readable description of the event */ + message?: string | null; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: Record | null; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId?: string | null; +} +/** One row per outstanding/completed ownership-verification challenge for a managed_domain. Holds the PUBLIC challenge the user must publish (e.g. a DNS TXT record value) — this is a verification token, NOT a secret. Entity-owned via owner_id and read/written through the AuthzEntityMembership scoped-module security path gated on manage_domains. */ +export interface DomainVerification { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number | null; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string | null; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string | null; + /** When this challenge expires and must be reissued */ + expiresAt?: string | null; + /** Unique identifier for this verification challenge */ + id: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string | null; + /** The managed_domain this challenge proves ownership of */ + managedDomainId?: string | null; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string | null; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId?: string | null; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string | null; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string | null; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string | null; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string | null; + /** When this row was last updated */ + updatedAt?: string | null; + /** When status last became verified */ + verifiedAt?: string | null; +} export interface EmbeddingChunk { chunkOverlap?: number | null; chunkSize?: number | null; @@ -627,8 +681,12 @@ export interface Index { } /** One row per cert-bearing host or wildcard; tracks domain verification and TLS provisioning independently of services_public.domains. Reconcilers match a route's root domain to a row here by string (no FK/coupling in v1) */ export interface ManagedDomain { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean | null; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: Record | null; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string | null; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId?: string | null; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -639,9 +697,9 @@ export interface ManagedDomain { isWildcard?: boolean | null; /** When tls_status last became active */ tlsReadyAt?: string | null; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string | null; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string | null; /** When verification_status last became verified */ verifiedAt?: string | null; @@ -1128,6 +1186,14 @@ export interface DomainRelations { site?: Site | null; httpRoutes?: ConnectionResult; } +export interface DomainEventRelations { + domainVerification?: DomainVerification | null; + managedDomain?: ManagedDomain | null; +} +export interface DomainVerificationRelations { + managedDomain?: ManagedDomain | null; + domainEvents?: ConnectionResult; +} export interface EmbeddingChunkRelations { chunksTable?: Table | null; database?: Database | null; @@ -1167,6 +1233,8 @@ export interface IndexRelations { } export interface ManagedDomainRelations { database?: Database | null; + domainEvents?: ConnectionResult; + domainVerifications?: ConnectionResult; } export interface NodeTypeRegistryRelations {} export interface PartitionRelations { @@ -1329,6 +1397,8 @@ export type DatabaseSettingWithRelations = DatabaseSetting & DatabaseSettingRela export type DatabaseTransferWithRelations = DatabaseTransfer & DatabaseTransferRelations; export type DefaultPrivilegeWithRelations = DefaultPrivilege & DefaultPrivilegeRelations; export type DomainWithRelations = Domain & DomainRelations; +export type DomainEventWithRelations = DomainEvent & DomainEventRelations; +export type DomainVerificationWithRelations = DomainVerification & DomainVerificationRelations; export type EmbeddingChunkWithRelations = EmbeddingChunk & EmbeddingChunkRelations; export type EnumWithRelations = Enum & EnumRelations; export type FieldWithRelations = Field & FieldRelations; @@ -1873,6 +1943,49 @@ export type DomainSelect = { orderBy?: HttpRouteOrderBy[]; }; }; +export type DomainEventSelect = { + actorId?: boolean; + createdAt?: boolean; + domainVerificationId?: boolean; + eventType?: boolean; + id?: boolean; + managedDomainId?: boolean; + message?: boolean; + metadata?: boolean; + ownerId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + managedDomain?: { + select: ManagedDomainSelect; + }; +}; +export type DomainVerificationSelect = { + attempts?: boolean; + createdAt?: boolean; + error?: boolean; + expiresAt?: boolean; + id?: boolean; + lastCheckedAt?: boolean; + managedDomainId?: boolean; + method?: boolean; + ownerId?: boolean; + recordName?: boolean; + recordType?: boolean; + recordValue?: boolean; + status?: boolean; + updatedAt?: boolean; + verifiedAt?: boolean; + managedDomain?: { + select: ManagedDomainSelect; + }; + domainEvents?: { + select: DomainEventSelect; + first?: number; + filter?: DomainEventFilter; + orderBy?: DomainEventOrderBy[]; + }; +}; export type EmbeddingChunkSelect = { chunkOverlap?: boolean; chunkSize?: boolean; @@ -2073,7 +2186,9 @@ export type IndexSelect = { }; }; export type ManagedDomainSelect = { + allowPublicUsage?: boolean; annotations?: boolean; + certStatus?: boolean; databaseId?: boolean; domain?: boolean; id?: boolean; @@ -2085,6 +2200,18 @@ export type ManagedDomainSelect = { database?: { select: DatabaseSelect; }; + domainEvents?: { + select: DomainEventSelect; + first?: number; + filter?: DomainEventFilter; + orderBy?: DomainEventOrderBy[]; + }; + domainVerifications?: { + select: DomainVerificationSelect; + first?: number; + filter?: DomainVerificationFilter; + orderBy?: DomainVerificationOrderBy[]; + }; }; export type NodeTypeRegistrySelect = { category?: boolean; @@ -3405,6 +3532,82 @@ export interface DomainFilter { /** Filter by the object’s `subdomain` field. */ subdomain?: ConstructiveInternalTypeHostnameFilter; } +export interface DomainEventFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: DomainEventFilter[]; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainVerification` relation. */ + domainVerification?: DomainVerificationFilter; + /** A related `domainVerification` exists. */ + domainVerificationExists?: boolean; + /** Filter by the object’s `domainVerificationId` field. */ + domainVerificationId?: UUIDFilter; + /** Filter by the object’s `eventType` field. */ + eventType?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `message` field. */ + message?: StringFilter; + /** Filter by the object’s `metadata` field. */ + metadata?: JSONFilter; + /** Negates the expression. */ + not?: DomainEventFilter; + /** Checks for any expressions in this list. */ + or?: DomainEventFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; +} +export interface DomainVerificationFilter { + /** Checks for all expressions in this list. */ + and?: DomainVerificationFilter[]; + /** Filter by the object’s `attempts` field. */ + attempts?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: DomainVerificationToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `expiresAt` field. */ + expiresAt?: DatetimeFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `lastCheckedAt` field. */ + lastCheckedAt?: DatetimeFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `method` field. */ + method?: StringFilter; + /** Negates the expression. */ + not?: DomainVerificationFilter; + /** Checks for any expressions in this list. */ + or?: DomainVerificationFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; + /** Filter by the object’s `recordName` field. */ + recordName?: StringFilter; + /** Filter by the object’s `recordType` field. */ + recordType?: StringFilter; + /** Filter by the object’s `recordValue` field. */ + recordValue?: StringFilter; + /** Filter by the object’s `status` field. */ + status?: StringFilter; + /** Filter by the object’s `updatedAt` field. */ + updatedAt?: DatetimeFilter; + /** Filter by the object’s `verifiedAt` field. */ + verifiedAt?: DatetimeFilter; +} export interface EmbeddingChunkFilter { /** Checks for all expressions in this list. */ and?: EmbeddingChunkFilter[]; @@ -3750,16 +3953,28 @@ export interface IndexFilter { whereClause?: JSONFilter; } export interface ManagedDomainFilter { + /** Filter by the object’s `allowPublicUsage` field. */ + allowPublicUsage?: BooleanFilter; /** Checks for all expressions in this list. */ and?: ManagedDomainFilter[]; /** Filter by the object’s `annotations` field. */ annotations?: JSONFilter; + /** Filter by the object’s `certStatus` field. */ + certStatus?: StringFilter; /** Filter by the object’s `database` relation. */ database?: DatabaseFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `domain` field. */ domain?: ConstructiveInternalTypeHostnameFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: ManagedDomainToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `domainVerifications` relation. */ + domainVerifications?: ManagedDomainToManyDomainVerificationFilter; + /** `domainVerifications` exist. */ + domainVerificationsExist?: boolean; /** Filter by the object’s `id` field. */ id?: UUIDFilter; /** Filter by the object’s `isWildcard` field. */ @@ -5104,6 +5319,62 @@ export type DomainOrderBy = | 'SITE_ID_DESC' | 'SUBDOMAIN_ASC' | 'SUBDOMAIN_DESC'; +export type DomainEventOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DOMAIN_VERIFICATION_ID_ASC' + | 'DOMAIN_VERIFICATION_ID_DESC' + | 'EVENT_TYPE_ASC' + | 'EVENT_TYPE_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'MESSAGE_ASC' + | 'MESSAGE_DESC' + | 'METADATA_ASC' + | 'METADATA_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC'; +export type DomainVerificationOrderBy = + | 'ATTEMPTS_ASC' + | 'ATTEMPTS_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'EXPIRES_AT_ASC' + | 'EXPIRES_AT_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'LAST_CHECKED_AT_ASC' + | 'LAST_CHECKED_AT_DESC' + | 'MANAGED_DOMAIN_ID_ASC' + | 'MANAGED_DOMAIN_ID_DESC' + | 'METHOD_ASC' + | 'METHOD_DESC' + | 'NATURAL' + | 'OWNER_ID_ASC' + | 'OWNER_ID_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'RECORD_NAME_ASC' + | 'RECORD_NAME_DESC' + | 'RECORD_TYPE_ASC' + | 'RECORD_TYPE_DESC' + | 'RECORD_VALUE_ASC' + | 'RECORD_VALUE_DESC' + | 'STATUS_ASC' + | 'STATUS_DESC' + | 'UPDATED_AT_ASC' + | 'UPDATED_AT_DESC' + | 'VERIFIED_AT_ASC' + | 'VERIFIED_AT_DESC'; export type EmbeddingChunkOrderBy = | 'CHUNKING_TASK_NAME_ASC' | 'CHUNKING_TASK_NAME_DESC' @@ -5365,8 +5636,12 @@ export type IndexOrderBy = | 'WHERE_CLAUSE_ASC' | 'WHERE_CLAUSE_DESC'; export type ManagedDomainOrderBy = + | 'ALLOW_PUBLIC_USAGE_ASC' + | 'ALLOW_PUBLIC_USAGE_DESC' | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' + | 'CERT_STATUS_ASC' + | 'CERT_STATUS_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DOMAIN_ASC' @@ -6434,6 +6709,76 @@ export interface DeleteDomainInput { clientMutationId?: string; id: string; } +export interface CreateDomainEventInput { + clientMutationId?: string; + domainEvent: { + actorId?: string; + domainVerificationId?: string; + eventType: string; + managedDomainId: string; + message?: string; + metadata?: Record; + ownerId: string; + }; +} +export interface DomainEventPatch { + actorId?: string | null; + domainVerificationId?: string | null; + eventType?: string | null; + managedDomainId?: string | null; + message?: string | null; + metadata?: Record | null; + ownerId?: string | null; +} +export interface UpdateDomainEventInput { + clientMutationId?: string; + id: string; + domainEventPatch: DomainEventPatch; +} +export interface DeleteDomainEventInput { + clientMutationId?: string; + id: string; +} +export interface CreateDomainVerificationInput { + clientMutationId?: string; + domainVerification: { + attempts?: number; + error?: string; + expiresAt?: string; + lastCheckedAt?: string; + managedDomainId: string; + method?: string; + ownerId: string; + recordName?: string; + recordType?: string; + recordValue?: string; + status?: string; + verifiedAt?: string; + }; +} +export interface DomainVerificationPatch { + attempts?: number | null; + error?: string | null; + expiresAt?: string | null; + lastCheckedAt?: string | null; + managedDomainId?: string | null; + method?: string | null; + ownerId?: string | null; + recordName?: string | null; + recordType?: string | null; + recordValue?: string | null; + status?: string | null; + verifiedAt?: string | null; +} +export interface UpdateDomainVerificationInput { + clientMutationId?: string; + id: string; + domainVerificationPatch: DomainVerificationPatch; +} +export interface DeleteDomainVerificationInput { + clientMutationId?: string; + id: string; +} export interface CreateEmbeddingChunkInput { clientMutationId?: string; embeddingChunk: { @@ -6753,7 +7098,9 @@ export interface DeleteIndexInput { export interface CreateManagedDomainInput { clientMutationId?: string; managedDomain: { + allowPublicUsage?: boolean; annotations?: Record; + certStatus?: string; databaseId: string; domain: ConstructiveInternalTypeHostname; isWildcard?: boolean; @@ -6764,7 +7111,9 @@ export interface CreateManagedDomainInput { }; } export interface ManagedDomainPatch { + allowPublicUsage?: boolean | null; annotations?: Record | null; + certStatus?: string | null; databaseId?: string | null; domain?: ConstructiveInternalTypeHostname | null; isWildcard?: boolean | null; @@ -7624,10 +7973,17 @@ export const connectionFieldsMap = { Domain: { httpRoutes: 'HttpRoute', }, + DomainVerification: { + domainEvents: 'DomainEvent', + }, Field: { spatialRelations: 'SpatialRelation', spatialRelationsByRefFieldId: 'SpatialRelation', }, + ManagedDomain: { + domainEvents: 'DomainEvent', + domainVerifications: 'DomainVerification', + }, Schema: { apiSchemas: 'ApiSchema', compositeTypes: 'CompositeType', @@ -8314,6 +8670,15 @@ export interface DomainToManyHttpRouteFilter { /** Filters to entities where at least one related entity matches. */ some?: HttpRouteFilter; } +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} /** A filter to be used against many `SpatialRelation` object types. All fields are combined with a logical ‘and.’ */ export interface FieldToManySpatialRelationFilter { /** Filters to entities where every related entity matches. */ @@ -8323,6 +8688,24 @@ export interface FieldToManySpatialRelationFilter { /** Filters to entities where at least one related entity matches. */ some?: SpatialRelationFilter; } +/** A filter to be used against many `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainEventFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainEventFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainEventFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainEventFilter; +} +/** A filter to be used against many `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface ManagedDomainToManyDomainVerificationFilter { + /** Filters to entities where every related entity matches. */ + every?: DomainVerificationFilter; + /** Filters to entities where no related entity matches. */ + none?: DomainVerificationFilter; + /** Filters to entities where at least one related entity matches. */ + some?: DomainVerificationFilter; +} /** A filter to be used against ApiExposureLevel fields. All fields are combined with a logical ‘and.’ */ export interface ApiExposureLevelFilter { /** Not equal to the specified value, treating null like an ordinary value. */ @@ -8923,6 +9306,60 @@ export interface DomainInput { /** Subdomain portion of the hostname */ subdomain?: ConstructiveInternalTypeHostname; } +/** An input for mutations affecting `DomainEvent` */ +export interface DomainEventInput { + /** User who triggered this event (NULL for system/automated transitions) */ + actorId?: string; + /** Event timestamp */ + createdAt?: string; + /** The verification challenge this event relates to, when applicable */ + domainVerificationId?: string; + /** Lifecycle event: challenge_issued | verification_started | verified | verification_failed | verification_expired | cert_issuing | cert_active | cert_error | cert_renewed | cert_revoked */ + eventType: string; + /** Unique event identifier */ + id?: string; + /** The managed_domain this event belongs to */ + managedDomainId: string; + /** Human-readable description of the event */ + message?: string; + /** Structured context (challenge record, cert-manager detail, error details, ...) */ + metadata?: Record; + /** Entity (e.g. org) that owns the managed_domain; scope key for AuthzEntityMembership RLS */ + ownerId: string; +} +/** An input for mutations affecting `DomainVerification` */ +export interface DomainVerificationInput { + /** Number of times domain:verify has polled for this challenge (drives backoff / max_attempts) */ + attempts?: number; + /** When this challenge was minted (domain:issue_challenge) */ + createdAt?: string; + /** Last verification error (mismatch, NXDOMAIN, timeout, ...) */ + error?: string; + /** When this challenge expires and must be reissued */ + expiresAt?: string; + /** Unique identifier for this verification challenge */ + id?: string; + /** When domain:verify last polled DNS/HTTP for this challenge */ + lastCheckedAt?: string; + /** The managed_domain this challenge proves ownership of */ + managedDomainId: string; + /** Verification method: dns_txt_ownership (root-domain ownership TXT) | http_01 (ACME HTTP challenge) | dns_01_acme (ACME DNS challenge) */ + method?: string; + /** Entity (e.g. org) that owns this verification; scope key for AuthzEntityMembership RLS. Domain control is proven once per owning entity. */ + ownerId: string; + /** DNS record name the user must create (e.g. _constructive-challenge.example.com); NULL for http_01 */ + recordName?: string; + /** DNS record type to create: TXT | CNAME | A; NULL for http_01 */ + recordType?: string; + /** The public challenge token the user must publish (ends up in a public DNS record). NOT a secret. */ + recordValue?: string; + /** Challenge lifecycle: pending | checking | verified | failed | expired */ + status?: string; + /** When this row was last updated */ + updatedAt?: string; + /** When status last became verified */ + verifiedAt?: string; +} /** An input for mutations affecting `EmbeddingChunk` */ export interface EmbeddingChunkInput { chunkOverlap?: number; @@ -9071,8 +9508,12 @@ export interface IndexInput { } /** An input for mutations affecting `ManagedDomain` */ export interface ManagedDomainInput { + /** Whether this domain is deliberately published so routes in other scopes may match and ride this row's cert. Only settable by app/platform authority via a generated AuthzColumnSecurity write-guard; backed by a generated permissive cross-scope SELECT policy. */ + allowPublicUsage?: boolean; /** Freeform cert-manager detail (secret name, challenge, last error) and tooling metadata */ annotations?: Record; + /** cert-manager resource lifecycle driven by the domain:issue_cert/domain:check_cert loop, tracked independently of tls_status: none | issuing | active | error */ + certStatus?: string; /** Database that owns this cert-bearing host; platform wildcards are owned by the platform database */ databaseId: string; /** Root hostname this row governs certs/verification for (e.g. launchql.dev, shop.acme.com) */ @@ -9083,9 +9524,9 @@ export interface ManagedDomainInput { isWildcard?: boolean; /** When tls_status last became active */ tlsReadyAt?: string; - /** TLS/SSL provisioning state: none | provisioning | active | failed */ + /** TLS/SSL serving/reconcile state (ingress): none | provisioning | active | failed */ tlsStatus?: string; - /** Domain ownership verification state: pending | verified | failed */ + /** Domain ownership verification state driven by the domain:issue_challenge/domain:verify loop: pending | checking | verified | failed | expired */ verificationStatus?: string; /** When verification_status last became verified */ verifiedAt?: string; @@ -10146,16 +10587,28 @@ export interface IndexFilter { } /** A filter to be used against `ManagedDomain` object types. All fields are combined with a logical ‘and.’ */ export interface ManagedDomainFilter { + /** Filter by the object’s `allowPublicUsage` field. */ + allowPublicUsage?: BooleanFilter; /** Checks for all expressions in this list. */ and?: ManagedDomainFilter[]; /** Filter by the object’s `annotations` field. */ annotations?: JSONFilter; + /** Filter by the object’s `certStatus` field. */ + certStatus?: StringFilter; /** Filter by the object’s `database` relation. */ database?: DatabaseFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `domain` field. */ domain?: ConstructiveInternalTypeHostnameFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: ManagedDomainToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `domainVerifications` relation. */ + domainVerifications?: ManagedDomainToManyDomainVerificationFilter; + /** `domainVerifications` exist. */ + domainVerificationsExist?: boolean; /** Filter by the object’s `id` field. */ id?: UUIDFilter; /** Filter by the object’s `isWildcard` field. */ @@ -10979,6 +11432,84 @@ export interface HttpRouteFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +/** A filter to be used against `DomainEvent` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainEventFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: DomainEventFilter[]; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainVerification` relation. */ + domainVerification?: DomainVerificationFilter; + /** A related `domainVerification` exists. */ + domainVerificationExists?: boolean; + /** Filter by the object’s `domainVerificationId` field. */ + domainVerificationId?: UUIDFilter; + /** Filter by the object’s `eventType` field. */ + eventType?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `message` field. */ + message?: StringFilter; + /** Filter by the object’s `metadata` field. */ + metadata?: JSONFilter; + /** Negates the expression. */ + not?: DomainEventFilter; + /** Checks for any expressions in this list. */ + or?: DomainEventFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; +} +/** A filter to be used against `DomainVerification` object types. All fields are combined with a logical ‘and.’ */ +export interface DomainVerificationFilter { + /** Checks for all expressions in this list. */ + and?: DomainVerificationFilter[]; + /** Filter by the object’s `attempts` field. */ + attempts?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `domainEvents` relation. */ + domainEvents?: DomainVerificationToManyDomainEventFilter; + /** `domainEvents` exist. */ + domainEventsExist?: boolean; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `expiresAt` field. */ + expiresAt?: DatetimeFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `lastCheckedAt` field. */ + lastCheckedAt?: DatetimeFilter; + /** Filter by the object’s `managedDomain` relation. */ + managedDomain?: ManagedDomainFilter; + /** Filter by the object’s `managedDomainId` field. */ + managedDomainId?: UUIDFilter; + /** Filter by the object’s `method` field. */ + method?: StringFilter; + /** Negates the expression. */ + not?: DomainVerificationFilter; + /** Checks for any expressions in this list. */ + or?: DomainVerificationFilter[]; + /** Filter by the object’s `ownerId` field. */ + ownerId?: UUIDFilter; + /** Filter by the object’s `recordName` field. */ + recordName?: StringFilter; + /** Filter by the object’s `recordType` field. */ + recordType?: StringFilter; + /** Filter by the object’s `recordValue` field. */ + recordValue?: StringFilter; + /** Filter by the object’s `status` field. */ + status?: StringFilter; + /** Filter by the object’s `updatedAt` field. */ + updatedAt?: DatetimeFilter; + /** Filter by the object’s `verifiedAt` field. */ + verifiedAt?: DatetimeFilter; +} /** A filter to be used against UUID fields. All fields are combined with a logical ‘and.’ */ export interface UUIDFilter { /** Not equal to the specified value, treating null like an ordinary value. */ @@ -12426,6 +12957,96 @@ export type DeleteDomainPayloadSelect = { select: DomainEdgeSelect; }; }; +export interface CreateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was created by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type CreateDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface UpdateDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was updated by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type UpdateDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface DeleteDomainEventPayload { + clientMutationId?: string | null; + /** The `DomainEvent` that was deleted by this mutation. */ + domainEvent?: DomainEvent | null; + domainEventEdge?: DomainEventEdge | null; +} +export type DeleteDomainEventPayloadSelect = { + clientMutationId?: boolean; + domainEvent?: { + select: DomainEventSelect; + }; + domainEventEdge?: { + select: DomainEventEdgeSelect; + }; +}; +export interface CreateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was created by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type CreateDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; +export interface UpdateDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was updated by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type UpdateDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; +export interface DeleteDomainVerificationPayload { + clientMutationId?: string | null; + /** The `DomainVerification` that was deleted by this mutation. */ + domainVerification?: DomainVerification | null; + domainVerificationEdge?: DomainVerificationEdge | null; +} +export type DeleteDomainVerificationPayloadSelect = { + clientMutationId?: boolean; + domainVerification?: { + select: DomainVerificationSelect; + }; + domainVerificationEdge?: { + select: DomainVerificationEdgeSelect; + }; +}; export interface CreateEmbeddingChunkPayload { clientMutationId?: string | null; /** The `EmbeddingChunk` that was created by this mutation. */ @@ -13868,6 +14489,8 @@ export type DeleteWebauthnSettingPayloadSelect = { }; /** Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. */ export interface DatabaseProvisionModule { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string | null; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -13901,6 +14524,7 @@ export interface DatabaseProvisionModule { updatedAt: string; } export type DatabaseProvisionModuleSelect = { + async?: boolean; bootstrapError?: boolean; bootstrapStatus?: boolean; bootstrapUser?: boolean; @@ -14076,6 +14700,30 @@ export type DomainEdgeSelect = { select: DomainSelect; }; }; +/** A `DomainEvent` edge in the connection. */ +export interface DomainEventEdge { + cursor?: string | null; + /** The `DomainEvent` at the end of the edge. */ + node?: DomainEvent | null; +} +export type DomainEventEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainEventSelect; + }; +}; +/** A `DomainVerification` edge in the connection. */ +export interface DomainVerificationEdge { + cursor?: string | null; + /** The `DomainVerification` at the end of the edge. */ + node?: DomainVerification | null; +} +export type DomainVerificationEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainVerificationSelect; + }; +}; /** A `EmbeddingChunk` edge in the connection. */ export interface EmbeddingChunkEdge { cursor?: string | null; diff --git a/sdk/constructive-sdk/src/api/orm/models/domainEvent.ts b/sdk/constructive-sdk/src/api/orm/models/domainEvent.ts new file mode 100644 index 000000000..7177a7270 --- /dev/null +++ b/sdk/constructive-sdk/src/api/orm/models/domainEvent.ts @@ -0,0 +1,245 @@ +/** + * DomainEvent model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainEvent, + DomainEventWithRelations, + DomainEventSelect, + DomainEventFilter, + DomainEventOrderBy, + CreateDomainEventInput, + UpdateDomainEventInput, + DomainEventPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainEventModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvents: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvents', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvent: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvent', + document, + variables, + transform: (data: { + domainEvents?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainEvent: data.domainEvents?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainEvent: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainEvent', + 'domainEvents', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainEventFilter', + 'DomainEventOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainEvent', + fieldName: 'domainEvent', + document, + variables, + transform: (data: { + domainEvents?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainEvent: data.domainEvents?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainEvent', + 'createDomainEvent', + 'domainEvent', + args.select, + args.data, + 'CreateDomainEventInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'createDomainEvent', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainEventPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainEvent', + 'updateDomainEvent', + 'domainEvent', + args.select, + args.where.id, + args.data, + 'UpdateDomainEventInput', + 'id', + 'domainEventPatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'updateDomainEvent', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainEvent: { + domainEvent: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainEvent', + 'deleteDomainEvent', + 'domainEvent', + { + id: args.where.id, + }, + 'DeleteDomainEventInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainEvent', + fieldName: 'deleteDomainEvent', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/api/orm/models/domainVerification.ts b/sdk/constructive-sdk/src/api/orm/models/domainVerification.ts new file mode 100644 index 000000000..b004e0b4d --- /dev/null +++ b/sdk/constructive-sdk/src/api/orm/models/domainVerification.ts @@ -0,0 +1,245 @@ +/** + * DomainVerification model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainVerification, + DomainVerificationWithRelations, + DomainVerificationSelect, + DomainVerificationFilter, + DomainVerificationOrderBy, + CreateDomainVerificationInput, + UpdateDomainVerificationInput, + DomainVerificationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainVerificationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerifications: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerifications', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerification: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerification', + document, + variables, + transform: (data: { + domainVerifications?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainVerification: data.domainVerifications?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainVerification: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainVerification', + 'domainVerifications', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainVerificationFilter', + 'DomainVerificationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainVerification', + fieldName: 'domainVerification', + document, + variables, + transform: (data: { + domainVerifications?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainVerification: data.domainVerifications?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainVerification', + 'createDomainVerification', + 'domainVerification', + args.select, + args.data, + 'CreateDomainVerificationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'createDomainVerification', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainVerificationPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainVerification', + 'updateDomainVerification', + 'domainVerification', + args.select, + args.where.id, + args.data, + 'UpdateDomainVerificationInput', + 'id', + 'domainVerificationPatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'updateDomainVerification', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainVerification: { + domainVerification: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainVerification', + 'deleteDomainVerification', + 'domainVerification', + { + id: args.where.id, + }, + 'DeleteDomainVerificationInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainVerification', + fieldName: 'deleteDomainVerification', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/api/orm/models/index.ts b/sdk/constructive-sdk/src/api/orm/models/index.ts index 26dab64b2..a21fca3c5 100644 --- a/sdk/constructive-sdk/src/api/orm/models/index.ts +++ b/sdk/constructive-sdk/src/api/orm/models/index.ts @@ -17,6 +17,8 @@ export { DatabaseSettingModel } from './databaseSetting'; export { DatabaseTransferModel } from './databaseTransfer'; export { DefaultPrivilegeModel } from './defaultPrivilege'; export { DomainModel } from './domain'; +export { DomainEventModel } from './domainEvent'; +export { DomainVerificationModel } from './domainVerification'; export { EmbeddingChunkModel } from './embeddingChunk'; export { EnumModel } from './enum'; export { FieldModel } from './field'; diff --git a/sdk/constructive-sdk/src/api/orm/mutation/index.ts b/sdk/constructive-sdk/src/api/orm/mutation/index.ts index 242a60b79..0192a395b 100644 --- a/sdk/constructive-sdk/src/api/orm/mutation/index.ts +++ b/sdk/constructive-sdk/src/api/orm/mutation/index.ts @@ -56,7 +56,7 @@ export interface RejectDatabaseTransferVariables { * Variables for requestDatabase * Requests a database and returns a ticket (database_provision_module row) to poll. -Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. +Pass exactly one of preset_slug or modules. The pool, presets, and owner bootstrap are private implementation details: a warm pool hit fulfills the ticket immediately (fulfilled_at set, deferred owner bootstrap), otherwise the database is cold-provisioned asynchronously with exactly the requested modules. Poll the ticket until status = 'completed'; it then carries database_id and fulfilled_at. Example usage: SELECT * FROM metaschema_public.request_database('my_app', 'example.com', preset_slug := 'full'); diff --git a/sdk/constructive-sdk/src/api/orm/query/index.ts b/sdk/constructive-sdk/src/api/orm/query/index.ts index 0b7b1b1f0..1e86e6234 100644 --- a/sdk/constructive-sdk/src/api/orm/query/index.ts +++ b/sdk/constructive-sdk/src/api/orm/query/index.ts @@ -13,9 +13,9 @@ export interface ApplyRegistryDefaultsVariables { nodeType?: string; } export interface ResolveHttpRouteVariables { - pHost?: string; - pMethod?: string; - pPath?: string; + requestHost?: string; + requestMethod?: string; + requestPath?: string; } export function createQueryOperations(client: OrmClient) { return { @@ -73,15 +73,15 @@ export function createQueryOperations(client: OrmClient) { args, [ { - name: 'pHost', + name: 'requestHost', type: 'String', }, { - name: 'pMethod', + name: 'requestMethod', type: 'String', }, { - name: 'pPath', + name: 'requestPath', type: 'String', }, ], diff --git a/sdk/constructive-sdk/src/compute/README.md b/sdk/constructive-sdk/src/compute/README.md index 2dbdf9e65..53efb0b73 100644 --- a/sdk/constructive-sdk/src/compute/README.md +++ b/sdk/constructive-sdk/src/compute/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 65 +- **Tables:** 67 - **Custom queries:** 1 - **Custom mutations:** 28 diff --git a/sdk/constructive-sdk/src/compute/orm/README.md b/sdk/constructive-sdk/src/compute/orm/README.md index 1da2b6a29..c8d23ccd1 100644 --- a/sdk/constructive-sdk/src/compute/orm/README.md +++ b/sdk/constructive-sdk/src/compute/orm/README.md @@ -22,7 +22,6 @@ const db = createClient({ | Model | Operations | |-------|------------| | `dbPreset` | findMany, findOne, create, update, delete | -| `declaredCapacity` | findMany, findOne, create, update, delete | | `functionApiBinding` | findMany, findOne, create, update, delete | | `functionDefinition` | findMany, findOne, create, update, delete | | `functionDeployment` | findMany, findOne, create, update, delete | @@ -36,6 +35,7 @@ const db = createClient({ | `functionGraphObject` | findMany, findOne, create, update, delete | | `functionGraphRef` | findMany, findOne, create, update, delete | | `functionGraphStore` | findMany, findOne, create, update, delete | +| `functionInvocationAttempt` | findMany, findOne, create, update, delete | | `functionInvocation` | findMany, findOne, create, update, delete | | `getAllTreeNodesRecord` | findMany, findOne, create, update, delete | | `infraCommit` | findMany, findOne, create, update, delete | @@ -46,12 +46,12 @@ const db = createClient({ | `integrationProvider` | findMany, findOne, create, update, delete | | `namespace` | findMany, findOne, create, update, delete | | `namespaceEvent` | findMany, findOne, create, update, delete | -| `platformDeclaredCapacity` | findMany, findOne, create, update, delete | | `platformFunctionApiBinding` | findMany, findOne, create, update, delete | | `platformFunctionDefinition` | findMany, findOne, create, update, delete | | `platformFunctionDeployment` | findMany, findOne, create, update, delete | | `platformFunctionDeploymentEvent` | findMany, findOne, create, update, delete | | `platformFunctionExecutionLog` | findMany, findOne, create, update, delete | +| `platformFunctionInvocationAttempt` | findMany, findOne, create, update, delete | | `platformFunctionInvocation` | findMany, findOne, create, update, delete | | `platformInfraCommit` | findMany, findOne, create, update, delete | | `platformInfraGetAllTreeNodesRecord` | findMany, findOne, create, update, delete | @@ -61,26 +61,28 @@ const db = createClient({ | `platformNamespace` | findMany, findOne, create, update, delete | | `platformNamespaceEvent` | findMany, findOne, create, update, delete | | `platformResource` | findMany, findOne, create, update, delete | +| `platformResourceDeclaredCapacity` | findMany, findOne, create, update, delete | | `platformResourceDefinition` | findMany, findOne, create, update, delete | | `platformResourceEvent` | findMany, findOne, create, update, delete | | `platformResourceInstallation` | findMany, findOne, create, update, delete | | `platformResourceStatusCheck` | findMany, findOne, create, update, delete | | `platformResourceUsageLog` | findMany, findOne, create, update, delete | | `platformResourceUsageSummary` | findMany, findOne, create, update, delete | -| `platformResourceUtilizationDaily` | findMany, findOne, create, update, delete | +| `platformResourceUtilization` | findMany, findOne, create, update, delete | | `platformResourcesHealth` | findMany, findOne, create, update, delete | | `platformResourcesRequirementsState` | findMany, findOne, create, update, delete | | `platformResourcesResolvedRequirement` | findMany, findOne, create, update, delete | | `platformWebhookEndpoint` | findMany, findOne, create, update, delete | | `platformWebhookEvent` | findMany, findOne, create, update, delete | | `resource` | findMany, findOne, create, update, delete | +| `resourceDeclaredCapacity` | findMany, findOne, create, update, delete | | `resourceDefinition` | findMany, findOne, create, update, delete | | `resourceEvent` | findMany, findOne, create, update, delete | | `resourceInstallation` | findMany, findOne, create, update, delete | | `resourceStatusCheck` | findMany, findOne, create, update, delete | | `resourceUsageLog` | findMany, findOne, create, update, delete | | `resourceUsageSummary` | findMany, findOne, create, update, delete | -| `resourceUtilizationDaily` | findMany, findOne, create, update, delete | +| `resourceUtilization` | findMany, findOne, create, update, delete | | `resourcesHealth` | findMany, findOne, create, update, delete | | `resourcesRequirementsState` | findMany, findOne, create, update, delete | | `resourcesResolvedRequirement` | findMany, findOne, create, update, delete | @@ -128,47 +130,6 @@ const updated = await db.dbPreset.update({ where: { id: '' }, data: { acti const deleted = await db.dbPreset.delete({ where: { id: '' } }).execute(); ``` -### `db.declaredCapacity` - -CRUD operations for DeclaredCapacity records. - -**Fields:** - -| Field | Type | Editable | -|-------|------|----------| -| `cpuLimitMillicores` | BigInt | Yes | -| `cpuRequestMillicores` | BigInt | Yes | -| `installationId` | UUID | Yes | -| `isTransient` | Boolean | Yes | -| `kind` | String | Yes | -| `memoryLimitBytes` | BigInt | Yes | -| `memoryRequestBytes` | BigInt | Yes | -| `namespaceId` | UUID | Yes | -| `podCountMax` | Int | Yes | -| `podCountMin` | Int | Yes | -| `source` | String | Yes | -| `sourceId` | UUID | Yes | -| `storageSizeBytes` | BigInt | Yes | - -**Operations:** - -```typescript -// List all declaredCapacity records -const items = await db.declaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Get one by id -const item = await db.declaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Create -const created = await db.declaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); - -// Update -const updated = await db.declaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); - -// Delete -const deleted = await db.declaredCapacity.delete({ where: { id: '' } }).execute(); -``` - ### `db.functionApiBinding` CRUD operations for FunctionApiBinding records. @@ -709,6 +670,47 @@ const updated = await db.functionGraphStore.update({ where: { id: '' }, da const deleted = await db.functionGraphStore.delete({ where: { id: '' } }).execute(); ``` +### `db.functionInvocationAttempt` + +CRUD operations for FunctionInvocationAttempt records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `attempt` | Int | Yes | +| `createdAt` | Datetime | No | +| `databaseId` | UUID | Yes | +| `durationMs` | Int | Yes | +| `error` | String | Yes | +| `errorDetail` | JSON | Yes | +| `id` | UUID | No | +| `invocationCreatedAt` | Datetime | Yes | +| `invocationId` | UUID | Yes | +| `startedAt` | Datetime | Yes | +| `success` | Boolean | Yes | +| `taskIdentifier` | String | Yes | + +**Operations:** + +```typescript +// List all functionInvocationAttempt records +const items = await db.functionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Get one by id +const item = await db.functionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, databaseId: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Create +const created = await db.functionInvocationAttempt.create({ data: { actorId: '', attempt: '', databaseId: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.functionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.functionInvocationAttempt.delete({ where: { id: '' } }).execute(); +``` + ### `db.functionInvocation` CRUD operations for FunctionInvocation records. @@ -1071,47 +1073,6 @@ const updated = await db.namespaceEvent.update({ where: { id: '' }, data: const deleted = await db.namespaceEvent.delete({ where: { id: '' } }).execute(); ``` -### `db.platformDeclaredCapacity` - -CRUD operations for PlatformDeclaredCapacity records. - -**Fields:** - -| Field | Type | Editable | -|-------|------|----------| -| `cpuLimitMillicores` | BigInt | Yes | -| `cpuRequestMillicores` | BigInt | Yes | -| `installationId` | UUID | Yes | -| `isTransient` | Boolean | Yes | -| `kind` | String | Yes | -| `memoryLimitBytes` | BigInt | Yes | -| `memoryRequestBytes` | BigInt | Yes | -| `namespaceId` | UUID | Yes | -| `podCountMax` | Int | Yes | -| `podCountMin` | Int | Yes | -| `source` | String | Yes | -| `sourceId` | UUID | Yes | -| `storageSizeBytes` | BigInt | Yes | - -**Operations:** - -```typescript -// List all platformDeclaredCapacity records -const items = await db.platformDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Get one by id -const item = await db.platformDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); - -// Create -const created = await db.platformDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); - -// Update -const updated = await db.platformDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); - -// Delete -const deleted = await db.platformDeclaredCapacity.delete({ where: { id: '' } }).execute(); -``` - ### `db.platformFunctionApiBinding` CRUD operations for PlatformFunctionApiBinding records. @@ -1154,6 +1115,7 @@ CRUD operations for PlatformFunctionDefinition records. | Field | Type | Editable | |-------|------|----------| | `accessChannels` | String | Yes | +| `billable` | Boolean | Yes | | `category` | String | Yes | | `concurrency` | Int | Yes | | `cpuLimitMillicores` | BigInt | Yes | @@ -1189,6 +1151,7 @@ CRUD operations for PlatformFunctionDefinition records. | `runtime` | String | Yes | | `scaleMax` | Int | Yes | | `scaleMin` | Int | Yes | +| `system` | Boolean | Yes | | `targetFunction` | String | Yes | | `targetSchema` | String | Yes | | `taskIdentifier` | String | Yes | @@ -1200,13 +1163,13 @@ CRUD operations for PlatformFunctionDefinition records. ```typescript // List all platformFunctionDefinition records -const items = await db.platformFunctionDefinition.findMany({ select: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); +const items = await db.platformFunctionDefinition.findMany({ select: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); // Get one by id -const item = await db.platformFunctionDefinition.findOne({ id: '', select: { accessChannels: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); +const item = await db.platformFunctionDefinition.findOne({ id: '', select: { accessChannels: true, billable: true, category: true, concurrency: true, cpuLimitMillicores: true, cpuRequestMillicores: true, createdAt: true, description: true, fnCategory: true, functionColumns: true, graphId: true, icon: true, id: true, image: true, inputs: true, integrations: true, isPublished: true, maxAttempts: true, memoryLimitBytes: true, memoryRequestBytes: true, moduleTable: true, name: true, outputs: true, payloadArgs: true, priority: true, props: true, protected: true, publishedAt: true, queueName: true, requiredBuckets: true, requiredConfigs: true, requiredModels: true, requiredSecrets: true, resources: true, runtime: true, scaleMax: true, scaleMin: true, system: true, targetFunction: true, targetSchema: true, taskIdentifier: true, timeoutSeconds: true, updatedAt: true, volatile: true } }).execute(); // Create -const created = await db.platformFunctionDefinition.create({ data: { accessChannels: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute(); +const created = await db.platformFunctionDefinition.create({ data: { accessChannels: '', billable: '', category: '', concurrency: '', cpuLimitMillicores: '', cpuRequestMillicores: '', description: '', fnCategory: '', functionColumns: '', graphId: '', icon: '', image: '', inputs: '', integrations: '', isPublished: '', maxAttempts: '', memoryLimitBytes: '', memoryRequestBytes: '', moduleTable: '', name: '', outputs: '', payloadArgs: '', priority: '', props: '', protected: '', publishedAt: '', queueName: '', requiredBuckets: '', requiredConfigs: '', requiredModels: '', requiredSecrets: '', resources: '', runtime: '', scaleMax: '', scaleMin: '', system: '', targetFunction: '', targetSchema: '', taskIdentifier: '', timeoutSeconds: '', volatile: '' }, select: { id: true } }).execute(); // Update const updated = await db.platformFunctionDefinition.update({ where: { id: '' }, data: { accessChannels: '' }, select: { id: true } }).execute(); @@ -1335,6 +1298,46 @@ const updated = await db.platformFunctionExecutionLog.update({ where: { id: '' } }).execute(); ``` +### `db.platformFunctionInvocationAttempt` + +CRUD operations for PlatformFunctionInvocationAttempt records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `actorId` | UUID | Yes | +| `attempt` | Int | Yes | +| `createdAt` | Datetime | No | +| `durationMs` | Int | Yes | +| `error` | String | Yes | +| `errorDetail` | JSON | Yes | +| `id` | UUID | No | +| `invocationCreatedAt` | Datetime | Yes | +| `invocationId` | UUID | Yes | +| `startedAt` | Datetime | Yes | +| `success` | Boolean | Yes | +| `taskIdentifier` | String | Yes | + +**Operations:** + +```typescript +// List all platformFunctionInvocationAttempt records +const items = await db.platformFunctionInvocationAttempt.findMany({ select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Get one by id +const item = await db.platformFunctionInvocationAttempt.findOne({ id: '', select: { actorId: true, attempt: true, createdAt: true, durationMs: true, error: true, errorDetail: true, id: true, invocationCreatedAt: true, invocationId: true, startedAt: true, success: true, taskIdentifier: true } }).execute(); + +// Create +const created = await db.platformFunctionInvocationAttempt.create({ data: { actorId: '', attempt: '', durationMs: '', error: '', errorDetail: '', invocationCreatedAt: '', invocationId: '', startedAt: '', success: '', taskIdentifier: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.platformFunctionInvocationAttempt.update({ where: { id: '' }, data: { actorId: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.platformFunctionInvocationAttempt.delete({ where: { id: '' } }).execute(); +``` + ### `db.platformFunctionInvocation` CRUD operations for PlatformFunctionInvocation records. @@ -1681,6 +1684,47 @@ const updated = await db.platformResource.update({ where: { id: '' }, data const deleted = await db.platformResource.delete({ where: { id: '' } }).execute(); ``` +### `db.platformResourceDeclaredCapacity` + +CRUD operations for PlatformResourceDeclaredCapacity records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `cpuLimitMillicores` | BigInt | Yes | +| `cpuRequestMillicores` | BigInt | Yes | +| `installationId` | UUID | Yes | +| `isTransient` | Boolean | Yes | +| `kind` | String | Yes | +| `memoryLimitBytes` | BigInt | Yes | +| `memoryRequestBytes` | BigInt | Yes | +| `namespaceId` | UUID | Yes | +| `podCountMax` | Int | Yes | +| `podCountMin` | Int | Yes | +| `source` | String | Yes | +| `sourceId` | UUID | Yes | +| `storageSizeBytes` | BigInt | Yes | + +**Operations:** + +```typescript +// List all platformResourceDeclaredCapacity records +const items = await db.platformResourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Get one by id +const item = await db.platformResourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Create +const created = await db.platformResourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.platformResourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.platformResourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); +``` + ### `db.platformResourceDefinition` CRUD operations for PlatformResourceDefinition records. @@ -1911,9 +1955,9 @@ const updated = await db.platformResourceUsageSummary.update({ where: { id: '' } }).execute(); ``` -### `db.platformResourceUtilizationDaily` +### `db.platformResourceUtilization` -CRUD operations for PlatformResourceUtilizationDaily records. +CRUD operations for PlatformResourceUtilization records. **Fields:** @@ -1942,20 +1986,20 @@ CRUD operations for PlatformResourceUtilizationDaily records. **Operations:** ```typescript -// List all platformResourceUtilizationDaily records -const items = await db.platformResourceUtilizationDaily.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +// List all platformResourceUtilization records +const items = await db.platformResourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id -const item = await db.platformResourceUtilizationDaily.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +const item = await db.platformResourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create -const created = await db.platformResourceUtilizationDaily.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); +const created = await db.platformResourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update -const updated = await db.platformResourceUtilizationDaily.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); +const updated = await db.platformResourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete -const deleted = await db.platformResourceUtilizationDaily.delete({ where: { id: '' } }).execute(); +const deleted = await db.platformResourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.platformResourcesHealth` @@ -2228,6 +2272,47 @@ const updated = await db.resource.update({ where: { id: '' }, data: { anno const deleted = await db.resource.delete({ where: { id: '' } }).execute(); ``` +### `db.resourceDeclaredCapacity` + +CRUD operations for ResourceDeclaredCapacity records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `cpuLimitMillicores` | BigInt | Yes | +| `cpuRequestMillicores` | BigInt | Yes | +| `installationId` | UUID | Yes | +| `isTransient` | Boolean | Yes | +| `kind` | String | Yes | +| `memoryLimitBytes` | BigInt | Yes | +| `memoryRequestBytes` | BigInt | Yes | +| `namespaceId` | UUID | Yes | +| `podCountMax` | Int | Yes | +| `podCountMin` | Int | Yes | +| `source` | String | Yes | +| `sourceId` | UUID | Yes | +| `storageSizeBytes` | BigInt | Yes | + +**Operations:** + +```typescript +// List all resourceDeclaredCapacity records +const items = await db.resourceDeclaredCapacity.findMany({ select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Get one by id +const item = await db.resourceDeclaredCapacity.findOne({ id: '', select: { cpuLimitMillicores: true, cpuRequestMillicores: true, installationId: true, isTransient: true, kind: true, memoryLimitBytes: true, memoryRequestBytes: true, namespaceId: true, podCountMax: true, podCountMin: true, source: true, sourceId: true, storageSizeBytes: true } }).execute(); + +// Create +const created = await db.resourceDeclaredCapacity.create({ data: { cpuLimitMillicores: '', cpuRequestMillicores: '', installationId: '', isTransient: '', kind: '', memoryLimitBytes: '', memoryRequestBytes: '', namespaceId: '', podCountMax: '', podCountMin: '', source: '', sourceId: '', storageSizeBytes: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.resourceDeclaredCapacity.update({ where: { id: '' }, data: { cpuLimitMillicores: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.resourceDeclaredCapacity.delete({ where: { id: '' } }).execute(); +``` + ### `db.resourceDefinition` CRUD operations for ResourceDefinition records. @@ -2464,9 +2549,9 @@ const updated = await db.resourceUsageSummary.update({ where: { id: '' }, const deleted = await db.resourceUsageSummary.delete({ where: { id: '' } }).execute(); ``` -### `db.resourceUtilizationDaily` +### `db.resourceUtilization` -CRUD operations for ResourceUtilizationDaily records. +CRUD operations for ResourceUtilization records. **Fields:** @@ -2495,20 +2580,20 @@ CRUD operations for ResourceUtilizationDaily records. **Operations:** ```typescript -// List all resourceUtilizationDaily records -const items = await db.resourceUtilizationDaily.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +// List all resourceUtilization records +const items = await db.resourceUtilization.findMany({ select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Get one by id -const item = await db.resourceUtilizationDaily.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); +const item = await db.resourceUtilization.findOne({ id: '', select: { avgMemoryBytes: true, cpuLimitMillicores: true, cpuPeakUtilization: true, cpuRequestHeadroomMillicores: true, cpuRequestMillicores: true, date: true, gbSeconds: true, kind: true, maxCpuMillicores: true, maxMemoryBytes: true, memoryLimitBytes: true, memoryPeakUtilization: true, memoryRequestBytes: true, memoryRequestHeadroomBytes: true, namespaceId: true, replicas: true, resourceId: true, runtimeSeconds: true, sampleCount: true } }).execute(); // Create -const created = await db.resourceUtilizationDaily.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); +const created = await db.resourceUtilization.create({ data: { avgMemoryBytes: '', cpuLimitMillicores: '', cpuPeakUtilization: '', cpuRequestHeadroomMillicores: '', cpuRequestMillicores: '', date: '', gbSeconds: '', kind: '', maxCpuMillicores: '', maxMemoryBytes: '', memoryLimitBytes: '', memoryPeakUtilization: '', memoryRequestBytes: '', memoryRequestHeadroomBytes: '', namespaceId: '', replicas: '', resourceId: '', runtimeSeconds: '', sampleCount: '' }, select: { id: true } }).execute(); // Update -const updated = await db.resourceUtilizationDaily.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); +const updated = await db.resourceUtilization.update({ where: { id: '' }, data: { avgMemoryBytes: '' }, select: { id: true } }).execute(); // Delete -const deleted = await db.resourceUtilizationDaily.delete({ where: { id: '' } }).execute(); +const deleted = await db.resourceUtilization.delete({ where: { id: '' } }).execute(); ``` ### `db.resourcesHealth` @@ -2980,7 +3065,7 @@ platformResourceInstallationsInstall | `input` | PlatformResourceInstallationsInstallInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsRollback` @@ -2995,7 +3080,7 @@ platformResourceInstallationsRollback | `input` | PlatformResourceInstallationsRollbackInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUninstall` @@ -3010,7 +3095,7 @@ platformResourceInstallationsUninstall | `input` | PlatformResourceInstallationsUninstallInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.platformResourceInstallationsUpgrade` @@ -3025,7 +3110,7 @@ platformResourceInstallationsUpgrade | `input` | PlatformResourceInstallationsUpgradeInput (required) | ```typescript -const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.platformResourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.provisionBucket` @@ -3058,7 +3143,7 @@ resourceInstallationsInstall | `input` | ResourceInstallationsInstallInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsInstall({ input: { pName: '', pNamespaceId: '', pParams: '', pSlug: '' } }).execute(); +const result = await db.mutation.resourceInstallationsInstall({ input: { name: '', namespaceId: '', newParams: '', slug: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsRollback` @@ -3073,7 +3158,7 @@ resourceInstallationsRollback | `input` | ResourceInstallationsRollbackInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsRollback({ input: { pCommitId: '', pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsRollback({ input: { commitId: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUninstall` @@ -3088,7 +3173,7 @@ resourceInstallationsUninstall | `input` | ResourceInstallationsUninstallInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsUninstall({ input: { pInstallationId: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUninstall({ input: { targetInstallationId: '' } }).execute(); ``` ### `db.mutation.resourceInstallationsUpgrade` @@ -3103,7 +3188,7 @@ resourceInstallationsUpgrade | `input` | ResourceInstallationsUpgradeInput (required) | ```typescript -const result = await db.mutation.resourceInstallationsUpgrade({ input: { pInstallationId: '', pParams: '' } }).execute(); +const result = await db.mutation.resourceInstallationsUpgrade({ input: { newParams: '', targetInstallationId: '' } }).execute(); ``` ### `db.mutation.saveGraph` diff --git a/sdk/constructive-sdk/src/compute/orm/index.ts b/sdk/constructive-sdk/src/compute/orm/index.ts index 979783107..933b08ed3 100644 --- a/sdk/constructive-sdk/src/compute/orm/index.ts +++ b/sdk/constructive-sdk/src/compute/orm/index.ts @@ -6,7 +6,6 @@ import { OrmClient } from './client'; import type { OrmClientConfig } from './client'; import { DbPresetModel } from './models/dbPreset'; -import { DeclaredCapacityModel } from './models/declaredCapacity'; import { FunctionApiBindingModel } from './models/functionApiBinding'; import { FunctionDefinitionModel } from './models/functionDefinition'; import { FunctionDeploymentModel } from './models/functionDeployment'; @@ -20,6 +19,7 @@ import { FunctionGraphExecutionOutputModel } from './models/functionGraphExecuti import { FunctionGraphObjectModel } from './models/functionGraphObject'; import { FunctionGraphRefModel } from './models/functionGraphRef'; import { FunctionGraphStoreModel } from './models/functionGraphStore'; +import { FunctionInvocationAttemptModel } from './models/functionInvocationAttempt'; import { FunctionInvocationModel } from './models/functionInvocation'; import { GetAllTreeNodesRecordModel } from './models/getAllTreeNodesRecord'; import { InfraCommitModel } from './models/infraCommit'; @@ -30,12 +30,12 @@ import { InfraStoreModel } from './models/infraStore'; import { IntegrationProviderModel } from './models/integrationProvider'; import { NamespaceModel } from './models/namespace'; import { NamespaceEventModel } from './models/namespaceEvent'; -import { PlatformDeclaredCapacityModel } from './models/platformDeclaredCapacity'; import { PlatformFunctionApiBindingModel } from './models/platformFunctionApiBinding'; import { PlatformFunctionDefinitionModel } from './models/platformFunctionDefinition'; import { PlatformFunctionDeploymentModel } from './models/platformFunctionDeployment'; import { PlatformFunctionDeploymentEventModel } from './models/platformFunctionDeploymentEvent'; import { PlatformFunctionExecutionLogModel } from './models/platformFunctionExecutionLog'; +import { PlatformFunctionInvocationAttemptModel } from './models/platformFunctionInvocationAttempt'; import { PlatformFunctionInvocationModel } from './models/platformFunctionInvocation'; import { PlatformInfraCommitModel } from './models/platformInfraCommit'; import { PlatformInfraGetAllTreeNodesRecordModel } from './models/platformInfraGetAllTreeNodesRecord'; @@ -45,26 +45,28 @@ import { PlatformInfraStoreModel } from './models/platformInfraStore'; import { PlatformNamespaceModel } from './models/platformNamespace'; import { PlatformNamespaceEventModel } from './models/platformNamespaceEvent'; import { PlatformResourceModel } from './models/platformResource'; +import { PlatformResourceDeclaredCapacityModel } from './models/platformResourceDeclaredCapacity'; import { PlatformResourceDefinitionModel } from './models/platformResourceDefinition'; import { PlatformResourceEventModel } from './models/platformResourceEvent'; import { PlatformResourceInstallationModel } from './models/platformResourceInstallation'; import { PlatformResourceStatusCheckModel } from './models/platformResourceStatusCheck'; import { PlatformResourceUsageLogModel } from './models/platformResourceUsageLog'; import { PlatformResourceUsageSummaryModel } from './models/platformResourceUsageSummary'; -import { PlatformResourceUtilizationDailyModel } from './models/platformResourceUtilizationDaily'; +import { PlatformResourceUtilizationModel } from './models/platformResourceUtilization'; import { PlatformResourcesHealthModel } from './models/platformResourcesHealth'; import { PlatformResourcesRequirementsStateModel } from './models/platformResourcesRequirementsState'; import { PlatformResourcesResolvedRequirementModel } from './models/platformResourcesResolvedRequirement'; import { PlatformWebhookEndpointModel } from './models/platformWebhookEndpoint'; import { PlatformWebhookEventModel } from './models/platformWebhookEvent'; import { ResourceModel } from './models/resource'; +import { ResourceDeclaredCapacityModel } from './models/resourceDeclaredCapacity'; import { ResourceDefinitionModel } from './models/resourceDefinition'; import { ResourceEventModel } from './models/resourceEvent'; import { ResourceInstallationModel } from './models/resourceInstallation'; import { ResourceStatusCheckModel } from './models/resourceStatusCheck'; import { ResourceUsageLogModel } from './models/resourceUsageLog'; import { ResourceUsageSummaryModel } from './models/resourceUsageSummary'; -import { ResourceUtilizationDailyModel } from './models/resourceUtilizationDaily'; +import { ResourceUtilizationModel } from './models/resourceUtilization'; import { ResourcesHealthModel } from './models/resourcesHealth'; import { ResourcesRequirementsStateModel } from './models/resourcesRequirementsState'; import { ResourcesResolvedRequirementModel } from './models/resourcesResolvedRequirement'; @@ -106,7 +108,6 @@ export function createClient(config: OrmClientConfig) { const client = new OrmClient(config); return { dbPreset: new DbPresetModel(client), - declaredCapacity: new DeclaredCapacityModel(client), functionApiBinding: new FunctionApiBindingModel(client), functionDefinition: new FunctionDefinitionModel(client), functionDeployment: new FunctionDeploymentModel(client), @@ -120,6 +121,7 @@ export function createClient(config: OrmClientConfig) { functionGraphObject: new FunctionGraphObjectModel(client), functionGraphRef: new FunctionGraphRefModel(client), functionGraphStore: new FunctionGraphStoreModel(client), + functionInvocationAttempt: new FunctionInvocationAttemptModel(client), functionInvocation: new FunctionInvocationModel(client), getAllTreeNodesRecord: new GetAllTreeNodesRecordModel(client), infraCommit: new InfraCommitModel(client), @@ -130,12 +132,12 @@ export function createClient(config: OrmClientConfig) { integrationProvider: new IntegrationProviderModel(client), namespace: new NamespaceModel(client), namespaceEvent: new NamespaceEventModel(client), - platformDeclaredCapacity: new PlatformDeclaredCapacityModel(client), platformFunctionApiBinding: new PlatformFunctionApiBindingModel(client), platformFunctionDefinition: new PlatformFunctionDefinitionModel(client), platformFunctionDeployment: new PlatformFunctionDeploymentModel(client), platformFunctionDeploymentEvent: new PlatformFunctionDeploymentEventModel(client), platformFunctionExecutionLog: new PlatformFunctionExecutionLogModel(client), + platformFunctionInvocationAttempt: new PlatformFunctionInvocationAttemptModel(client), platformFunctionInvocation: new PlatformFunctionInvocationModel(client), platformInfraCommit: new PlatformInfraCommitModel(client), platformInfraGetAllTreeNodesRecord: new PlatformInfraGetAllTreeNodesRecordModel(client), @@ -145,26 +147,28 @@ export function createClient(config: OrmClientConfig) { platformNamespace: new PlatformNamespaceModel(client), platformNamespaceEvent: new PlatformNamespaceEventModel(client), platformResource: new PlatformResourceModel(client), + platformResourceDeclaredCapacity: new PlatformResourceDeclaredCapacityModel(client), platformResourceDefinition: new PlatformResourceDefinitionModel(client), platformResourceEvent: new PlatformResourceEventModel(client), platformResourceInstallation: new PlatformResourceInstallationModel(client), platformResourceStatusCheck: new PlatformResourceStatusCheckModel(client), platformResourceUsageLog: new PlatformResourceUsageLogModel(client), platformResourceUsageSummary: new PlatformResourceUsageSummaryModel(client), - platformResourceUtilizationDaily: new PlatformResourceUtilizationDailyModel(client), + platformResourceUtilization: new PlatformResourceUtilizationModel(client), platformResourcesHealth: new PlatformResourcesHealthModel(client), platformResourcesRequirementsState: new PlatformResourcesRequirementsStateModel(client), platformResourcesResolvedRequirement: new PlatformResourcesResolvedRequirementModel(client), platformWebhookEndpoint: new PlatformWebhookEndpointModel(client), platformWebhookEvent: new PlatformWebhookEventModel(client), resource: new ResourceModel(client), + resourceDeclaredCapacity: new ResourceDeclaredCapacityModel(client), resourceDefinition: new ResourceDefinitionModel(client), resourceEvent: new ResourceEventModel(client), resourceInstallation: new ResourceInstallationModel(client), resourceStatusCheck: new ResourceStatusCheckModel(client), resourceUsageLog: new ResourceUsageLogModel(client), resourceUsageSummary: new ResourceUsageSummaryModel(client), - resourceUtilizationDaily: new ResourceUtilizationDailyModel(client), + resourceUtilization: new ResourceUtilizationModel(client), resourcesHealth: new ResourcesHealthModel(client), resourcesRequirementsState: new ResourcesRequirementsStateModel(client), resourcesResolvedRequirement: new ResourcesResolvedRequirementModel(client), diff --git a/sdk/constructive-sdk/src/compute/orm/input-types.ts b/sdk/constructive-sdk/src/compute/orm/input-types.ts index 676843824..6ff018412 100644 --- a/sdk/constructive-sdk/src/compute/orm/input-types.ts +++ b/sdk/constructive-sdk/src/compute/orm/input-types.ts @@ -260,21 +260,6 @@ export interface DbPreset { /** Timestamp of last modification */ updatedAt?: string | null; } -export interface DeclaredCapacity { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} /** Join table binding function definitions to API endpoints with per-binding alias and config */ export interface FunctionApiBinding { /** Binding alias (e.g. default, staging, production) */ @@ -365,7 +350,7 @@ export interface FunctionDefinition { targetFunction?: string | null; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string | null; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ + /** Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) */ taskIdentifier?: string | null; /** Knative request timeout in seconds */ timeoutSeconds?: number | null; @@ -659,6 +644,35 @@ export interface FunctionGraphStore { /** Opaque store partition key for the global tier */ scopeId?: string | null; } +/** Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail */ +export interface FunctionInvocationAttempt { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string | null; + /** 1-based attempt number for this invocation */ + attempt?: number | null; + /** When the attempt result was recorded (partition key) */ + createdAt?: string | null; + /** Database that owns this resource (database-scoped isolation) */ + databaseId?: string | null; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number | null; + /** Error message when the attempt failed */ + error?: string | null; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record | null; + /** Unique attempt identifier */ + id: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string | null; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string | null; + /** When the attempt began executing */ + startedAt?: string | null; + /** Whether this attempt completed successfully */ + success?: boolean | null; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string | null; +} /** Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. */ export interface FunctionInvocation { /** Who triggered the invocation (NULL for system/cron) */ @@ -677,7 +691,7 @@ export interface FunctionInvocation { definitionScope?: string | null; /** Wall-clock execution time in milliseconds */ durationMs?: number | null; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string | null; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string | null; @@ -697,7 +711,7 @@ export interface FunctionInvocation { result?: Record | null; /** When execution started */ startedAt?: string | null; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string | null; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string | null; @@ -841,21 +855,6 @@ export interface NamespaceEvent { /** Namespace this event belongs to */ namespaceId?: string | null; } -export interface PlatformDeclaredCapacity { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} /** Join table binding function definitions to API endpoints with per-binding alias and config */ export interface PlatformFunctionApiBinding { /** Binding alias (e.g. default, staging, production) */ @@ -872,6 +871,8 @@ export interface PlatformFunctionApiBinding { export interface PlatformFunctionDefinition { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[] | null; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean | null; /** Function task category (e.g. email, embed, chunk, custom) */ category?: string | null; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -940,11 +941,13 @@ export interface PlatformFunctionDefinition { scaleMax?: number | null; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number | null; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean | null; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string | null; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string | null; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ + /** Routing slug generated as category || ':' || name (used by the Knative job worker for dispatch) */ taskIdentifier?: string | null; /** Knative request timeout in seconds */ timeoutSeconds?: number | null; @@ -1030,6 +1033,33 @@ export interface PlatformFunctionExecutionLog { /** Function routing key (NULL for generic job logs) */ taskIdentifier?: string | null; } +/** Function invocation attempts — one row per worker attempt (including failed retries) with duration and error detail */ +export interface PlatformFunctionInvocationAttempt { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string | null; + /** 1-based attempt number for this invocation */ + attempt?: number | null; + /** When the attempt result was recorded (partition key) */ + createdAt?: string | null; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number | null; + /** Error message when the attempt failed */ + error?: string | null; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record | null; + /** Unique attempt identifier */ + id: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt?: string | null; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId?: string | null; + /** When the attempt began executing */ + startedAt?: string | null; + /** Whether this attempt completed successfully */ + success?: boolean | null; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier?: string | null; +} /** Function invocation log — INSERT to call a function (business-layer, metered). Linked to definitions via function_definition_id FK, with task_identifier as the denormalized routing/audit slug. */ export interface PlatformFunctionInvocation { /** Who triggered the invocation (NULL for system/cron) */ @@ -1046,7 +1076,7 @@ export interface PlatformFunctionInvocation { definitionScope?: string | null; /** Wall-clock execution time in milliseconds */ durationMs?: number | null; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string | null; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string | null; @@ -1066,7 +1096,7 @@ export interface PlatformFunctionInvocation { result?: Record | null; /** When execution started */ startedAt?: string | null; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string | null; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier?: string | null; @@ -1195,7 +1225,7 @@ export interface PlatformResource { installationId?: string | null; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string | null; /** Key/value pairs for selecting and filtering resources */ labels?: Record | null; @@ -1234,6 +1264,21 @@ export interface PlatformResource { updatedAt?: string | null; updatedBy?: string | null; } +export interface PlatformResourceDeclaredCapacity { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} /** Resource definitions — templates for resource kinds declaring default spec and secret/config requirements */ export interface PlatformResourceDefinition { /** Freeform metadata for tooling and operational notes */ @@ -1247,7 +1292,7 @@ export interface PlatformResourceDefinition { id: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string | null; /** Key/value pairs for selecting and filtering definitions */ labels?: Record | null; @@ -1324,7 +1369,7 @@ export interface PlatformResourceStatusCheck { /** Check lifecycle: pending, running, completed, failed */ status?: string | null; } -/** Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) */ +/** Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) */ export interface PlatformResourceUsageLog { /** CPU gauge in millicores at sample time (NULL when unknown) */ cpuMillicores?: string | null; @@ -1342,7 +1387,7 @@ export interface PlatformResourceUsageLog { resourceId?: string | null; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string | null; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string | null; } /** Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals */ @@ -1366,7 +1411,7 @@ export interface PlatformResourceUsageSummary { /** Number of raw samples aggregated into this summary */ sampleCount?: number | null; } -export interface PlatformResourceUtilizationDaily { +export interface PlatformResourceUtilization { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -1507,7 +1552,7 @@ export interface Resource { installationId?: string | null; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind?: string | null; /** Key/value pairs for selecting and filtering resources */ labels?: Record | null; @@ -1546,6 +1591,21 @@ export interface Resource { updatedAt?: string | null; updatedBy?: string | null; } +export interface ResourceDeclaredCapacity { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} /** Resource definitions — templates for resource kinds declaring default spec and secret/config requirements */ export interface ResourceDefinition { /** Freeform metadata for tooling and operational notes */ @@ -1561,7 +1621,7 @@ export interface ResourceDefinition { id: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[] | null; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind?: string | null; /** Key/value pairs for selecting and filtering definitions */ labels?: Record | null; @@ -1644,7 +1704,7 @@ export interface ResourceStatusCheck { /** Check lifecycle: pending, running, completed, failed */ status?: string | null; } -/** Raw resource usage log — interval-accounting measurements from heartbeats (self) and the reconciler (observer) */ +/** Raw resource usage log — interval-accounting measurements from heartbeats (self), the reconciler (observer), and the namespace-grain collector (prometheus) */ export interface ResourceUsageLog { /** CPU gauge in millicores at sample time (NULL when unknown) */ cpuMillicores?: string | null; @@ -1664,7 +1724,7 @@ export interface ResourceUsageLog { resourceId?: string | null; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string | null; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source?: string | null; } /** Resource usage summaries — runtime seconds, GB-seconds, and max gauges per (resource, namespace, day); resource_id-NULL rows are namespace-grain totals */ @@ -1690,7 +1750,7 @@ export interface ResourceUsageSummary { /** Number of raw samples aggregated into this summary */ sampleCount?: number | null; } -export interface ResourceUtilizationDaily { +export interface ResourceUtilization { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -1831,7 +1891,6 @@ export interface PageInfo { } // ============ Entity Relation Types ============ export interface DbPresetRelations {} -export interface DeclaredCapacityRelations {} export interface FunctionApiBindingRelations { functionDefinition?: FunctionDefinition | null; functionInvocationsByApiBindingId?: ConnectionResult; @@ -1858,6 +1917,7 @@ export interface FunctionGraphExecutionOutputRelations {} export interface FunctionGraphObjectRelations {} export interface FunctionGraphRefRelations {} export interface FunctionGraphStoreRelations {} +export interface FunctionInvocationAttemptRelations {} export interface FunctionInvocationRelations { apiBinding?: FunctionApiBinding | null; } @@ -1876,7 +1936,6 @@ export interface NamespaceRelations { webhookEndpoints?: ConnectionResult; } export interface NamespaceEventRelations {} -export interface PlatformDeclaredCapacityRelations {} export interface PlatformFunctionApiBindingRelations { functionDefinition?: PlatformFunctionDefinition | null; platformFunctionInvocationsByApiBindingId?: ConnectionResult; @@ -1891,6 +1950,7 @@ export interface PlatformFunctionDeploymentRelations { } export interface PlatformFunctionDeploymentEventRelations {} export interface PlatformFunctionExecutionLogRelations {} +export interface PlatformFunctionInvocationAttemptRelations {} export interface PlatformFunctionInvocationRelations { apiBinding?: PlatformFunctionApiBinding | null; } @@ -1913,6 +1973,7 @@ export interface PlatformResourceRelations { resourceDefinition?: PlatformResourceDefinition | null; platformResourceStatusChecksByResourceId?: ConnectionResult; } +export interface PlatformResourceDeclaredCapacityRelations {} export interface PlatformResourceDefinitionRelations { namespace?: PlatformNamespace | null; platformResourcesByResourceDefinitionId?: ConnectionResult; @@ -1927,7 +1988,7 @@ export interface PlatformResourceStatusCheckRelations { } export interface PlatformResourceUsageLogRelations {} export interface PlatformResourceUsageSummaryRelations {} -export interface PlatformResourceUtilizationDailyRelations {} +export interface PlatformResourceUtilizationRelations {} export interface PlatformResourcesHealthRelations {} export interface PlatformResourcesRequirementsStateRelations {} export interface PlatformResourcesResolvedRequirementRelations {} @@ -1945,6 +2006,7 @@ export interface ResourceRelations { resourceDefinition?: ResourceDefinition | null; resourceStatusChecks?: ConnectionResult; } +export interface ResourceDeclaredCapacityRelations {} export interface ResourceDefinitionRelations { namespace?: Namespace | null; resources?: ConnectionResult; @@ -1959,7 +2021,7 @@ export interface ResourceStatusCheckRelations { } export interface ResourceUsageLogRelations {} export interface ResourceUsageSummaryRelations {} -export interface ResourceUtilizationDailyRelations {} +export interface ResourceUtilizationRelations {} export interface ResourcesHealthRelations {} export interface ResourcesRequirementsStateRelations {} export interface ResourcesResolvedRequirementRelations {} @@ -1973,7 +2035,6 @@ export interface WebhookEventRelations { } // ============ Entity Types With Relations ============ export type DbPresetWithRelations = DbPreset & DbPresetRelations; -export type DeclaredCapacityWithRelations = DeclaredCapacity & DeclaredCapacityRelations; export type FunctionApiBindingWithRelations = FunctionApiBinding & FunctionApiBindingRelations; export type FunctionDefinitionWithRelations = FunctionDefinition & FunctionDefinitionRelations; export type FunctionDeploymentWithRelations = FunctionDeployment & FunctionDeploymentRelations; @@ -1992,6 +2053,8 @@ export type FunctionGraphExecutionOutputWithRelations = FunctionGraphExecutionOu export type FunctionGraphObjectWithRelations = FunctionGraphObject & FunctionGraphObjectRelations; export type FunctionGraphRefWithRelations = FunctionGraphRef & FunctionGraphRefRelations; export type FunctionGraphStoreWithRelations = FunctionGraphStore & FunctionGraphStoreRelations; +export type FunctionInvocationAttemptWithRelations = FunctionInvocationAttempt & + FunctionInvocationAttemptRelations; export type FunctionInvocationWithRelations = FunctionInvocation & FunctionInvocationRelations; export type GetAllTreeNodesRecordWithRelations = GetAllTreeNodesRecord & GetAllTreeNodesRecordRelations; @@ -2004,8 +2067,6 @@ export type InfraStoreWithRelations = InfraStore & InfraStoreRelations; export type IntegrationProviderWithRelations = IntegrationProvider & IntegrationProviderRelations; export type NamespaceWithRelations = Namespace & NamespaceRelations; export type NamespaceEventWithRelations = NamespaceEvent & NamespaceEventRelations; -export type PlatformDeclaredCapacityWithRelations = PlatformDeclaredCapacity & - PlatformDeclaredCapacityRelations; export type PlatformFunctionApiBindingWithRelations = PlatformFunctionApiBinding & PlatformFunctionApiBindingRelations; export type PlatformFunctionDefinitionWithRelations = PlatformFunctionDefinition & @@ -2016,6 +2077,8 @@ export type PlatformFunctionDeploymentEventWithRelations = PlatformFunctionDeplo PlatformFunctionDeploymentEventRelations; export type PlatformFunctionExecutionLogWithRelations = PlatformFunctionExecutionLog & PlatformFunctionExecutionLogRelations; +export type PlatformFunctionInvocationAttemptWithRelations = PlatformFunctionInvocationAttempt & + PlatformFunctionInvocationAttemptRelations; export type PlatformFunctionInvocationWithRelations = PlatformFunctionInvocation & PlatformFunctionInvocationRelations; export type PlatformInfraCommitWithRelations = PlatformInfraCommit & PlatformInfraCommitRelations; @@ -2028,6 +2091,8 @@ export type PlatformNamespaceWithRelations = PlatformNamespace & PlatformNamespa export type PlatformNamespaceEventWithRelations = PlatformNamespaceEvent & PlatformNamespaceEventRelations; export type PlatformResourceWithRelations = PlatformResource & PlatformResourceRelations; +export type PlatformResourceDeclaredCapacityWithRelations = PlatformResourceDeclaredCapacity & + PlatformResourceDeclaredCapacityRelations; export type PlatformResourceDefinitionWithRelations = PlatformResourceDefinition & PlatformResourceDefinitionRelations; export type PlatformResourceEventWithRelations = PlatformResourceEvent & @@ -2040,8 +2105,8 @@ export type PlatformResourceUsageLogWithRelations = PlatformResourceUsageLog & PlatformResourceUsageLogRelations; export type PlatformResourceUsageSummaryWithRelations = PlatformResourceUsageSummary & PlatformResourceUsageSummaryRelations; -export type PlatformResourceUtilizationDailyWithRelations = PlatformResourceUtilizationDaily & - PlatformResourceUtilizationDailyRelations; +export type PlatformResourceUtilizationWithRelations = PlatformResourceUtilization & + PlatformResourceUtilizationRelations; export type PlatformResourcesHealthWithRelations = PlatformResourcesHealth & PlatformResourcesHealthRelations; export type PlatformResourcesRequirementsStateWithRelations = PlatformResourcesRequirementsState & @@ -2053,6 +2118,8 @@ export type PlatformWebhookEndpointWithRelations = PlatformWebhookEndpoint & export type PlatformWebhookEventWithRelations = PlatformWebhookEvent & PlatformWebhookEventRelations; export type ResourceWithRelations = Resource & ResourceRelations; +export type ResourceDeclaredCapacityWithRelations = ResourceDeclaredCapacity & + ResourceDeclaredCapacityRelations; export type ResourceDefinitionWithRelations = ResourceDefinition & ResourceDefinitionRelations; export type ResourceEventWithRelations = ResourceEvent & ResourceEventRelations; export type ResourceInstallationWithRelations = ResourceInstallation & @@ -2061,8 +2128,7 @@ export type ResourceStatusCheckWithRelations = ResourceStatusCheck & ResourceSta export type ResourceUsageLogWithRelations = ResourceUsageLog & ResourceUsageLogRelations; export type ResourceUsageSummaryWithRelations = ResourceUsageSummary & ResourceUsageSummaryRelations; -export type ResourceUtilizationDailyWithRelations = ResourceUtilizationDaily & - ResourceUtilizationDailyRelations; +export type ResourceUtilizationWithRelations = ResourceUtilization & ResourceUtilizationRelations; export type ResourcesHealthWithRelations = ResourcesHealth & ResourcesHealthRelations; export type ResourcesRequirementsStateWithRelations = ResourcesRequirementsState & ResourcesRequirementsStateRelations; @@ -2084,21 +2150,6 @@ export type DbPresetSelect = { storeId?: boolean; updatedAt?: boolean; }; -export type DeclaredCapacitySelect = { - cpuLimitMillicores?: boolean; - cpuRequestMillicores?: boolean; - installationId?: boolean; - isTransient?: boolean; - kind?: boolean; - memoryLimitBytes?: boolean; - memoryRequestBytes?: boolean; - namespaceId?: boolean; - podCountMax?: boolean; - podCountMin?: boolean; - source?: boolean; - sourceId?: boolean; - storageSizeBytes?: boolean; -}; export type FunctionApiBindingSelect = { alias?: boolean; apiId?: boolean; @@ -2340,6 +2391,21 @@ export type FunctionGraphStoreSelect = { name?: boolean; scopeId?: boolean; }; +export type FunctionInvocationAttemptSelect = { + actorId?: boolean; + attempt?: boolean; + createdAt?: boolean; + databaseId?: boolean; + durationMs?: boolean; + error?: boolean; + errorDetail?: boolean; + id?: boolean; + invocationCreatedAt?: boolean; + invocationId?: boolean; + startedAt?: boolean; + success?: boolean; + taskIdentifier?: boolean; +}; export type FunctionInvocationSelect = { actorId?: boolean; apiBindingId?: boolean; @@ -2475,21 +2541,6 @@ export type NamespaceEventSelect = { metadata?: boolean; namespaceId?: boolean; }; -export type PlatformDeclaredCapacitySelect = { - cpuLimitMillicores?: boolean; - cpuRequestMillicores?: boolean; - installationId?: boolean; - isTransient?: boolean; - kind?: boolean; - memoryLimitBytes?: boolean; - memoryRequestBytes?: boolean; - namespaceId?: boolean; - podCountMax?: boolean; - podCountMin?: boolean; - source?: boolean; - sourceId?: boolean; - storageSizeBytes?: boolean; -}; export type PlatformFunctionApiBindingSelect = { alias?: boolean; apiId?: boolean; @@ -2508,6 +2559,7 @@ export type PlatformFunctionApiBindingSelect = { }; export type PlatformFunctionDefinitionSelect = { accessChannels?: boolean; + billable?: boolean; category?: boolean; concurrency?: boolean; cpuLimitMillicores?: boolean; @@ -2543,6 +2595,7 @@ export type PlatformFunctionDefinitionSelect = { runtime?: boolean; scaleMax?: boolean; scaleMin?: boolean; + system?: boolean; targetFunction?: boolean; targetSchema?: boolean; taskIdentifier?: boolean; @@ -2610,6 +2663,20 @@ export type PlatformFunctionExecutionLogSelect = { metadata?: boolean; taskIdentifier?: boolean; }; +export type PlatformFunctionInvocationAttemptSelect = { + actorId?: boolean; + attempt?: boolean; + createdAt?: boolean; + durationMs?: boolean; + error?: boolean; + errorDetail?: boolean; + id?: boolean; + invocationCreatedAt?: boolean; + invocationId?: boolean; + startedAt?: boolean; + success?: boolean; + taskIdentifier?: boolean; +}; export type PlatformFunctionInvocationSelect = { actorId?: boolean; apiBindingId?: boolean; @@ -2770,6 +2837,21 @@ export type PlatformResourceSelect = { orderBy?: PlatformResourceStatusCheckOrderBy[]; }; }; +export type PlatformResourceDeclaredCapacitySelect = { + cpuLimitMillicores?: boolean; + cpuRequestMillicores?: boolean; + installationId?: boolean; + isTransient?: boolean; + kind?: boolean; + memoryLimitBytes?: boolean; + memoryRequestBytes?: boolean; + namespaceId?: boolean; + podCountMax?: boolean; + podCountMin?: boolean; + source?: boolean; + sourceId?: boolean; + storageSizeBytes?: boolean; +}; export type PlatformResourceDefinitionSelect = { annotations?: boolean; createdAt?: boolean; @@ -2865,7 +2947,7 @@ export type PlatformResourceUsageSummarySelect = { runtimeSeconds?: boolean; sampleCount?: boolean; }; -export type PlatformResourceUtilizationDailySelect = { +export type PlatformResourceUtilizationSelect = { avgMemoryBytes?: boolean; cpuLimitMillicores?: boolean; cpuPeakUtilization?: boolean; @@ -3030,6 +3112,21 @@ export type ResourceSelect = { orderBy?: ResourceStatusCheckOrderBy[]; }; }; +export type ResourceDeclaredCapacitySelect = { + cpuLimitMillicores?: boolean; + cpuRequestMillicores?: boolean; + installationId?: boolean; + isTransient?: boolean; + kind?: boolean; + memoryLimitBytes?: boolean; + memoryRequestBytes?: boolean; + namespaceId?: boolean; + podCountMax?: boolean; + podCountMin?: boolean; + source?: boolean; + sourceId?: boolean; + storageSizeBytes?: boolean; +}; export type ResourceDefinitionSelect = { annotations?: boolean; createdAt?: boolean; @@ -3131,7 +3228,7 @@ export type ResourceUsageSummarySelect = { runtimeSeconds?: boolean; sampleCount?: boolean; }; -export type ResourceUtilizationDailySelect = { +export type ResourceUtilizationSelect = { avgMemoryBytes?: boolean; cpuLimitMillicores?: boolean; cpuPeakUtilization?: boolean; @@ -3283,40 +3380,6 @@ export interface DbPresetFilter { /** Filter by the object’s `updatedAt` field. */ updatedAt?: DatetimeFilter; } -export interface DeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: DeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: DeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: DeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} export interface FunctionApiBindingFilter { /** Filter by the object’s `alias` field. */ alias?: StringFilter; @@ -3795,6 +3858,40 @@ export interface FunctionGraphStoreFilter { /** Filter by the object’s `scopeId` field. */ scopeId?: UUIDFilter; } +export interface FunctionInvocationAttemptFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: FunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: FunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} export interface FunctionInvocationFilter { /** Filter by the object’s `actorId` field. */ actorId?: UUIDFilter; @@ -4049,40 +4146,6 @@ export interface NamespaceEventFilter { /** Checks for any expressions in this list. */ or?: NamespaceEventFilter[]; } -export interface PlatformDeclaredCapacityFilter { - /** Checks for all expressions in this list. */ - and?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `cpuLimitMillicores` field. */ - cpuLimitMillicores?: BigIntFilter; - /** Filter by the object’s `cpuRequestMillicores` field. */ - cpuRequestMillicores?: BigIntFilter; - /** Filter by the object’s `installationId` field. */ - installationId?: UUIDFilter; - /** Filter by the object’s `isTransient` field. */ - isTransient?: BooleanFilter; - /** Filter by the object’s `kind` field. */ - kind?: StringFilter; - /** Filter by the object’s `memoryLimitBytes` field. */ - memoryLimitBytes?: BigIntFilter; - /** Filter by the object’s `memoryRequestBytes` field. */ - memoryRequestBytes?: BigIntFilter; - /** Filter by the object’s `namespaceId` field. */ - namespaceId?: UUIDFilter; - /** Negates the expression. */ - not?: PlatformDeclaredCapacityFilter; - /** Checks for any expressions in this list. */ - or?: PlatformDeclaredCapacityFilter[]; - /** Filter by the object’s `podCountMax` field. */ - podCountMax?: IntFilter; - /** Filter by the object’s `podCountMin` field. */ - podCountMin?: IntFilter; - /** Filter by the object’s `source` field. */ - source?: StringFilter; - /** Filter by the object’s `sourceId` field. */ - sourceId?: UUIDFilter; - /** Filter by the object’s `storageSizeBytes` field. */ - storageSizeBytes?: BigIntFilter; -} export interface PlatformFunctionApiBindingFilter { /** Filter by the object’s `alias` field. */ alias?: StringFilter; @@ -4112,6 +4175,8 @@ export interface PlatformFunctionDefinitionFilter { accessChannels?: StringListFilter; /** Checks for all expressions in this list. */ and?: PlatformFunctionDefinitionFilter[]; + /** Filter by the object’s `billable` field. */ + billable?: BooleanFilter; /** Filter by the object’s `category` field. */ category?: StringFilter; /** Filter by the object’s `concurrency` field. */ @@ -4194,6 +4259,8 @@ export interface PlatformFunctionDefinitionFilter { scaleMax?: IntFilter; /** Filter by the object’s `scaleMin` field. */ scaleMin?: IntFilter; + /** Filter by the object’s `system` field. */ + system?: BooleanFilter; /** Filter by the object’s `targetFunction` field. */ targetFunction?: StringFilter; /** Filter by the object’s `targetSchema` field. */ @@ -4305,20 +4372,52 @@ export interface PlatformFunctionExecutionLogFilter { /** Filter by the object’s `taskIdentifier` field. */ taskIdentifier?: StringFilter; } -export interface PlatformFunctionInvocationFilter { +export interface PlatformFunctionInvocationAttemptFilter { /** Filter by the object’s `actorId` field. */ actorId?: UUIDFilter; /** Checks for all expressions in this list. */ - and?: PlatformFunctionInvocationFilter[]; - /** Filter by the object’s `apiBinding` relation. */ - apiBinding?: PlatformFunctionApiBindingFilter; - /** A related `apiBinding` exists. */ - apiBindingExists?: boolean; - /** Filter by the object’s `apiBindingId` field. */ - apiBindingId?: UUIDFilter; - /** Filter by the object’s `channel` field. */ - channel?: StringFilter; - /** Filter by the object’s `completedAt` field. */ + and?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `attempt` field. */ + attempt?: IntFilter; + /** Filter by the object’s `createdAt` field. */ + createdAt?: DatetimeFilter; + /** Filter by the object’s `durationMs` field. */ + durationMs?: IntFilter; + /** Filter by the object’s `error` field. */ + error?: StringFilter; + /** Filter by the object’s `errorDetail` field. */ + errorDetail?: JSONFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `invocationCreatedAt` field. */ + invocationCreatedAt?: DatetimeFilter; + /** Filter by the object’s `invocationId` field. */ + invocationId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformFunctionInvocationAttemptFilter; + /** Checks for any expressions in this list. */ + or?: PlatformFunctionInvocationAttemptFilter[]; + /** Filter by the object’s `startedAt` field. */ + startedAt?: DatetimeFilter; + /** Filter by the object’s `success` field. */ + success?: BooleanFilter; + /** Filter by the object’s `taskIdentifier` field. */ + taskIdentifier?: StringFilter; +} +export interface PlatformFunctionInvocationFilter { + /** Filter by the object’s `actorId` field. */ + actorId?: UUIDFilter; + /** Checks for all expressions in this list. */ + and?: PlatformFunctionInvocationFilter[]; + /** Filter by the object’s `apiBinding` relation. */ + apiBinding?: PlatformFunctionApiBindingFilter; + /** A related `apiBinding` exists. */ + apiBindingExists?: boolean; + /** Filter by the object’s `apiBindingId` field. */ + apiBindingId?: UUIDFilter; + /** Filter by the object’s `channel` field. */ + channel?: StringFilter; + /** Filter by the object’s `completedAt` field. */ completedAt?: DatetimeFilter; /** Filter by the object’s `createdAt` field. */ createdAt?: DatetimeFilter; @@ -4594,6 +4693,40 @@ export interface PlatformResourceFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +export interface PlatformResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: PlatformResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: PlatformResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} export interface PlatformResourceDefinitionFilter { /** Checks for all expressions in this list. */ and?: PlatformResourceDefinitionFilter[]; @@ -4776,9 +4909,9 @@ export interface PlatformResourceUsageSummaryFilter { /** Filter by the object’s `sampleCount` field. */ sampleCount?: IntFilter; } -export interface PlatformResourceUtilizationDailyFilter { +export interface PlatformResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: PlatformResourceUtilizationDailyFilter[]; + and?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -4810,9 +4943,9 @@ export interface PlatformResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: PlatformResourceUtilizationDailyFilter; + not?: PlatformResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: PlatformResourceUtilizationDailyFilter[]; + or?: PlatformResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -5090,6 +5223,40 @@ export interface ResourceFilter { /** Filter by the object’s `updatedBy` field. */ updatedBy?: UUIDFilter; } +export interface ResourceDeclaredCapacityFilter { + /** Checks for all expressions in this list. */ + and?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `cpuLimitMillicores` field. */ + cpuLimitMillicores?: BigIntFilter; + /** Filter by the object’s `cpuRequestMillicores` field. */ + cpuRequestMillicores?: BigIntFilter; + /** Filter by the object’s `installationId` field. */ + installationId?: UUIDFilter; + /** Filter by the object’s `isTransient` field. */ + isTransient?: BooleanFilter; + /** Filter by the object’s `kind` field. */ + kind?: StringFilter; + /** Filter by the object’s `memoryLimitBytes` field. */ + memoryLimitBytes?: BigIntFilter; + /** Filter by the object’s `memoryRequestBytes` field. */ + memoryRequestBytes?: BigIntFilter; + /** Filter by the object’s `namespaceId` field. */ + namespaceId?: UUIDFilter; + /** Negates the expression. */ + not?: ResourceDeclaredCapacityFilter; + /** Checks for any expressions in this list. */ + or?: ResourceDeclaredCapacityFilter[]; + /** Filter by the object’s `podCountMax` field. */ + podCountMax?: IntFilter; + /** Filter by the object’s `podCountMin` field. */ + podCountMin?: IntFilter; + /** Filter by the object’s `source` field. */ + source?: StringFilter; + /** Filter by the object’s `sourceId` field. */ + sourceId?: UUIDFilter; + /** Filter by the object’s `storageSizeBytes` field. */ + storageSizeBytes?: BigIntFilter; +} export interface ResourceDefinitionFilter { /** Checks for all expressions in this list. */ and?: ResourceDefinitionFilter[]; @@ -5284,9 +5451,9 @@ export interface ResourceUsageSummaryFilter { /** Filter by the object’s `sampleCount` field. */ sampleCount?: IntFilter; } -export interface ResourceUtilizationDailyFilter { +export interface ResourceUtilizationFilter { /** Checks for all expressions in this list. */ - and?: ResourceUtilizationDailyFilter[]; + and?: ResourceUtilizationFilter[]; /** Filter by the object’s `avgMemoryBytes` field. */ avgMemoryBytes?: BigIntFilter; /** Filter by the object’s `cpuLimitMillicores` field. */ @@ -5318,9 +5485,9 @@ export interface ResourceUtilizationDailyFilter { /** Filter by the object’s `namespaceId` field. */ namespaceId?: UUIDFilter; /** Negates the expression. */ - not?: ResourceUtilizationDailyFilter; + not?: ResourceUtilizationFilter; /** Checks for any expressions in this list. */ - or?: ResourceUtilizationDailyFilter[]; + or?: ResourceUtilizationFilter[]; /** Filter by the object’s `replicas` field. */ replicas?: IntFilter; /** Filter by the object’s `resourceId` field. */ @@ -5553,34 +5720,6 @@ export type DbPresetOrderBy = | 'STORE_ID_DESC' | 'UPDATED_AT_ASC' | 'UPDATED_AT_DESC'; -export type DeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; export type FunctionApiBindingOrderBy = | 'ALIAS_ASC' | 'ALIAS_DESC' @@ -5985,6 +6124,36 @@ export type FunctionGraphStoreOrderBy = | 'PRIMARY_KEY_DESC' | 'SCOPE_ID_ASC' | 'SCOPE_ID_DESC'; +export type FunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; export type FunctionInvocationOrderBy = | 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' @@ -6189,34 +6358,6 @@ export type NamespaceEventOrderBy = | 'NATURAL' | 'PRIMARY_KEY_ASC' | 'PRIMARY_KEY_DESC'; -export type PlatformDeclaredCapacityOrderBy = - | 'CPU_LIMIT_MILLICORES_ASC' - | 'CPU_LIMIT_MILLICORES_DESC' - | 'CPU_REQUEST_MILLICORES_ASC' - | 'CPU_REQUEST_MILLICORES_DESC' - | 'INSTALLATION_ID_ASC' - | 'INSTALLATION_ID_DESC' - | 'IS_TRANSIENT_ASC' - | 'IS_TRANSIENT_DESC' - | 'KIND_ASC' - | 'KIND_DESC' - | 'MEMORY_LIMIT_BYTES_ASC' - | 'MEMORY_LIMIT_BYTES_DESC' - | 'MEMORY_REQUEST_BYTES_ASC' - | 'MEMORY_REQUEST_BYTES_DESC' - | 'NAMESPACE_ID_ASC' - | 'NAMESPACE_ID_DESC' - | 'NATURAL' - | 'POD_COUNT_MAX_ASC' - | 'POD_COUNT_MAX_DESC' - | 'POD_COUNT_MIN_ASC' - | 'POD_COUNT_MIN_DESC' - | 'SOURCE_ASC' - | 'SOURCE_DESC' - | 'SOURCE_ID_ASC' - | 'SOURCE_ID_DESC' - | 'STORAGE_SIZE_BYTES_ASC' - | 'STORAGE_SIZE_BYTES_DESC'; export type PlatformFunctionApiBindingOrderBy = | 'ALIAS_ASC' | 'ALIAS_DESC' @@ -6234,6 +6375,8 @@ export type PlatformFunctionApiBindingOrderBy = export type PlatformFunctionDefinitionOrderBy = | 'ACCESS_CHANNELS_ASC' | 'ACCESS_CHANNELS_DESC' + | 'BILLABLE_ASC' + | 'BILLABLE_DESC' | 'CATEGORY_ASC' | 'CATEGORY_DESC' | 'CONCURRENCY_ASC' @@ -6307,6 +6450,8 @@ export type PlatformFunctionDefinitionOrderBy = | 'SCALE_MAX_DESC' | 'SCALE_MIN_ASC' | 'SCALE_MIN_DESC' + | 'SYSTEM_ASC' + | 'SYSTEM_DESC' | 'TARGET_FUNCTION_ASC' | 'TARGET_FUNCTION_DESC' | 'TARGET_SCHEMA_ASC' @@ -6403,6 +6548,34 @@ export type PlatformFunctionExecutionLogOrderBy = | 'PRIMARY_KEY_DESC' | 'TASK_IDENTIFIER_ASC' | 'TASK_IDENTIFIER_DESC'; +export type PlatformFunctionInvocationAttemptOrderBy = + | 'ACTOR_ID_ASC' + | 'ACTOR_ID_DESC' + | 'ATTEMPT_ASC' + | 'ATTEMPT_DESC' + | 'CREATED_AT_ASC' + | 'CREATED_AT_DESC' + | 'DURATION_MS_ASC' + | 'DURATION_MS_DESC' + | 'ERROR_ASC' + | 'ERROR_DESC' + | 'ERROR_DETAIL_ASC' + | 'ERROR_DETAIL_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'INVOCATION_CREATED_AT_ASC' + | 'INVOCATION_CREATED_AT_DESC' + | 'INVOCATION_ID_ASC' + | 'INVOCATION_ID_DESC' + | 'NATURAL' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'STARTED_AT_ASC' + | 'STARTED_AT_DESC' + | 'SUCCESS_ASC' + | 'SUCCESS_DESC' + | 'TASK_IDENTIFIER_ASC' + | 'TASK_IDENTIFIER_DESC'; export type PlatformFunctionInvocationOrderBy = | 'ACTOR_ID_ASC' | 'ACTOR_ID_DESC' @@ -6627,6 +6800,34 @@ export type PlatformResourceOrderBy = | 'UPDATED_AT_DESC' | 'UPDATED_BY_ASC' | 'UPDATED_BY_DESC'; +export type PlatformResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; export type PlatformResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' @@ -6775,7 +6976,7 @@ export type PlatformResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -export type PlatformResourceUtilizationDailyOrderBy = +export type PlatformResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -7037,6 +7238,34 @@ export type ResourceOrderBy = | 'UPDATED_AT_DESC' | 'UPDATED_BY_ASC' | 'UPDATED_BY_DESC'; +export type ResourceDeclaredCapacityOrderBy = + | 'CPU_LIMIT_MILLICORES_ASC' + | 'CPU_LIMIT_MILLICORES_DESC' + | 'CPU_REQUEST_MILLICORES_ASC' + | 'CPU_REQUEST_MILLICORES_DESC' + | 'INSTALLATION_ID_ASC' + | 'INSTALLATION_ID_DESC' + | 'IS_TRANSIENT_ASC' + | 'IS_TRANSIENT_DESC' + | 'KIND_ASC' + | 'KIND_DESC' + | 'MEMORY_LIMIT_BYTES_ASC' + | 'MEMORY_LIMIT_BYTES_DESC' + | 'MEMORY_REQUEST_BYTES_ASC' + | 'MEMORY_REQUEST_BYTES_DESC' + | 'NAMESPACE_ID_ASC' + | 'NAMESPACE_ID_DESC' + | 'NATURAL' + | 'POD_COUNT_MAX_ASC' + | 'POD_COUNT_MAX_DESC' + | 'POD_COUNT_MIN_ASC' + | 'POD_COUNT_MIN_DESC' + | 'SOURCE_ASC' + | 'SOURCE_DESC' + | 'SOURCE_ID_ASC' + | 'SOURCE_ID_DESC' + | 'STORAGE_SIZE_BYTES_ASC' + | 'STORAGE_SIZE_BYTES_DESC'; export type ResourceDefinitionOrderBy = | 'ANNOTATIONS_ASC' | 'ANNOTATIONS_DESC' @@ -7197,7 +7426,7 @@ export type ResourceUsageSummaryOrderBy = | 'RUNTIME_SECONDS_DESC' | 'SAMPLE_COUNT_ASC' | 'SAMPLE_COUNT_DESC'; -export type ResourceUtilizationDailyOrderBy = +export type ResourceUtilizationOrderBy = | 'AVG_MEMORY_BYTES_ASC' | 'AVG_MEMORY_BYTES_DESC' | 'CPU_LIMIT_MILLICORES_ASC' @@ -7407,72 +7636,30 @@ export interface CreateDbPresetInput { dbPreset: { active?: boolean; commitId?: string; - definition: Record; - description?: string; - label?: string; - modulesHash?: string; - slug: string; - storeId?: string; - }; -} -export interface DbPresetPatch { - active?: boolean | null; - commitId?: string | null; - definition?: Record | null; - description?: string | null; - label?: string | null; - modulesHash?: string | null; - slug?: string | null; - storeId?: string | null; -} -export interface UpdateDbPresetInput { - clientMutationId?: string; - id: string; - dbPresetPatch: DbPresetPatch; -} -export interface DeleteDbPresetInput { - clientMutationId?: string; - id: string; -} -export interface CreateDeclaredCapacityInput { - clientMutationId?: string; - declaredCapacity: { - cpuLimitMillicores?: string; - cpuRequestMillicores?: string; - installationId: string; - isTransient?: boolean; - kind?: string; - memoryLimitBytes?: string; - memoryRequestBytes?: string; - namespaceId: string; - podCountMax?: number; - podCountMin?: number; - source?: string; - sourceId: string; - storageSizeBytes?: string; - }; -} -export interface DeclaredCapacityPatch { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; + definition: Record; + description?: string; + label?: string; + modulesHash?: string; + slug: string; + storeId?: string; + }; +} +export interface DbPresetPatch { + active?: boolean | null; + commitId?: string | null; + definition?: Record | null; + description?: string | null; + label?: string | null; + modulesHash?: string | null; + slug?: string | null; + storeId?: string | null; } -export interface UpdateDeclaredCapacityInput { +export interface UpdateDbPresetInput { clientMutationId?: string; id: string; - declaredCapacityPatch: DeclaredCapacityPatch; + dbPresetPatch: DbPresetPatch; } -export interface DeleteDeclaredCapacityInput { +export interface DeleteDbPresetInput { clientMutationId?: string; id: string; } @@ -7536,7 +7723,6 @@ export interface CreateFunctionDefinitionInput { scaleMin?: number; targetFunction?: string; targetSchema?: string; - taskIdentifier: string; timeoutSeconds?: number; volatile?: boolean; }; @@ -7575,7 +7761,6 @@ export interface FunctionDefinitionPatch { scaleMin?: number | null; targetFunction?: string | null; targetSchema?: string | null; - taskIdentifier?: string | null; timeoutSeconds?: number | null; volatile?: boolean | null; } @@ -7978,6 +8163,44 @@ export interface DeleteFunctionGraphStoreInput { clientMutationId?: string; id: string; } +export interface CreateFunctionInvocationAttemptInput { + clientMutationId?: string; + functionInvocationAttempt: { + actorId?: string; + attempt: number; + databaseId: string; + durationMs?: number; + error?: string; + errorDetail?: Record; + invocationCreatedAt: string; + invocationId: string; + startedAt?: string; + success: boolean; + taskIdentifier: string; + }; +} +export interface FunctionInvocationAttemptPatch { + actorId?: string | null; + attempt?: number | null; + databaseId?: string | null; + durationMs?: number | null; + error?: string | null; + errorDetail?: Record | null; + invocationCreatedAt?: string | null; + invocationId?: string | null; + startedAt?: string | null; + success?: boolean | null; + taskIdentifier?: string | null; +} +export interface UpdateFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; + functionInvocationAttemptPatch: FunctionInvocationAttemptPatch; +} +export interface DeleteFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; +} export interface CreateFunctionInvocationInput { clientMutationId?: string; functionInvocation: { @@ -8271,48 +8494,6 @@ export interface DeleteNamespaceEventInput { clientMutationId?: string; id: string; } -export interface CreatePlatformDeclaredCapacityInput { - clientMutationId?: string; - platformDeclaredCapacity: { - cpuLimitMillicores?: string; - cpuRequestMillicores?: string; - installationId: string; - isTransient?: boolean; - kind?: string; - memoryLimitBytes?: string; - memoryRequestBytes?: string; - namespaceId: string; - podCountMax?: number; - podCountMin?: number; - source?: string; - sourceId: string; - storageSizeBytes?: string; - }; -} -export interface PlatformDeclaredCapacityPatch { - cpuLimitMillicores?: string | null; - cpuRequestMillicores?: string | null; - installationId?: string | null; - isTransient?: boolean | null; - kind?: string | null; - memoryLimitBytes?: string | null; - memoryRequestBytes?: string | null; - namespaceId?: string | null; - podCountMax?: number | null; - podCountMin?: number | null; - source?: string | null; - sourceId?: string | null; - storageSizeBytes?: string | null; -} -export interface UpdatePlatformDeclaredCapacityInput { - clientMutationId?: string; - id: string; - platformDeclaredCapacityPatch: PlatformDeclaredCapacityPatch; -} -export interface DeletePlatformDeclaredCapacityInput { - clientMutationId?: string; - id: string; -} export interface CreatePlatformFunctionApiBindingInput { clientMutationId?: string; platformFunctionApiBinding: { @@ -8341,6 +8522,7 @@ export interface CreatePlatformFunctionDefinitionInput { clientMutationId?: string; platformFunctionDefinition: { accessChannels?: string[]; + billable?: boolean; category: string; concurrency?: number; description?: string; @@ -8370,15 +8552,16 @@ export interface CreatePlatformFunctionDefinitionInput { runtime?: string; scaleMax?: number; scaleMin?: number; + system?: boolean; targetFunction?: string; targetSchema?: string; - taskIdentifier: string; timeoutSeconds?: number; volatile?: boolean; }; } export interface PlatformFunctionDefinitionPatch { accessChannels?: string[] | null; + billable?: boolean | null; category?: string | null; concurrency?: number | null; description?: string | null; @@ -8408,9 +8591,9 @@ export interface PlatformFunctionDefinitionPatch { runtime?: string | null; scaleMax?: number | null; scaleMin?: number | null; + system?: boolean | null; targetFunction?: string | null; targetSchema?: string | null; - taskIdentifier?: string | null; timeoutSeconds?: number | null; volatile?: boolean | null; } @@ -8529,6 +8712,42 @@ export interface DeletePlatformFunctionExecutionLogInput { clientMutationId?: string; id: string; } +export interface CreatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + platformFunctionInvocationAttempt: { + actorId?: string; + attempt: number; + durationMs?: number; + error?: string; + errorDetail?: Record; + invocationCreatedAt: string; + invocationId: string; + startedAt?: string; + success: boolean; + taskIdentifier: string; + }; +} +export interface PlatformFunctionInvocationAttemptPatch { + actorId?: string | null; + attempt?: number | null; + durationMs?: number | null; + error?: string | null; + errorDetail?: Record | null; + invocationCreatedAt?: string | null; + invocationId?: string | null; + startedAt?: string | null; + success?: boolean | null; + taskIdentifier?: string | null; +} +export interface UpdatePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; + platformFunctionInvocationAttemptPatch: PlatformFunctionInvocationAttemptPatch; +} +export interface DeletePlatformFunctionInvocationAttemptInput { + clientMutationId?: string; + id: string; +} export interface CreatePlatformFunctionInvocationInput { clientMutationId?: string; platformFunctionInvocation: { @@ -8815,6 +9034,48 @@ export interface DeletePlatformResourceInput { clientMutationId?: string; id: string; } +export interface CreatePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + platformResourceDeclaredCapacity: { + cpuLimitMillicores?: string; + cpuRequestMillicores?: string; + installationId: string; + isTransient?: boolean; + kind?: string; + memoryLimitBytes?: string; + memoryRequestBytes?: string; + namespaceId: string; + podCountMax?: number; + podCountMin?: number; + source?: string; + sourceId: string; + storageSizeBytes?: string; + }; +} +export interface PlatformResourceDeclaredCapacityPatch { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} +export interface UpdatePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; + platformResourceDeclaredCapacityPatch: PlatformResourceDeclaredCapacityPatch; +} +export interface DeletePlatformResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; +} export interface CreatePlatformResourceDefinitionInput { clientMutationId?: string; platformResourceDefinition: { @@ -9013,9 +9274,9 @@ export interface DeletePlatformResourceUsageSummaryInput { clientMutationId?: string; id: string; } -export interface CreatePlatformResourceUtilizationDailyInput { +export interface CreatePlatformResourceUtilizationInput { clientMutationId?: string; - platformResourceUtilizationDaily: { + platformResourceUtilization: { avgMemoryBytes?: string; cpuLimitMillicores?: string; cpuPeakUtilization?: string; @@ -9037,7 +9298,7 @@ export interface CreatePlatformResourceUtilizationDailyInput { sampleCount?: number; }; } -export interface PlatformResourceUtilizationDailyPatch { +export interface PlatformResourceUtilizationPatch { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -9058,12 +9319,12 @@ export interface PlatformResourceUtilizationDailyPatch { runtimeSeconds?: string | null; sampleCount?: number | null; } -export interface UpdatePlatformResourceUtilizationDailyInput { +export interface UpdatePlatformResourceUtilizationInput { clientMutationId?: string; id: string; - platformResourceUtilizationDailyPatch: PlatformResourceUtilizationDailyPatch; + platformResourceUtilizationPatch: PlatformResourceUtilizationPatch; } -export interface DeletePlatformResourceUtilizationDailyInput { +export interface DeletePlatformResourceUtilizationInput { clientMutationId?: string; id: string; } @@ -9329,6 +9590,48 @@ export interface DeleteResourceInput { clientMutationId?: string; id: string; } +export interface CreateResourceDeclaredCapacityInput { + clientMutationId?: string; + resourceDeclaredCapacity: { + cpuLimitMillicores?: string; + cpuRequestMillicores?: string; + installationId: string; + isTransient?: boolean; + kind?: string; + memoryLimitBytes?: string; + memoryRequestBytes?: string; + namespaceId: string; + podCountMax?: number; + podCountMin?: number; + source?: string; + sourceId: string; + storageSizeBytes?: string; + }; +} +export interface ResourceDeclaredCapacityPatch { + cpuLimitMillicores?: string | null; + cpuRequestMillicores?: string | null; + installationId?: string | null; + isTransient?: boolean | null; + kind?: string | null; + memoryLimitBytes?: string | null; + memoryRequestBytes?: string | null; + namespaceId?: string | null; + podCountMax?: number | null; + podCountMin?: number | null; + source?: string | null; + sourceId?: string | null; + storageSizeBytes?: string | null; +} +export interface UpdateResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; + resourceDeclaredCapacityPatch: ResourceDeclaredCapacityPatch; +} +export interface DeleteResourceDeclaredCapacityInput { + clientMutationId?: string; + id: string; +} export interface CreateResourceDefinitionInput { clientMutationId?: string; resourceDefinition: { @@ -9539,9 +9842,9 @@ export interface DeleteResourceUsageSummaryInput { clientMutationId?: string; id: string; } -export interface CreateResourceUtilizationDailyInput { +export interface CreateResourceUtilizationInput { clientMutationId?: string; - resourceUtilizationDaily: { + resourceUtilization: { avgMemoryBytes?: string; cpuLimitMillicores?: string; cpuPeakUtilization?: string; @@ -9563,7 +9866,7 @@ export interface CreateResourceUtilizationDailyInput { sampleCount?: number; }; } -export interface ResourceUtilizationDailyPatch { +export interface ResourceUtilizationPatch { avgMemoryBytes?: string | null; cpuLimitMillicores?: string | null; cpuPeakUtilization?: string | null; @@ -9584,12 +9887,12 @@ export interface ResourceUtilizationDailyPatch { runtimeSeconds?: string | null; sampleCount?: number | null; } -export interface UpdateResourceUtilizationDailyInput { +export interface UpdateResourceUtilizationInput { clientMutationId?: string; id: string; - resourceUtilizationDailyPatch: ResourceUtilizationDailyPatch; + resourceUtilizationPatch: ResourceUtilizationPatch; } -export interface DeleteResourceUtilizationDailyInput { +export interface DeleteResourceUtilizationInput { clientMutationId?: string; id: string; } @@ -9986,24 +10289,24 @@ export interface PlatformInfraSetDataAtPathInput { } export interface PlatformResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: Record; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: Record; + slug?: string; } export interface PlatformResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface PlatformResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: Record; + newParams?: Record; + targetInstallationId?: string; } export interface ProvisionBucketInput { /** The logical bucket key (e.g., "public", "private") */ @@ -10016,24 +10319,24 @@ export interface ProvisionBucketInput { } export interface ResourceInstallationsInstallInput { clientMutationId?: string; - pName?: string; - pNamespaceId?: string; - pParams?: Record; - pSlug?: string; + name?: string; + namespaceId?: string; + newParams?: Record; + slug?: string; } export interface ResourceInstallationsRollbackInput { clientMutationId?: string; - pCommitId?: string; - pInstallationId?: string; + commitId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUninstallInput { clientMutationId?: string; - pInstallationId?: string; + targetInstallationId?: string; } export interface ResourceInstallationsUpgradeInput { clientMutationId?: string; - pInstallationId?: string; - pParams?: Record; + newParams?: Record; + targetInstallationId?: string; } export interface SaveGraphInput { clientMutationId?: string; @@ -10483,8 +10786,6 @@ export interface FunctionDefinitionInput { targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -10756,6 +11057,35 @@ export interface FunctionGraphStoreInput { /** Opaque store partition key for the global tier */ scopeId: string; } +/** An input for mutations affecting `FunctionInvocationAttempt` */ +export interface FunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Database that owns this resource (database-scoped isolation) */ + databaseId: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} /** An input for mutations affecting `FunctionInvocation` */ export interface FunctionInvocationInput { /** Who triggered the invocation (NULL for system/cron) */ @@ -10774,7 +11104,7 @@ export interface FunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -10794,7 +11124,7 @@ export interface FunctionInvocationInput { result?: Record; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -10946,6 +11276,8 @@ export interface PlatformFunctionApiBindingInput { export interface PlatformFunctionDefinitionInput { /** Invocation channels this function may be exposed through (api, graph, cron, sync, webhook). Internal worker dispatch is implicit and never listed. Default [] = worker only. */ accessChannels?: string[]; + /** Whether executions are metered through the invocation ledger and billing quota gate */ + billable?: boolean; /** Function task category (e.g. email, embed, chunk, custom) */ category: string; /** Knative containerConcurrency — max concurrent requests per pod instance */ @@ -11006,12 +11338,12 @@ export interface PlatformFunctionDefinitionInput { scaleMax?: number; /** Minimum pod count for Knative autoscaling (minScale) */ scaleMin?: number; + /** Platform system definition: its task_identifier cannot be shadowed by non-platform registration */ + system?: boolean; /** Name of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetFunction?: string; /** Schema of the SQL function to invoke when runtime=sql (direct mode). NULL for module mode and other runtimes. */ targetSchema?: string; - /** Computed routing slug: category:name (used by Knative job worker for dispatch) */ - taskIdentifier: string; /** Knative request timeout in seconds */ timeoutSeconds?: number; updatedAt?: string; @@ -11096,6 +11428,33 @@ export interface PlatformFunctionExecutionLogInput { /** Function routing key (NULL for generic job logs) */ taskIdentifier?: string; } +/** An input for mutations affecting `PlatformFunctionInvocationAttempt` */ +export interface PlatformFunctionInvocationAttemptInput { + /** Who triggered the invocation (NULL for system/cron) */ + actorId?: string; + /** 1-based attempt number for this invocation */ + attempt: number; + /** When the attempt result was recorded (partition key) */ + createdAt?: string; + /** Wall-clock attempt time in milliseconds */ + durationMs?: number; + /** Error message when the attempt failed */ + error?: string; + /** Structured error context (stack, code, provider response) */ + errorDetail?: Record; + /** Unique attempt identifier */ + id?: string; + /** created_at of the referenced invocation (partition-pruned lookups against the invocations PK) */ + invocationCreatedAt: string; + /** Invocation this attempt belongs to (soft reference paired with invocation_created_at) */ + invocationId: string; + /** When the attempt began executing */ + startedAt?: string; + /** Whether this attempt completed successfully */ + success: boolean; + /** Function routing slug (denormalized from the invocation) */ + taskIdentifier: string; +} /** An input for mutations affecting `PlatformFunctionInvocation` */ export interface PlatformFunctionInvocationInput { /** Who triggered the invocation (NULL for system/cron) */ @@ -11112,7 +11471,7 @@ export interface PlatformFunctionInvocationInput { definitionScope?: string; /** Wall-clock execution time in milliseconds */ durationMs?: number; - /** Error message when status is failed */ + /** Error message when status is failed, or the reason the run was skipped when status is skipped */ error?: string; /** Function definition this invocation ran (soft cross-scope ref; paired with definition_scope). task_identifier stays as the audit slug. */ functionDefinitionId?: string; @@ -11132,7 +11491,7 @@ export interface PlatformFunctionInvocationInput { result?: Record; /** When execution started */ startedAt?: string; - /** Lifecycle: pending → running → completed/failed/cancelled */ + /** Lifecycle: pending → running → completed/failed/cancelled; skipped = never ran (a gate rejected the intended run) */ status?: string; /** Function routing slug (category:name). Denormalized from the definition — must match the row referenced by function_definition_id when that is set. */ taskIdentifier: string; @@ -11253,7 +11612,7 @@ export interface PlatformResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: Record; @@ -11295,7 +11654,7 @@ export interface PlatformResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: Record; @@ -11409,7 +11768,7 @@ export interface PlatformResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** An input for mutations affecting `PlatformResourceUsageSummary` */ @@ -11496,7 +11855,7 @@ export interface ResourceInput { installationId?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer */ kind: string; /** Key/value pairs for selecting and filtering resources */ labels?: Record; @@ -11540,7 +11899,7 @@ export interface ResourceDefinitionInput { id?: string; /** Provider slugs (e.g. mailgun, postgres) associated with this resource definition. The UI uses this to auto-fill required_secrets and required_configs from integration_providers. */ integrations?: string[]; - /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, or custom kinds */ + /** Resource kind: Deployment, StatefulSet, Job, Service, Ingress, Certificate, ClusterIssuer, or custom kinds */ kind: string; /** Key/value pairs for selecting and filtering definitions */ labels?: Record; @@ -11643,7 +12002,7 @@ export interface ResourceUsageLogInput { resourceId?: string; /** Sample timestamp (partition key) — end of the measured interval */ sampledAt?: string; - /** Sample producer: self (workload heartbeat) or observer (reconciler) */ + /** Sample producer: self (workload heartbeat), observer (reconciler), or prometheus (namespace-grain usage collector) */ source: string; } /** An input for mutations affecting `ResourceUsageSummary` */ @@ -11925,6 +12284,8 @@ export interface PlatformFunctionDefinitionFilter { accessChannels?: StringListFilter; /** Checks for all expressions in this list. */ and?: PlatformFunctionDefinitionFilter[]; + /** Filter by the object’s `billable` field. */ + billable?: BooleanFilter; /** Filter by the object’s `category` field. */ category?: StringFilter; /** Filter by the object’s `concurrency` field. */ @@ -12007,6 +12368,8 @@ export interface PlatformFunctionDefinitionFilter { scaleMax?: IntFilter; /** Filter by the object’s `scaleMin` field. */ scaleMin?: IntFilter; + /** Filter by the object’s `system` field. */ + system?: BooleanFilter; /** Filter by the object’s `targetFunction` field. */ targetFunction?: StringFilter; /** Filter by the object’s `targetSchema` field. */ @@ -14069,6 +14432,51 @@ export type DeleteFunctionGraphStorePayloadSelect = { select: FunctionGraphStoreEdgeSelect; }; }; +export interface CreateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was created by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type CreateFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; +export interface UpdateFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was updated by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type UpdateFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; +export interface DeleteFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `FunctionInvocationAttempt` that was deleted by this mutation. */ + functionInvocationAttempt?: FunctionInvocationAttempt | null; + functionInvocationAttemptEdge?: FunctionInvocationAttemptEdge | null; +} +export type DeleteFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + functionInvocationAttempt?: { + select: FunctionInvocationAttemptSelect; + }; + functionInvocationAttemptEdge?: { + select: FunctionInvocationAttemptEdgeSelect; + }; +}; export interface CreateFunctionInvocationPayload { clientMutationId?: string | null; /** The `FunctionInvocation` that was created by this mutation. */ @@ -14654,6 +15062,51 @@ export type DeletePlatformFunctionExecutionLogPayloadSelect = { select: PlatformFunctionExecutionLogEdgeSelect; }; }; +export interface CreatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was created by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type CreatePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; +export interface UpdatePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was updated by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type UpdatePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; +export interface DeletePlatformFunctionInvocationAttemptPayload { + clientMutationId?: string | null; + /** The `PlatformFunctionInvocationAttempt` that was deleted by this mutation. */ + platformFunctionInvocationAttempt?: PlatformFunctionInvocationAttempt | null; + platformFunctionInvocationAttemptEdge?: PlatformFunctionInvocationAttemptEdge | null; +} +export type DeletePlatformFunctionInvocationAttemptPayloadSelect = { + clientMutationId?: boolean; + platformFunctionInvocationAttempt?: { + select: PlatformFunctionInvocationAttemptSelect; + }; + platformFunctionInvocationAttemptEdge?: { + select: PlatformFunctionInvocationAttemptEdgeSelect; + }; +}; export interface CreatePlatformFunctionInvocationPayload { clientMutationId?: string | null; /** The `PlatformFunctionInvocation` that was created by this mutation. */ @@ -15947,6 +16400,18 @@ export type FunctionGraphStoreEdgeSelect = { select: FunctionGraphStoreSelect; }; }; +/** A `FunctionInvocationAttempt` edge in the connection. */ +export interface FunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `FunctionInvocationAttempt` at the end of the edge. */ + node?: FunctionInvocationAttempt | null; +} +export type FunctionInvocationAttemptEdgeSelect = { + cursor?: boolean; + node?: { + select: FunctionInvocationAttemptSelect; + }; +}; /** A `FunctionInvocation` edge in the connection. */ export interface FunctionInvocationEdge { cursor?: string | null; @@ -16103,6 +16568,18 @@ export type PlatformFunctionExecutionLogEdgeSelect = { select: PlatformFunctionExecutionLogSelect; }; }; +/** A `PlatformFunctionInvocationAttempt` edge in the connection. */ +export interface PlatformFunctionInvocationAttemptEdge { + cursor?: string | null; + /** The `PlatformFunctionInvocationAttempt` at the end of the edge. */ + node?: PlatformFunctionInvocationAttempt | null; +} +export type PlatformFunctionInvocationAttemptEdgeSelect = { + cursor?: boolean; + node?: { + select: PlatformFunctionInvocationAttemptSelect; + }; +}; /** A `PlatformFunctionInvocation` edge in the connection. */ export interface PlatformFunctionInvocationEdge { cursor?: string | null; diff --git a/sdk/constructive-sdk/src/compute/orm/models/declaredCapacity.ts b/sdk/constructive-sdk/src/compute/orm/models/declaredCapacity.ts deleted file mode 100644 index 69304243f..000000000 --- a/sdk/constructive-sdk/src/compute/orm/models/declaredCapacity.ts +++ /dev/null @@ -1,134 +0,0 @@ -/** - * DeclaredCapacity model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - DeclaredCapacity, - DeclaredCapacityWithRelations, - DeclaredCapacitySelect, - DeclaredCapacityFilter, - DeclaredCapacityOrderBy, - CreateDeclaredCapacityInput, - UpdateDeclaredCapacityInput, - DeclaredCapacityPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class DeclaredCapacityModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - declaredCapacities: ConnectionResult>; - }> { - const { document, variables } = buildFindManyDocument( - 'DeclaredCapacity', - 'declaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'DeclaredCapacityFilter', - 'DeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'DeclaredCapacity', - fieldName: 'declaredCapacities', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - declaredCapacity: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'DeclaredCapacity', - 'declaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'DeclaredCapacityFilter', - 'DeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'DeclaredCapacity', - fieldName: 'declaredCapacity', - document, - variables, - transform: (data: { - declaredCapacities?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - declaredCapacity: data.declaredCapacities?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createDeclaredCapacity: { - declaredCapacity: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'DeclaredCapacity', - 'createDeclaredCapacity', - 'declaredCapacity', - args.select, - args.data, - 'CreateDeclaredCapacityInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'DeclaredCapacity', - fieldName: 'createDeclaredCapacity', - document, - variables, - }); - } -} diff --git a/sdk/constructive-sdk/src/compute/orm/models/functionInvocationAttempt.ts b/sdk/constructive-sdk/src/compute/orm/models/functionInvocationAttempt.ts new file mode 100644 index 000000000..710ddec0b --- /dev/null +++ b/sdk/constructive-sdk/src/compute/orm/models/functionInvocationAttempt.ts @@ -0,0 +1,252 @@ +/** + * FunctionInvocationAttempt model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + FunctionInvocationAttempt, + FunctionInvocationAttemptWithRelations, + FunctionInvocationAttemptSelect, + FunctionInvocationAttemptFilter, + FunctionInvocationAttemptOrderBy, + CreateFunctionInvocationAttemptInput, + UpdateFunctionInvocationAttemptInput, + FunctionInvocationAttemptPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class FunctionInvocationAttemptModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempts', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempt: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempt', + document, + variables, + transform: (data: { + functionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + functionInvocationAttempt: data.functionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + functionInvocationAttempt: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'FunctionInvocationAttempt', + 'functionInvocationAttempts', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'FunctionInvocationAttemptFilter', + 'FunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'FunctionInvocationAttempt', + fieldName: 'functionInvocationAttempt', + document, + variables, + transform: (data: { + functionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + functionInvocationAttempt: data.functionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'FunctionInvocationAttempt', + 'createFunctionInvocationAttempt', + 'functionInvocationAttempt', + args.select, + args.data, + 'CreateFunctionInvocationAttemptInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'createFunctionInvocationAttempt', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + createdAt: string; + }, + FunctionInvocationAttemptPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'FunctionInvocationAttempt', + 'updateFunctionInvocationAttempt', + 'functionInvocationAttempt', + args.select, + args.where.id, + args.data, + 'UpdateFunctionInvocationAttemptInput', + 'id', + 'functionInvocationAttemptPatch', + connectionFieldsMap, + { + createdAt: args.where.createdAt, + } + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'updateFunctionInvocationAttempt', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + createdAt: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteFunctionInvocationAttempt: { + functionInvocationAttempt: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'FunctionInvocationAttempt', + 'deleteFunctionInvocationAttempt', + 'functionInvocationAttempt', + { + id: args.where.id, + createdAt: args.where.createdAt, + }, + 'DeleteFunctionInvocationAttemptInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'FunctionInvocationAttempt', + fieldName: 'deleteFunctionInvocationAttempt', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/compute/orm/models/index.ts b/sdk/constructive-sdk/src/compute/orm/models/index.ts index 3f21b469c..c06f5f3db 100644 --- a/sdk/constructive-sdk/src/compute/orm/models/index.ts +++ b/sdk/constructive-sdk/src/compute/orm/models/index.ts @@ -4,7 +4,6 @@ * DO NOT EDIT - changes will be overwritten */ export { DbPresetModel } from './dbPreset'; -export { DeclaredCapacityModel } from './declaredCapacity'; export { FunctionApiBindingModel } from './functionApiBinding'; export { FunctionDefinitionModel } from './functionDefinition'; export { FunctionDeploymentModel } from './functionDeployment'; @@ -18,6 +17,7 @@ export { FunctionGraphExecutionOutputModel } from './functionGraphExecutionOutpu export { FunctionGraphObjectModel } from './functionGraphObject'; export { FunctionGraphRefModel } from './functionGraphRef'; export { FunctionGraphStoreModel } from './functionGraphStore'; +export { FunctionInvocationAttemptModel } from './functionInvocationAttempt'; export { FunctionInvocationModel } from './functionInvocation'; export { GetAllTreeNodesRecordModel } from './getAllTreeNodesRecord'; export { InfraCommitModel } from './infraCommit'; @@ -28,12 +28,12 @@ export { InfraStoreModel } from './infraStore'; export { IntegrationProviderModel } from './integrationProvider'; export { NamespaceModel } from './namespace'; export { NamespaceEventModel } from './namespaceEvent'; -export { PlatformDeclaredCapacityModel } from './platformDeclaredCapacity'; export { PlatformFunctionApiBindingModel } from './platformFunctionApiBinding'; export { PlatformFunctionDefinitionModel } from './platformFunctionDefinition'; export { PlatformFunctionDeploymentModel } from './platformFunctionDeployment'; export { PlatformFunctionDeploymentEventModel } from './platformFunctionDeploymentEvent'; export { PlatformFunctionExecutionLogModel } from './platformFunctionExecutionLog'; +export { PlatformFunctionInvocationAttemptModel } from './platformFunctionInvocationAttempt'; export { PlatformFunctionInvocationModel } from './platformFunctionInvocation'; export { PlatformInfraCommitModel } from './platformInfraCommit'; export { PlatformInfraGetAllTreeNodesRecordModel } from './platformInfraGetAllTreeNodesRecord'; @@ -43,26 +43,28 @@ export { PlatformInfraStoreModel } from './platformInfraStore'; export { PlatformNamespaceModel } from './platformNamespace'; export { PlatformNamespaceEventModel } from './platformNamespaceEvent'; export { PlatformResourceModel } from './platformResource'; +export { PlatformResourceDeclaredCapacityModel } from './platformResourceDeclaredCapacity'; export { PlatformResourceDefinitionModel } from './platformResourceDefinition'; export { PlatformResourceEventModel } from './platformResourceEvent'; export { PlatformResourceInstallationModel } from './platformResourceInstallation'; export { PlatformResourceStatusCheckModel } from './platformResourceStatusCheck'; export { PlatformResourceUsageLogModel } from './platformResourceUsageLog'; export { PlatformResourceUsageSummaryModel } from './platformResourceUsageSummary'; -export { PlatformResourceUtilizationDailyModel } from './platformResourceUtilizationDaily'; +export { PlatformResourceUtilizationModel } from './platformResourceUtilization'; export { PlatformResourcesHealthModel } from './platformResourcesHealth'; export { PlatformResourcesRequirementsStateModel } from './platformResourcesRequirementsState'; export { PlatformResourcesResolvedRequirementModel } from './platformResourcesResolvedRequirement'; export { PlatformWebhookEndpointModel } from './platformWebhookEndpoint'; export { PlatformWebhookEventModel } from './platformWebhookEvent'; export { ResourceModel } from './resource'; +export { ResourceDeclaredCapacityModel } from './resourceDeclaredCapacity'; export { ResourceDefinitionModel } from './resourceDefinition'; export { ResourceEventModel } from './resourceEvent'; export { ResourceInstallationModel } from './resourceInstallation'; export { ResourceStatusCheckModel } from './resourceStatusCheck'; export { ResourceUsageLogModel } from './resourceUsageLog'; export { ResourceUsageSummaryModel } from './resourceUsageSummary'; -export { ResourceUtilizationDailyModel } from './resourceUtilizationDaily'; +export { ResourceUtilizationModel } from './resourceUtilization'; export { ResourcesHealthModel } from './resourcesHealth'; export { ResourcesRequirementsStateModel } from './resourcesRequirementsState'; export { ResourcesResolvedRequirementModel } from './resourcesResolvedRequirement'; diff --git a/sdk/constructive-sdk/src/compute/orm/models/platformDeclaredCapacity.ts b/sdk/constructive-sdk/src/compute/orm/models/platformDeclaredCapacity.ts deleted file mode 100644 index 0edf75c4d..000000000 --- a/sdk/constructive-sdk/src/compute/orm/models/platformDeclaredCapacity.ts +++ /dev/null @@ -1,136 +0,0 @@ -/** - * PlatformDeclaredCapacity model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - PlatformDeclaredCapacity, - PlatformDeclaredCapacityWithRelations, - PlatformDeclaredCapacitySelect, - PlatformDeclaredCapacityFilter, - PlatformDeclaredCapacityOrderBy, - CreatePlatformDeclaredCapacityInput, - UpdatePlatformDeclaredCapacityInput, - PlatformDeclaredCapacityPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class PlatformDeclaredCapacityModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformDeclaredCapacities: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'PlatformDeclaredCapacity', - 'platformDeclaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'PlatformDeclaredCapacityFilter', - 'PlatformDeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'platformDeclaredCapacities', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformDeclaredCapacity: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'PlatformDeclaredCapacity', - 'platformDeclaredCapacities', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'PlatformDeclaredCapacityFilter', - 'PlatformDeclaredCapacityOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'platformDeclaredCapacity', - document, - variables, - transform: (data: { - platformDeclaredCapacities?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - platformDeclaredCapacity: data.platformDeclaredCapacities?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createPlatformDeclaredCapacity: { - platformDeclaredCapacity: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'PlatformDeclaredCapacity', - 'createPlatformDeclaredCapacity', - 'platformDeclaredCapacity', - args.select, - args.data, - 'CreatePlatformDeclaredCapacityInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'PlatformDeclaredCapacity', - fieldName: 'createPlatformDeclaredCapacity', - document, - variables, - }); - } -} diff --git a/sdk/constructive-sdk/src/compute/orm/models/platformFunctionInvocationAttempt.ts b/sdk/constructive-sdk/src/compute/orm/models/platformFunctionInvocationAttempt.ts new file mode 100644 index 000000000..a1db7bbe0 --- /dev/null +++ b/sdk/constructive-sdk/src/compute/orm/models/platformFunctionInvocationAttempt.ts @@ -0,0 +1,280 @@ +/** + * PlatformFunctionInvocationAttempt model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformFunctionInvocationAttempt, + PlatformFunctionInvocationAttemptWithRelations, + PlatformFunctionInvocationAttemptSelect, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy, + CreatePlatformFunctionInvocationAttemptInput, + UpdatePlatformFunctionInvocationAttemptInput, + PlatformFunctionInvocationAttemptPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformFunctionInvocationAttemptModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempts: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempts', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformFunctionInvocationAttemptFilter, + PlatformFunctionInvocationAttemptOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempt', + document, + variables, + transform: (data: { + platformFunctionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformFunctionInvocationAttempt: + data.platformFunctionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempts', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'PlatformFunctionInvocationAttemptFilter', + 'PlatformFunctionInvocationAttemptOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'platformFunctionInvocationAttempt', + document, + variables, + transform: (data: { + platformFunctionInvocationAttempts?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformFunctionInvocationAttempt: + data.platformFunctionInvocationAttempts?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs< + S, + CreatePlatformFunctionInvocationAttemptInput['platformFunctionInvocationAttempt'] + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformFunctionInvocationAttempt', + 'createPlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + args.select, + args.data, + 'CreatePlatformFunctionInvocationAttemptInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'createPlatformFunctionInvocationAttempt', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + createdAt: string; + }, + PlatformFunctionInvocationAttemptPatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updatePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'PlatformFunctionInvocationAttempt', + 'updatePlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + args.select, + args.where.id, + args.data, + 'UpdatePlatformFunctionInvocationAttemptInput', + 'id', + 'platformFunctionInvocationAttemptPatch', + connectionFieldsMap, + { + createdAt: args.where.createdAt, + } + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'updatePlatformFunctionInvocationAttempt', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + createdAt: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deletePlatformFunctionInvocationAttempt: { + platformFunctionInvocationAttempt: InferSelectResult< + PlatformFunctionInvocationAttemptWithRelations, + S + >; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'PlatformFunctionInvocationAttempt', + 'deletePlatformFunctionInvocationAttempt', + 'platformFunctionInvocationAttempt', + { + id: args.where.id, + createdAt: args.where.createdAt, + }, + 'DeletePlatformFunctionInvocationAttemptInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformFunctionInvocationAttempt', + fieldName: 'deletePlatformFunctionInvocationAttempt', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/compute/orm/models/platformResourceDeclaredCapacity.ts b/sdk/constructive-sdk/src/compute/orm/models/platformResourceDeclaredCapacity.ts new file mode 100644 index 000000000..66a88f859 --- /dev/null +++ b/sdk/constructive-sdk/src/compute/orm/models/platformResourceDeclaredCapacity.ts @@ -0,0 +1,154 @@ +/** + * PlatformResourceDeclaredCapacity model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformResourceDeclaredCapacity, + PlatformResourceDeclaredCapacityWithRelations, + PlatformResourceDeclaredCapacitySelect, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy, + CreatePlatformResourceDeclaredCapacityInput, + UpdatePlatformResourceDeclaredCapacityInput, + PlatformResourceDeclaredCapacityPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformResourceDeclaredCapacityModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformResourceDeclaredCapacityFilter', + 'PlatformResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'platformResourceDeclaredCapacities', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformResourceDeclaredCapacityFilter, + PlatformResourceDeclaredCapacityOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformResourceDeclaredCapacityFilter', + 'PlatformResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'platformResourceDeclaredCapacity', + document, + variables, + transform: (data: { + platformResourceDeclaredCapacities?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformResourceDeclaredCapacity: + data.platformResourceDeclaredCapacities?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs< + S, + CreatePlatformResourceDeclaredCapacityInput['platformResourceDeclaredCapacity'] + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformResourceDeclaredCapacity: { + platformResourceDeclaredCapacity: InferSelectResult< + PlatformResourceDeclaredCapacityWithRelations, + S + >; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformResourceDeclaredCapacity', + 'createPlatformResourceDeclaredCapacity', + 'platformResourceDeclaredCapacity', + args.select, + args.data, + 'CreatePlatformResourceDeclaredCapacityInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformResourceDeclaredCapacity', + fieldName: 'createPlatformResourceDeclaredCapacity', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilization.ts b/sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilization.ts new file mode 100644 index 000000000..040d38000 --- /dev/null +++ b/sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilization.ts @@ -0,0 +1,143 @@ +/** + * PlatformResourceUtilization model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + PlatformResourceUtilization, + PlatformResourceUtilizationWithRelations, + PlatformResourceUtilizationSelect, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy, + CreatePlatformResourceUtilizationInput, + UpdatePlatformResourceUtilizationInput, + PlatformResourceUtilizationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class PlatformResourceUtilizationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceUtilizations: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'PlatformResourceUtilization', + 'platformResourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'PlatformResourceUtilizationFilter', + 'PlatformResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceUtilization', + fieldName: 'platformResourceUtilizations', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs< + S, + PlatformResourceUtilizationFilter, + PlatformResourceUtilizationOrderBy + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + platformResourceUtilization: InferSelectResult< + PlatformResourceUtilizationWithRelations, + S + > | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'PlatformResourceUtilization', + 'platformResourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'PlatformResourceUtilizationFilter', + 'PlatformResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'PlatformResourceUtilization', + fieldName: 'platformResourceUtilization', + document, + variables, + transform: (data: { + platformResourceUtilizations?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + platformResourceUtilization: data.platformResourceUtilizations?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createPlatformResourceUtilization: { + platformResourceUtilization: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'PlatformResourceUtilization', + 'createPlatformResourceUtilization', + 'platformResourceUtilization', + args.select, + args.data, + 'CreatePlatformResourceUtilizationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'PlatformResourceUtilization', + fieldName: 'createPlatformResourceUtilization', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilizationDaily.ts b/sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilizationDaily.ts deleted file mode 100644 index e142f1f50..000000000 --- a/sdk/constructive-sdk/src/compute/orm/models/platformResourceUtilizationDaily.ts +++ /dev/null @@ -1,154 +0,0 @@ -/** - * PlatformResourceUtilizationDaily model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - PlatformResourceUtilizationDaily, - PlatformResourceUtilizationDailyWithRelations, - PlatformResourceUtilizationDailySelect, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy, - CreatePlatformResourceUtilizationDailyInput, - UpdatePlatformResourceUtilizationDailyInput, - PlatformResourceUtilizationDailyPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class PlatformResourceUtilizationDailyModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformResourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'PlatformResourceUtilizationDaily', - 'platformResourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'PlatformResourceUtilizationDailyFilter', - 'PlatformResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'platformResourceUtilizationDailies', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs< - S, - PlatformResourceUtilizationDailyFilter, - PlatformResourceUtilizationDailyOrderBy - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - > | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'PlatformResourceUtilizationDaily', - 'platformResourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'PlatformResourceUtilizationDailyFilter', - 'PlatformResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'platformResourceUtilizationDaily', - document, - variables, - transform: (data: { - platformResourceUtilizationDailies?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - platformResourceUtilizationDaily: - data.platformResourceUtilizationDailies?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs< - S, - CreatePlatformResourceUtilizationDailyInput['platformResourceUtilizationDaily'] - > & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createPlatformResourceUtilizationDaily: { - platformResourceUtilizationDaily: InferSelectResult< - PlatformResourceUtilizationDailyWithRelations, - S - >; - }; - }> { - const { document, variables } = buildCreateDocument( - 'PlatformResourceUtilizationDaily', - 'createPlatformResourceUtilizationDaily', - 'platformResourceUtilizationDaily', - args.select, - args.data, - 'CreatePlatformResourceUtilizationDailyInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'PlatformResourceUtilizationDaily', - fieldName: 'createPlatformResourceUtilizationDaily', - document, - variables, - }); - } -} diff --git a/sdk/constructive-sdk/src/compute/orm/models/resourceDeclaredCapacity.ts b/sdk/constructive-sdk/src/compute/orm/models/resourceDeclaredCapacity.ts new file mode 100644 index 000000000..6340979a9 --- /dev/null +++ b/sdk/constructive-sdk/src/compute/orm/models/resourceDeclaredCapacity.ts @@ -0,0 +1,136 @@ +/** + * ResourceDeclaredCapacity model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ResourceDeclaredCapacity, + ResourceDeclaredCapacityWithRelations, + ResourceDeclaredCapacitySelect, + ResourceDeclaredCapacityFilter, + ResourceDeclaredCapacityOrderBy, + CreateResourceDeclaredCapacityInput, + UpdateResourceDeclaredCapacityInput, + ResourceDeclaredCapacityPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ResourceDeclaredCapacityModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceDeclaredCapacities: ConnectionResult< + InferSelectResult + >; + }> { + const { document, variables } = buildFindManyDocument( + 'ResourceDeclaredCapacity', + 'resourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ResourceDeclaredCapacityFilter', + 'ResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'resourceDeclaredCapacities', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceDeclaredCapacity: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ResourceDeclaredCapacity', + 'resourceDeclaredCapacities', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ResourceDeclaredCapacityFilter', + 'ResourceDeclaredCapacityOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'resourceDeclaredCapacity', + document, + variables, + transform: (data: { + resourceDeclaredCapacities?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + resourceDeclaredCapacity: data.resourceDeclaredCapacities?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createResourceDeclaredCapacity: { + resourceDeclaredCapacity: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ResourceDeclaredCapacity', + 'createResourceDeclaredCapacity', + 'resourceDeclaredCapacity', + args.select, + args.data, + 'CreateResourceDeclaredCapacityInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ResourceDeclaredCapacity', + fieldName: 'createResourceDeclaredCapacity', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/compute/orm/models/resourceUtilization.ts b/sdk/constructive-sdk/src/compute/orm/models/resourceUtilization.ts new file mode 100644 index 000000000..362048600 --- /dev/null +++ b/sdk/constructive-sdk/src/compute/orm/models/resourceUtilization.ts @@ -0,0 +1,134 @@ +/** + * ResourceUtilization model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ResourceUtilization, + ResourceUtilizationWithRelations, + ResourceUtilizationSelect, + ResourceUtilizationFilter, + ResourceUtilizationOrderBy, + CreateResourceUtilizationInput, + UpdateResourceUtilizationInput, + ResourceUtilizationPatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ResourceUtilizationModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceUtilizations: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'ResourceUtilization', + 'resourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ResourceUtilizationFilter', + 'ResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceUtilization', + fieldName: 'resourceUtilizations', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + resourceUtilization: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ResourceUtilization', + 'resourceUtilizations', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ResourceUtilizationFilter', + 'ResourceUtilizationOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ResourceUtilization', + fieldName: 'resourceUtilization', + document, + variables, + transform: (data: { + resourceUtilizations?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + resourceUtilization: data.resourceUtilizations?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createResourceUtilization: { + resourceUtilization: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ResourceUtilization', + 'createResourceUtilization', + 'resourceUtilization', + args.select, + args.data, + 'CreateResourceUtilizationInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ResourceUtilization', + fieldName: 'createResourceUtilization', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/compute/orm/models/resourceUtilizationDaily.ts b/sdk/constructive-sdk/src/compute/orm/models/resourceUtilizationDaily.ts deleted file mode 100644 index 8307b4adc..000000000 --- a/sdk/constructive-sdk/src/compute/orm/models/resourceUtilizationDaily.ts +++ /dev/null @@ -1,136 +0,0 @@ -/** - * ResourceUtilizationDaily model for ORM client - * @generated by @constructive-io/graphql-codegen - * DO NOT EDIT - changes will be overwritten - */ -import { OrmClient } from '../client'; -import { - QueryBuilder, - buildFindManyDocument, - buildFindFirstDocument, - buildFindOneDocument, - buildCreateDocument, - buildUpdateByPkDocument, - buildDeleteByPkDocument, -} from '../query-builder'; -import type { - ConnectionResult, - FindManyArgs, - FindFirstArgs, - CreateArgs, - UpdateArgs, - DeleteArgs, - InferSelectResult, - StrictSelect, -} from '../select-types'; -import type { - ResourceUtilizationDaily, - ResourceUtilizationDailyWithRelations, - ResourceUtilizationDailySelect, - ResourceUtilizationDailyFilter, - ResourceUtilizationDailyOrderBy, - CreateResourceUtilizationDailyInput, - UpdateResourceUtilizationDailyInput, - ResourceUtilizationDailyPatch, -} from '../input-types'; -import { connectionFieldsMap } from '../input-types'; -export class ResourceUtilizationDailyModel { - constructor(private client: OrmClient) {} - findMany( - args: FindManyArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - resourceUtilizationDailies: ConnectionResult< - InferSelectResult - >; - }> { - const { document, variables } = buildFindManyDocument( - 'ResourceUtilizationDaily', - 'resourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - first: args?.first, - last: args?.last, - after: args?.after, - before: args?.before, - offset: args?.offset, - }, - 'ResourceUtilizationDailyFilter', - 'ResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'ResourceUtilizationDaily', - fieldName: 'resourceUtilizationDailies', - document, - variables, - }); - } - findFirst( - args: FindFirstArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - resourceUtilizationDaily: InferSelectResult | null; - }> { - const { document, variables } = buildFindFirstDocument( - 'ResourceUtilizationDaily', - 'resourceUtilizationDailies', - args.select, - { - where: args?.where, - orderBy: args?.orderBy as string[] | undefined, - }, - 'ResourceUtilizationDailyFilter', - 'ResourceUtilizationDailyOrderBy', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'query', - operationName: 'ResourceUtilizationDaily', - fieldName: 'resourceUtilizationDaily', - document, - variables, - transform: (data: { - resourceUtilizationDailies?: { - nodes?: InferSelectResult[]; - }; - }) => ({ - resourceUtilizationDaily: data.resourceUtilizationDailies?.nodes?.[0] ?? null, - }), - }); - } - create( - args: CreateArgs & { - select: S; - } & StrictSelect - ): QueryBuilder<{ - createResourceUtilizationDaily: { - resourceUtilizationDaily: InferSelectResult; - }; - }> { - const { document, variables } = buildCreateDocument( - 'ResourceUtilizationDaily', - 'createResourceUtilizationDaily', - 'resourceUtilizationDaily', - args.select, - args.data, - 'CreateResourceUtilizationDailyInput', - connectionFieldsMap - ); - return new QueryBuilder({ - client: this.client, - operation: 'mutation', - operationName: 'ResourceUtilizationDaily', - fieldName: 'createResourceUtilizationDaily', - document, - variables, - }); - } -} diff --git a/sdk/constructive-sdk/src/modules/README.md b/sdk/constructive-sdk/src/modules/README.md index 645e6b685..de0c0e117 100644 --- a/sdk/constructive-sdk/src/modules/README.md +++ b/sdk/constructive-sdk/src/modules/README.md @@ -8,7 +8,7 @@ ## Overview -- **Tables:** 68 +- **Tables:** 74 - **Custom queries:** 2 - **Custom mutations:** 10 diff --git a/sdk/constructive-sdk/src/modules/orm/README.md b/sdk/constructive-sdk/src/modules/orm/README.md index e420c3adb..41c41241d 100644 --- a/sdk/constructive-sdk/src/modules/orm/README.md +++ b/sdk/constructive-sdk/src/modules/orm/README.md @@ -22,11 +22,14 @@ const db = createClient({ | Model | Operations | |-------|------------| | `agentModule` | findMany, findOne, create, update, delete | +| `apiSurfaceModule` | findMany, findOne, create, update, delete | +| `appModule` | findMany, findOne, create, update, delete | | `billingModule` | findMany, findOne, create, update, delete | | `billingProviderModule` | findMany, findOne, create, update, delete | | `blueprint` | findMany, findOne, create, update, delete | | `blueprintConstruction` | findMany, findOne, create, update, delete | | `blueprintTemplate` | findMany, findOne, create, update, delete | +| `catalogModule` | findMany, findOne, create, update, delete | | `computeLogModule` | findMany, findOne, create, update, delete | | `configSecretsUserModule` | findMany, findOne, create, update, delete | | `connectedAccountsModule` | findMany, findOne, create, update, delete | @@ -40,6 +43,7 @@ const db = createClient({ | `defaultIdsModule` | findMany, findOne, create, update, delete | | `denormalizedTableField` | findMany, findOne, create, update, delete | | `devicesModule` | findMany, findOne, create, update, delete | +| `domainModule` | findMany, findOne, create, update, delete | | `emailsModule` | findMany, findOne, create, update, delete | | `entityTypeProvision` | findMany, findOne, create, update, delete | | `eventsModule` | findMany, findOne, create, update, delete | @@ -75,9 +79,11 @@ const db = createClient({ | `relationProvision` | findMany, findOne, create, update, delete | | `resourceModule` | findMany, findOne, create, update, delete | | `rlsModule` | findMany, findOne, create, update, delete | +| `routeModule` | findMany, findOne, create, update, delete | | `secureTableProvision` | findMany, findOne, create, update, delete | | `sessionSecretsModule` | findMany, findOne, create, update, delete | | `sessionsModule` | findMany, findOne, create, update, delete | +| `siteSurfaceModule` | findMany, findOne, create, update, delete | | `storageLogModule` | findMany, findOne, create, update, delete | | `storageModule` | findMany, findOne, create, update, delete | | `transferLogModule` | findMany, findOne, create, update, delete | @@ -156,6 +162,98 @@ const updated = await db.agentModule.update({ where: { id: '' }, data: { a const deleted = await db.agentModule.delete({ where: { id: '' } }).execute(); ``` +### `db.apiSurfaceModule` + +CRUD operations for ApiSurfaceModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `apisTableId` | UUID | Yes | +| `apisTableName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all apiSurfaceModule records +const items = await db.apiSurfaceModule.findMany({ select: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.apiSurfaceModule.findOne({ id: '', select: { apiName: true, apisTableId: true, apisTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.apiSurfaceModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.apiSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.apiSurfaceModule.delete({ where: { id: '' } }).execute(); +``` + +### `db.appModule` + +CRUD operations for AppModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `appMembersTableId` | UUID | Yes | +| `appMembersTableName` | String | Yes | +| `appsTableId` | UUID | Yes | +| `appsTableName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `privateSchemaId` | UUID | Yes | +| `privateSchemaName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all appModule records +const items = await db.appModule.findMany({ select: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.appModule.findOne({ id: '', select: { apiName: true, appMembersTableId: true, appMembersTableName: true, appsTableId: true, appsTableName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.appModule.create({ data: { apiName: '', appMembersTableId: '', appMembersTableName: '', appsTableId: '', appsTableName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.appModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.appModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.billingModule` CRUD operations for BillingModule records. @@ -388,6 +486,63 @@ const updated = await db.blueprintTemplate.update({ where: { id: '' }, dat const deleted = await db.blueprintTemplate.delete({ where: { id: '' } }).execute(); ``` +### `db.catalogModule` + +CRUD operations for CatalogModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `apisTableId` | UUID | Yes | +| `apisTableName` | String | Yes | +| `appsTableId` | UUID | Yes | +| `appsTableName` | String | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainsTableId` | UUID | Yes | +| `domainsTableName` | String | Yes | +| `entityTableId` | UUID | Yes | +| `functionsTableId` | UUID | Yes | +| `functionsTableName` | String | Yes | +| `id` | UUID | No | +| `namespacesTableId` | UUID | Yes | +| `namespacesTableName` | String | Yes | +| `policies` | JSON | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `resourceDefinitionsTableId` | UUID | Yes | +| `resourceDefinitionsTableName` | String | Yes | +| `resourceInstallationsTableId` | UUID | Yes | +| `resourceInstallationsTableName` | String | Yes | +| `resourcesTableId` | UUID | Yes | +| `resourcesTableName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | +| `sitesTableId` | UUID | Yes | +| `sitesTableName` | String | Yes | + +**Operations:** + +```typescript +// List all catalogModule records +const items = await db.catalogModule.findMany({ select: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Get one by id +const item = await db.catalogModule.findOne({ id: '', select: { apiName: true, apisTableId: true, apisTableName: true, appsTableId: true, appsTableName: true, databaseId: true, defaultPermissions: true, domainsTableId: true, domainsTableName: true, entityTableId: true, functionsTableId: true, functionsTableName: true, id: true, namespacesTableId: true, namespacesTableName: true, policies: true, privateApiName: true, provisions: true, publicSchemaName: true, resourceDefinitionsTableId: true, resourceDefinitionsTableName: true, resourceInstallationsTableId: true, resourceInstallationsTableName: true, resourcesTableId: true, resourcesTableName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Create +const created = await db.catalogModule.create({ data: { apiName: '', apisTableId: '', apisTableName: '', appsTableId: '', appsTableName: '', databaseId: '', defaultPermissions: '', domainsTableId: '', domainsTableName: '', entityTableId: '', functionsTableId: '', functionsTableName: '', namespacesTableId: '', namespacesTableName: '', policies: '', privateApiName: '', provisions: '', publicSchemaName: '', resourceDefinitionsTableId: '', resourceDefinitionsTableName: '', resourceInstallationsTableId: '', resourceInstallationsTableName: '', resourcesTableId: '', resourcesTableName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.catalogModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.catalogModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.computeLogModule` CRUD operations for ComputeLogModule records. @@ -597,6 +752,7 @@ CRUD operations for DatabaseProvisionModule records. | Field | Type | Editable | |-------|------|----------| +| `async` | Boolean | Yes | | `bootstrapError` | String | Yes | | `bootstrapStatus` | String | Yes | | `bootstrapUser` | Boolean | Yes | @@ -620,16 +776,16 @@ CRUD operations for DatabaseProvisionModule records. ```typescript // List all databaseProvisionModule records -const items = await db.databaseProvisionModule.findMany({ select: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); +const items = await db.databaseProvisionModule.findMany({ select: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); // Get one by id -const item = await db.databaseProvisionModule.findOne({ id: '', select: { bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); +const item = await db.databaseProvisionModule.findOne({ id: '', select: { async: true, bootstrapError: true, bootstrapStatus: true, bootstrapUser: true, completedAt: true, createdAt: true, databaseId: true, databaseName: true, domain: true, errorMessage: true, fulfilledAt: true, id: true, modules: true, options: true, ownerId: true, sourceDatabaseId: true, status: true, subdomain: true, updatedAt: true } }).execute(); // Create -const created = await db.databaseProvisionModule.create({ data: { bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute(); +const created = await db.databaseProvisionModule.create({ data: { async: '', bootstrapError: '', bootstrapStatus: '', bootstrapUser: '', completedAt: '', databaseId: '', databaseName: '', domain: '', errorMessage: '', fulfilledAt: '', modules: '', options: '', ownerId: '', sourceDatabaseId: '', status: '', subdomain: '' }, select: { id: true } }).execute(); // Update -const updated = await db.databaseProvisionModule.update({ where: { id: '' }, data: { bootstrapError: '' }, select: { id: true } }).execute(); +const updated = await db.databaseProvisionModule.update({ where: { id: '' }, data: { async: '' }, select: { id: true } }).execute(); // Delete const deleted = await db.databaseProvisionModule.delete({ where: { id: '' } }).execute(); @@ -919,6 +1075,54 @@ const updated = await db.devicesModule.update({ where: { id: '' }, data: { const deleted = await db.devicesModule.delete({ where: { id: '' } }).execute(); ``` +### `db.domainModule` + +CRUD operations for DomainModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainEventsTableId` | UUID | Yes | +| `domainEventsTableName` | String | Yes | +| `domainVerificationsTableId` | UUID | Yes | +| `domainVerificationsTableName` | String | Yes | +| `domainsTableId` | UUID | Yes | +| `domainsTableName` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all domainModule records +const items = await db.domainModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.domainModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainEventsTableId: true, domainEventsTableName: true, domainVerificationsTableId: true, domainVerificationsTableName: true, domainsTableId: true, domainsTableName: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.domainModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainEventsTableId: '', domainEventsTableName: '', domainVerificationsTableId: '', domainVerificationsTableName: '', domainsTableId: '', domainsTableName: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.domainModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.domainModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.emailsModule` CRUD operations for EmailsModule records. @@ -1153,6 +1357,8 @@ CRUD operations for FunctionInvocationModule records. | Field | Type | Editable | |-------|------|----------| | `apiName` | String | Yes | +| `attemptsTableId` | UUID | Yes | +| `attemptsTableName` | String | Yes | | `databaseId` | UUID | Yes | | `defaultPermissions` | String | Yes | | `entityField` | String | Yes | @@ -1176,13 +1382,13 @@ CRUD operations for FunctionInvocationModule records. ```typescript // List all functionInvocationModule records -const items = await db.functionInvocationModule.findMany({ select: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); +const items = await db.functionInvocationModule.findMany({ select: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); // Get one by id -const item = await db.functionInvocationModule.findOne({ id: '', select: { apiName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); +const item = await db.functionInvocationModule.findOne({ id: '', select: { apiName: true, attemptsTableId: true, attemptsTableName: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, executionLogsTableId: true, executionLogsTableName: true, id: true, invocationsTableId: true, invocationsTableName: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true } }).execute(); // Create -const created = await db.functionInvocationModule.create({ data: { apiName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); +const created = await db.functionInvocationModule.create({ data: { apiName: '', attemptsTableId: '', attemptsTableName: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', executionLogsTableId: '', executionLogsTableName: '', invocationsTableId: '', invocationsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); // Update const updated = await db.functionInvocationModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); @@ -2612,6 +2818,58 @@ const updated = await db.rlsModule.update({ where: { id: '' }, data: { api const deleted = await db.rlsModule.delete({ where: { id: '' } }).execute(); ``` +### `db.routeModule` + +CRUD operations for RouteModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `domainModuleId` | UUID | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `hostnameBindingsTableId` | UUID | Yes | +| `hostnameBindingsTableName` | String | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `privateSchemaId` | UUID | Yes | +| `privateSchemaName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `resolverFunctionName` | String | Yes | +| `routeBindingsTableId` | UUID | Yes | +| `routeBindingsTableName` | String | Yes | +| `routesTableId` | UUID | Yes | +| `routesTableName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | + +**Operations:** + +```typescript +// List all routeModule records +const items = await db.routeModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }).execute(); + +// Get one by id +const item = await db.routeModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, domainModuleId: true, entityField: true, entityTableId: true, hostnameBindingsTableId: true, hostnameBindingsTableName: true, id: true, policies: true, prefix: true, privateApiName: true, privateSchemaId: true, privateSchemaName: true, provisions: true, publicSchemaName: true, resolverFunctionName: true, routeBindingsTableId: true, routeBindingsTableName: true, routesTableId: true, routesTableName: true, schemaId: true, scope: true } }).execute(); + +// Create +const created = await db.routeModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', domainModuleId: '', entityField: '', entityTableId: '', hostnameBindingsTableId: '', hostnameBindingsTableName: '', policies: '', prefix: '', privateApiName: '', privateSchemaId: '', privateSchemaName: '', provisions: '', publicSchemaName: '', resolverFunctionName: '', routeBindingsTableId: '', routeBindingsTableName: '', routesTableId: '', routesTableName: '', schemaId: '', scope: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.routeModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.routeModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.secureTableProvision` CRUD operations for SecureTableProvision records. @@ -2724,6 +2982,50 @@ const updated = await db.sessionsModule.update({ where: { id: '' }, data: const deleted = await db.sessionsModule.delete({ where: { id: '' } }).execute(); ``` +### `db.siteSurfaceModule` + +CRUD operations for SiteSurfaceModule records. + +**Fields:** + +| Field | Type | Editable | +|-------|------|----------| +| `apiName` | String | Yes | +| `catalogModuleId` | UUID | Yes | +| `databaseId` | UUID | Yes | +| `defaultPermissions` | String | Yes | +| `entityField` | String | Yes | +| `entityTableId` | UUID | Yes | +| `id` | UUID | No | +| `policies` | JSON | Yes | +| `prefix` | String | Yes | +| `privateApiName` | String | Yes | +| `provisions` | JSON | Yes | +| `publicSchemaName` | String | Yes | +| `schemaId` | UUID | Yes | +| `scope` | String | Yes | +| `sitesTableId` | UUID | Yes | +| `sitesTableName` | String | Yes | + +**Operations:** + +```typescript +// List all siteSurfaceModule records +const items = await db.siteSurfaceModule.findMany({ select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Get one by id +const item = await db.siteSurfaceModule.findOne({ id: '', select: { apiName: true, catalogModuleId: true, databaseId: true, defaultPermissions: true, entityField: true, entityTableId: true, id: true, policies: true, prefix: true, privateApiName: true, provisions: true, publicSchemaName: true, schemaId: true, scope: true, sitesTableId: true, sitesTableName: true } }).execute(); + +// Create +const created = await db.siteSurfaceModule.create({ data: { apiName: '', catalogModuleId: '', databaseId: '', defaultPermissions: '', entityField: '', entityTableId: '', policies: '', prefix: '', privateApiName: '', provisions: '', publicSchemaName: '', schemaId: '', scope: '', sitesTableId: '', sitesTableName: '' }, select: { id: true } }).execute(); + +// Update +const updated = await db.siteSurfaceModule.update({ where: { id: '' }, data: { apiName: '' }, select: { id: true } }).execute(); + +// Delete +const deleted = await db.siteSurfaceModule.delete({ where: { id: '' } }).execute(); +``` + ### `db.storageLogModule` CRUD operations for StorageLogModule records. diff --git a/sdk/constructive-sdk/src/modules/orm/index.ts b/sdk/constructive-sdk/src/modules/orm/index.ts index dc11b99fb..64ef96660 100644 --- a/sdk/constructive-sdk/src/modules/orm/index.ts +++ b/sdk/constructive-sdk/src/modules/orm/index.ts @@ -6,11 +6,14 @@ import { OrmClient } from './client'; import type { OrmClientConfig } from './client'; import { AgentModuleModel } from './models/agentModule'; +import { ApiSurfaceModuleModel } from './models/apiSurfaceModule'; +import { AppModuleModel } from './models/appModule'; import { BillingModuleModel } from './models/billingModule'; import { BillingProviderModuleModel } from './models/billingProviderModule'; import { BlueprintModel } from './models/blueprint'; import { BlueprintConstructionModel } from './models/blueprintConstruction'; import { BlueprintTemplateModel } from './models/blueprintTemplate'; +import { CatalogModuleModel } from './models/catalogModule'; import { ComputeLogModuleModel } from './models/computeLogModule'; import { ConfigSecretsUserModuleModel } from './models/configSecretsUserModule'; import { ConnectedAccountsModuleModel } from './models/connectedAccountsModule'; @@ -24,6 +27,7 @@ import { DbUsageModuleModel } from './models/dbUsageModule'; import { DefaultIdsModuleModel } from './models/defaultIdsModule'; import { DenormalizedTableFieldModel } from './models/denormalizedTableField'; import { DevicesModuleModel } from './models/devicesModule'; +import { DomainModuleModel } from './models/domainModule'; import { EmailsModuleModel } from './models/emailsModule'; import { EntityTypeProvisionModel } from './models/entityTypeProvision'; import { EventsModuleModel } from './models/eventsModule'; @@ -59,9 +63,11 @@ import { RealtimeModuleModel } from './models/realtimeModule'; import { RelationProvisionModel } from './models/relationProvision'; import { ResourceModuleModel } from './models/resourceModule'; import { RlsModuleModel } from './models/rlsModule'; +import { RouteModuleModel } from './models/routeModule'; import { SecureTableProvisionModel } from './models/secureTableProvision'; import { SessionSecretsModuleModel } from './models/sessionSecretsModule'; import { SessionsModuleModel } from './models/sessionsModule'; +import { SiteSurfaceModuleModel } from './models/siteSurfaceModule'; import { StorageLogModuleModel } from './models/storageLogModule'; import { StorageModuleModel } from './models/storageModule'; import { TransferLogModuleModel } from './models/transferLogModule'; @@ -109,11 +115,14 @@ export function createClient(config: OrmClientConfig) { const client = new OrmClient(config); return { agentModule: new AgentModuleModel(client), + apiSurfaceModule: new ApiSurfaceModuleModel(client), + appModule: new AppModuleModel(client), billingModule: new BillingModuleModel(client), billingProviderModule: new BillingProviderModuleModel(client), blueprint: new BlueprintModel(client), blueprintConstruction: new BlueprintConstructionModel(client), blueprintTemplate: new BlueprintTemplateModel(client), + catalogModule: new CatalogModuleModel(client), computeLogModule: new ComputeLogModuleModel(client), configSecretsUserModule: new ConfigSecretsUserModuleModel(client), connectedAccountsModule: new ConnectedAccountsModuleModel(client), @@ -127,6 +136,7 @@ export function createClient(config: OrmClientConfig) { defaultIdsModule: new DefaultIdsModuleModel(client), denormalizedTableField: new DenormalizedTableFieldModel(client), devicesModule: new DevicesModuleModel(client), + domainModule: new DomainModuleModel(client), emailsModule: new EmailsModuleModel(client), entityTypeProvision: new EntityTypeProvisionModel(client), eventsModule: new EventsModuleModel(client), @@ -162,9 +172,11 @@ export function createClient(config: OrmClientConfig) { relationProvision: new RelationProvisionModel(client), resourceModule: new ResourceModuleModel(client), rlsModule: new RlsModuleModel(client), + routeModule: new RouteModuleModel(client), secureTableProvision: new SecureTableProvisionModel(client), sessionSecretsModule: new SessionSecretsModuleModel(client), sessionsModule: new SessionsModuleModel(client), + siteSurfaceModule: new SiteSurfaceModuleModel(client), storageLogModule: new StorageLogModuleModel(client), storageModule: new StorageModuleModel(client), transferLogModule: new TransferLogModuleModel(client), diff --git a/sdk/constructive-sdk/src/modules/orm/input-types.ts b/sdk/constructive-sdk/src/modules/orm/input-types.ts index a163f67d4..c151221f6 100644 --- a/sdk/constructive-sdk/src/modules/orm/input-types.ts +++ b/sdk/constructive-sdk/src/modules/orm/input-types.ts @@ -269,6 +269,46 @@ export interface AgentModule { threadTableId?: string | null; threadTableName?: string | null; } +export interface ApiSurfaceModule { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface AppModule { + apiName?: string | null; + appMembersTableId?: string | null; + appMembersTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} export interface BillingModule { apiName?: string | null; balancesTableId?: string | null; @@ -417,6 +457,37 @@ export interface BlueprintTemplate { /** Access control for the template. private: only the owner can see and copy. public: anyone can browse and copy from the marketplace. Defaults to private. */ visibility?: string | null; } +export interface CatalogModule { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityTableId?: string | null; + functionsTableId?: string | null; + functionsTableName?: string | null; + id: string; + namespacesTableId?: string | null; + namespacesTableName?: string | null; + policies?: Record | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resourceDefinitionsTableId?: string | null; + resourceDefinitionsTableName?: string | null; + resourceInstallationsTableId?: string | null; + resourceInstallationsTableName?: string | null; + resourcesTableId?: string | null; + resourcesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} export interface ComputeLogModule { actorFkTableId?: string | null; apiName?: string | null; @@ -490,6 +561,8 @@ export interface CryptoAuthModule { } /** Tracks database provisioning requests and their status. The BEFORE INSERT trigger creates the database and sets database_id before RLS policies are evaluated. */ export interface DatabaseProvisionModule { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean | null; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string | null; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -639,6 +712,28 @@ export interface DevicesModule { userDevicesTableId?: string | null; userDevicesTableName?: string | null; } +export interface DomainModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainEventsTableId?: string | null; + domainEventsTableName?: string | null; + domainVerificationsTableId?: string | null; + domainVerificationsTableName?: string | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} export interface EmailsModule { apiName?: string | null; databaseId?: string | null; @@ -982,6 +1077,8 @@ export interface FunctionDeploymentModule { } export interface FunctionInvocationModule { apiName?: string | null; + attemptsTableId?: string | null; + attemptsTableName?: string | null; databaseId?: string | null; defaultPermissions?: string[] | null; entityField?: string | null; @@ -1772,6 +1869,32 @@ export interface RlsModule { sessionsTableId?: string | null; usersTableId?: string | null; } +export interface RouteModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainModuleId?: string | null; + entityField?: string | null; + entityTableId?: string | null; + hostnameBindingsTableId?: string | null; + hostnameBindingsTableName?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resolverFunctionName?: string | null; + routeBindingsTableId?: string | null; + routeBindingsTableName?: string | null; + routesTableId?: string | null; + routesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; +} /** Provisions security, fields, grants, and policies onto a table. Each row can independently: (1) create fields via nodes[] array (supporting multiple Data* modules per row), (2) grant privileges via grants[] array (supporting per-role privilege targeting), (3) create RLS policies via policies[] array (supporting multiple Authz* policies per row). Multiple rows can target the same table to compose different concerns. All three concerns are optional and independent. */ export interface SecureTableProvision { /** The database this provision belongs to. Required. */ @@ -1820,6 +1943,24 @@ export interface SessionsModule { sessionsTableName?: string | null; usersTableId?: string | null; } +export interface SiteSurfaceModule { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + id: string; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} export interface StorageLogModule { actorFkTableId?: string | null; apiName?: string | null; @@ -2048,6 +2189,12 @@ export interface PageInfo { } // ============ Entity Relation Types ============ export interface AgentModuleRelations {} +export interface ApiSurfaceModuleRelations { + catalogModule?: CatalogModule | null; +} +export interface AppModuleRelations { + catalogModule?: CatalogModule | null; +} export interface BillingModuleRelations {} export interface BillingProviderModuleRelations {} export interface BlueprintRelations { @@ -2062,6 +2209,7 @@ export interface BlueprintTemplateRelations { blueprintTemplatesByForkedFromId?: ConnectionResult; blueprintsByTemplateId?: ConnectionResult; } +export interface CatalogModuleRelations {} export interface ComputeLogModuleRelations {} export interface ConfigSecretsUserModuleRelations {} export interface ConnectedAccountsModuleRelations {} @@ -2077,6 +2225,9 @@ export interface DbUsageModuleRelations {} export interface DefaultIdsModuleRelations {} export interface DenormalizedTableFieldRelations {} export interface DevicesModuleRelations {} +export interface DomainModuleRelations { + catalogModule?: CatalogModule | null; +} export interface EmailsModuleRelations {} export interface EntityTypeProvisionRelations {} export interface EventsModuleRelations {} @@ -2129,9 +2280,16 @@ export interface ResourceModuleRelations { namespaceModule?: NamespaceModule | null; } export interface RlsModuleRelations {} +export interface RouteModuleRelations { + catalogModule?: CatalogModule | null; + domainModule?: DomainModule | null; +} export interface SecureTableProvisionRelations {} export interface SessionSecretsModuleRelations {} export interface SessionsModuleRelations {} +export interface SiteSurfaceModuleRelations { + catalogModule?: CatalogModule | null; +} export interface StorageLogModuleRelations {} export interface StorageModuleRelations {} export interface TransferLogModuleRelations {} @@ -2150,6 +2308,8 @@ export interface WebhookModuleRelations { } // ============ Entity Types With Relations ============ export type AgentModuleWithRelations = AgentModule & AgentModuleRelations; +export type ApiSurfaceModuleWithRelations = ApiSurfaceModule & ApiSurfaceModuleRelations; +export type AppModuleWithRelations = AppModule & AppModuleRelations; export type BillingModuleWithRelations = BillingModule & BillingModuleRelations; export type BillingProviderModuleWithRelations = BillingProviderModule & BillingProviderModuleRelations; @@ -2157,6 +2317,7 @@ export type BlueprintWithRelations = Blueprint & BlueprintRelations; export type BlueprintConstructionWithRelations = BlueprintConstruction & BlueprintConstructionRelations; export type BlueprintTemplateWithRelations = BlueprintTemplate & BlueprintTemplateRelations; +export type CatalogModuleWithRelations = CatalogModule & CatalogModuleRelations; export type ComputeLogModuleWithRelations = ComputeLogModule & ComputeLogModuleRelations; export type ConfigSecretsUserModuleWithRelations = ConfigSecretsUserModule & ConfigSecretsUserModuleRelations; @@ -2175,6 +2336,7 @@ export type DefaultIdsModuleWithRelations = DefaultIdsModule & DefaultIdsModuleR export type DenormalizedTableFieldWithRelations = DenormalizedTableField & DenormalizedTableFieldRelations; export type DevicesModuleWithRelations = DevicesModule & DevicesModuleRelations; +export type DomainModuleWithRelations = DomainModule & DomainModuleRelations; export type EmailsModuleWithRelations = EmailsModule & EmailsModuleRelations; export type EntityTypeProvisionWithRelations = EntityTypeProvision & EntityTypeProvisionRelations; export type EventsModuleWithRelations = EventsModule & EventsModuleRelations; @@ -2218,11 +2380,13 @@ export type RealtimeModuleWithRelations = RealtimeModule & RealtimeModuleRelatio export type RelationProvisionWithRelations = RelationProvision & RelationProvisionRelations; export type ResourceModuleWithRelations = ResourceModule & ResourceModuleRelations; export type RlsModuleWithRelations = RlsModule & RlsModuleRelations; +export type RouteModuleWithRelations = RouteModule & RouteModuleRelations; export type SecureTableProvisionWithRelations = SecureTableProvision & SecureTableProvisionRelations; export type SessionSecretsModuleWithRelations = SessionSecretsModule & SessionSecretsModuleRelations; export type SessionsModuleWithRelations = SessionsModule & SessionsModuleRelations; +export type SiteSurfaceModuleWithRelations = SiteSurfaceModule & SiteSurfaceModuleRelations; export type StorageLogModuleWithRelations = StorageLogModule & StorageLogModuleRelations; export type StorageModuleWithRelations = StorageModule & StorageModuleRelations; export type TransferLogModuleWithRelations = TransferLogModule & TransferLogModuleRelations; @@ -2275,6 +2439,52 @@ export type AgentModuleSelect = { threadTableId?: boolean; threadTableName?: boolean; }; +export type ApiSurfaceModuleSelect = { + apiName?: boolean; + apisTableId?: boolean; + apisTableName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; +export type AppModuleSelect = { + apiName?: boolean; + appMembersTableId?: boolean; + appMembersTableName?: boolean; + appsTableId?: boolean; + appsTableName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + privateSchemaId?: boolean; + privateSchemaName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type BillingModuleSelect = { apiName?: boolean; balancesTableId?: boolean; @@ -2404,6 +2614,37 @@ export type BlueprintTemplateSelect = { orderBy?: BlueprintOrderBy[]; }; }; +export type CatalogModuleSelect = { + apiName?: boolean; + apisTableId?: boolean; + apisTableName?: boolean; + appsTableId?: boolean; + appsTableName?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainsTableId?: boolean; + domainsTableName?: boolean; + entityTableId?: boolean; + functionsTableId?: boolean; + functionsTableName?: boolean; + id?: boolean; + namespacesTableId?: boolean; + namespacesTableName?: boolean; + policies?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + resourceDefinitionsTableId?: boolean; + resourceDefinitionsTableName?: boolean; + resourceInstallationsTableId?: boolean; + resourceInstallationsTableName?: boolean; + resourcesTableId?: boolean; + resourcesTableName?: boolean; + schemaId?: boolean; + scope?: boolean; + sitesTableId?: boolean; + sitesTableName?: boolean; +}; export type ComputeLogModuleSelect = { actorFkTableId?: boolean; apiName?: boolean; @@ -2476,6 +2717,7 @@ export type CryptoAuthModuleSelect = { usersTableId?: boolean; }; export type DatabaseProvisionModuleSelect = { + async?: boolean; bootstrapError?: boolean; bootstrapStatus?: boolean; bootstrapUser?: boolean; @@ -2600,6 +2842,31 @@ export type DevicesModuleSelect = { userDevicesTableId?: boolean; userDevicesTableName?: boolean; }; +export type DomainModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainEventsTableId?: boolean; + domainEventsTableName?: boolean; + domainVerificationsTableId?: boolean; + domainVerificationsTableName?: boolean; + domainsTableId?: boolean; + domainsTableName?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type EmailsModuleSelect = { apiName?: boolean; databaseId?: boolean; @@ -2729,6 +2996,8 @@ export type FunctionDeploymentModuleSelect = { }; export type FunctionInvocationModuleSelect = { apiName?: boolean; + attemptsTableId?: boolean; + attemptsTableName?: boolean; databaseId?: boolean; defaultPermissions?: boolean; entityField?: boolean; @@ -3422,6 +3691,38 @@ export type RlsModuleSelect = { sessionsTableId?: boolean; usersTableId?: boolean; }; +export type RouteModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + domainModuleId?: boolean; + entityField?: boolean; + entityTableId?: boolean; + hostnameBindingsTableId?: boolean; + hostnameBindingsTableName?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + privateSchemaId?: boolean; + privateSchemaName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + resolverFunctionName?: boolean; + routeBindingsTableId?: boolean; + routeBindingsTableName?: boolean; + routesTableId?: boolean; + routesTableName?: boolean; + schemaId?: boolean; + scope?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; + domainModule?: { + select: DomainModuleSelect; + }; +}; export type SecureTableProvisionSelect = { databaseId?: boolean; fields?: boolean; @@ -3456,6 +3757,27 @@ export type SessionsModuleSelect = { sessionsTableName?: boolean; usersTableId?: boolean; }; +export type SiteSurfaceModuleSelect = { + apiName?: boolean; + catalogModuleId?: boolean; + databaseId?: boolean; + defaultPermissions?: boolean; + entityField?: boolean; + entityTableId?: boolean; + id?: boolean; + policies?: boolean; + prefix?: boolean; + privateApiName?: boolean; + provisions?: boolean; + publicSchemaName?: boolean; + schemaId?: boolean; + scope?: boolean; + sitesTableId?: boolean; + sitesTableName?: boolean; + catalogModule?: { + select: CatalogModuleSelect; + }; +}; export type StorageLogModuleSelect = { actorFkTableId?: boolean; apiName?: boolean; @@ -3756,74 +4078,170 @@ export interface AgentModuleFilter { /** Filter by the object’s `threadTableName` field. */ threadTableName?: StringFilter; } -export interface BillingModuleFilter { +export interface ApiSurfaceModuleFilter { /** Checks for all expressions in this list. */ - and?: BillingModuleFilter[]; + and?: ApiSurfaceModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; - /** Filter by the object’s `balancesTableId` field. */ - balancesTableId?: UUIDFilter; - /** Filter by the object’s `balancesTableName` field. */ - balancesTableName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `defaultPermissions` field. */ defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; /** Filter by the object’s `id` field. */ id?: UUIDFilter; - /** Filter by the object’s `ledgerTableId` field. */ - ledgerTableId?: UUIDFilter; - /** Filter by the object’s `ledgerTableName` field. */ - ledgerTableName?: StringFilter; - /** Filter by the object’s `meterCreditsTableId` field. */ - meterCreditsTableId?: UUIDFilter; - /** Filter by the object’s `meterCreditsTableName` field. */ - meterCreditsTableName?: StringFilter; - /** Filter by the object’s `meterDefaultsTableId` field. */ - meterDefaultsTableId?: UUIDFilter; - /** Filter by the object’s `meterDefaultsTableName` field. */ - meterDefaultsTableName?: StringFilter; - /** Filter by the object’s `meterSourcesTableId` field. */ - meterSourcesTableId?: UUIDFilter; - /** Filter by the object’s `meterSourcesTableName` field. */ - meterSourcesTableName?: StringFilter; - /** Filter by the object’s `metersTableId` field. */ - metersTableId?: UUIDFilter; - /** Filter by the object’s `metersTableName` field. */ - metersTableName?: StringFilter; /** Negates the expression. */ - not?: BillingModuleFilter; + not?: ApiSurfaceModuleFilter; /** Checks for any expressions in this list. */ - or?: BillingModuleFilter[]; - /** Filter by the object’s `planSubscriptionsTableId` field. */ - planSubscriptionsTableId?: UUIDFilter; - /** Filter by the object’s `planSubscriptionsTableName` field. */ - planSubscriptionsTableName?: StringFilter; + or?: ApiSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; /** Filter by the object’s `prefix` field. */ prefix?: StringFilter; /** Filter by the object’s `privateApiName` field. */ privateApiName?: StringFilter; - /** Filter by the object’s `privateSchemaId` field. */ - privateSchemaId?: UUIDFilter; - /** Filter by the object’s `privateSchemaName` field. */ - privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; /** Filter by the object’s `publicSchemaName` field. */ publicSchemaName?: StringFilter; - /** Filter by the object’s `recordUsageFunction` field. */ - recordUsageFunction?: StringFilter; - /** Filter by the object’s `rollupUsageSummaryFunction` field. */ - rollupUsageSummaryFunction?: StringFilter; /** Filter by the object’s `schemaId` field. */ schemaId?: UUIDFilter; - /** Filter by the object’s `sweepExpiredSubscriptionsFunction` field. */ - sweepExpiredSubscriptionsFunction?: StringFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; } -export interface BillingProviderModuleFilter { +export interface AppModuleFilter { /** Checks for all expressions in this list. */ - and?: BillingProviderModuleFilter[]; + and?: AppModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; - /** Filter by the object’s `billingCustomersTableId` field. */ + /** Filter by the object’s `appMembersTableId` field. */ + appMembersTableId?: UUIDFilter; + /** Filter by the object’s `appMembersTableName` field. */ + appMembersTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: AppModuleFilter; + /** Checks for any expressions in this list. */ + or?: AppModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} +export interface BillingModuleFilter { + /** Checks for all expressions in this list. */ + and?: BillingModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `balancesTableId` field. */ + balancesTableId?: UUIDFilter; + /** Filter by the object’s `balancesTableName` field. */ + balancesTableName?: StringFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `ledgerTableId` field. */ + ledgerTableId?: UUIDFilter; + /** Filter by the object’s `ledgerTableName` field. */ + ledgerTableName?: StringFilter; + /** Filter by the object’s `meterCreditsTableId` field. */ + meterCreditsTableId?: UUIDFilter; + /** Filter by the object’s `meterCreditsTableName` field. */ + meterCreditsTableName?: StringFilter; + /** Filter by the object’s `meterDefaultsTableId` field. */ + meterDefaultsTableId?: UUIDFilter; + /** Filter by the object’s `meterDefaultsTableName` field. */ + meterDefaultsTableName?: StringFilter; + /** Filter by the object’s `meterSourcesTableId` field. */ + meterSourcesTableId?: UUIDFilter; + /** Filter by the object’s `meterSourcesTableName` field. */ + meterSourcesTableName?: StringFilter; + /** Filter by the object’s `metersTableId` field. */ + metersTableId?: UUIDFilter; + /** Filter by the object’s `metersTableName` field. */ + metersTableName?: StringFilter; + /** Negates the expression. */ + not?: BillingModuleFilter; + /** Checks for any expressions in this list. */ + or?: BillingModuleFilter[]; + /** Filter by the object’s `planSubscriptionsTableId` field. */ + planSubscriptionsTableId?: UUIDFilter; + /** Filter by the object’s `planSubscriptionsTableName` field. */ + planSubscriptionsTableName?: StringFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `recordUsageFunction` field. */ + recordUsageFunction?: StringFilter; + /** Filter by the object’s `rollupUsageSummaryFunction` field. */ + rollupUsageSummaryFunction?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `sweepExpiredSubscriptionsFunction` field. */ + sweepExpiredSubscriptionsFunction?: StringFilter; +} +export interface BillingProviderModuleFilter { + /** Checks for all expressions in this list. */ + and?: BillingProviderModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `billingCustomersTableId` field. */ billingCustomersTableId?: UUIDFilter; /** Filter by the object’s `billingCustomersTableName` field. */ billingCustomersTableName?: StringFilter; @@ -4002,6 +4420,72 @@ export interface BlueprintTemplateFilter { /** Filter by the object’s `visibility` field. */ visibility?: StringFilter; } +export interface CatalogModuleFilter { + /** Checks for all expressions in this list. */ + and?: CatalogModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `apisTableId` field. */ + apisTableId?: UUIDFilter; + /** Filter by the object’s `apisTableName` field. */ + apisTableName?: StringFilter; + /** Filter by the object’s `appsTableId` field. */ + appsTableId?: UUIDFilter; + /** Filter by the object’s `appsTableName` field. */ + appsTableName?: StringFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableId` field. */ + functionsTableId?: UUIDFilter; + /** Filter by the object’s `functionsTableName` field. */ + functionsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Filter by the object’s `namespacesTableId` field. */ + namespacesTableId?: UUIDFilter; + /** Filter by the object’s `namespacesTableName` field. */ + namespacesTableName?: StringFilter; + /** Negates the expression. */ + not?: CatalogModuleFilter; + /** Checks for any expressions in this list. */ + or?: CatalogModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resourceDefinitionsTableId` field. */ + resourceDefinitionsTableId?: UUIDFilter; + /** Filter by the object’s `resourceDefinitionsTableName` field. */ + resourceDefinitionsTableName?: StringFilter; + /** Filter by the object’s `resourceInstallationsTableId` field. */ + resourceInstallationsTableId?: UUIDFilter; + /** Filter by the object’s `resourceInstallationsTableName` field. */ + resourceInstallationsTableName?: StringFilter; + /** Filter by the object’s `resourcesTableId` field. */ + resourcesTableId?: UUIDFilter; + /** Filter by the object’s `resourcesTableName` field. */ + resourcesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} export interface ComputeLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ actorFkTableId?: UUIDFilter; @@ -4167,6 +4651,8 @@ export interface CryptoAuthModuleFilter { export interface DatabaseProvisionModuleFilter { /** Checks for all expressions in this list. */ and?: DatabaseProvisionModuleFilter[]; + /** Filter by the object’s `async` field. */ + async?: BooleanFilter; /** Filter by the object’s `bootstrapError` field. */ bootstrapError?: StringFilter; /** Filter by the object’s `bootstrapStatus` field. */ @@ -4442,6 +4928,58 @@ export interface DevicesModuleFilter { /** Filter by the object’s `userDevicesTableName` field. */ userDevicesTableName?: StringFilter; } +export interface DomainModuleFilter { + /** Checks for all expressions in this list. */ + and?: DomainModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainEventsTableId` field. */ + domainEventsTableId?: UUIDFilter; + /** Filter by the object’s `domainEventsTableName` field. */ + domainEventsTableName?: StringFilter; + /** Filter by the object’s `domainVerificationsTableId` field. */ + domainVerificationsTableId?: UUIDFilter; + /** Filter by the object’s `domainVerificationsTableName` field. */ + domainVerificationsTableName?: StringFilter; + /** Filter by the object’s `domainsTableId` field. */ + domainsTableId?: UUIDFilter; + /** Filter by the object’s `domainsTableName` field. */ + domainsTableName?: StringFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: DomainModuleFilter; + /** Checks for any expressions in this list. */ + or?: DomainModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} export interface EmailsModuleFilter { /** Checks for all expressions in this list. */ and?: EmailsModuleFilter[]; @@ -4713,6 +5251,10 @@ export interface FunctionInvocationModuleFilter { and?: FunctionInvocationModuleFilter[]; /** Filter by the object’s `apiName` field. */ apiName?: StringFilter; + /** Filter by the object’s `attemptsTableId` field. */ + attemptsTableId?: UUIDFilter; + /** Filter by the object’s `attemptsTableName` field. */ + attemptsTableName?: StringFilter; /** Filter by the object’s `databaseId` field. */ databaseId?: UUIDFilter; /** Filter by the object’s `defaultPermissions` field. */ @@ -6188,6 +6730,70 @@ export interface RlsModuleFilter { /** Filter by the object’s `usersTableId` field. */ usersTableId?: UUIDFilter; } +export interface RouteModuleFilter { + /** Checks for all expressions in this list. */ + and?: RouteModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `domainModule` relation. */ + domainModule?: DomainModuleFilter; + /** A related `domainModule` exists. */ + domainModuleExists?: boolean; + /** Filter by the object’s `domainModuleId` field. */ + domainModuleId?: UUIDFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableId` field. */ + hostnameBindingsTableId?: UUIDFilter; + /** Filter by the object’s `hostnameBindingsTableName` field. */ + hostnameBindingsTableName?: StringFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: RouteModuleFilter; + /** Checks for any expressions in this list. */ + or?: RouteModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `privateSchemaId` field. */ + privateSchemaId?: UUIDFilter; + /** Filter by the object’s `privateSchemaName` field. */ + privateSchemaName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `resolverFunctionName` field. */ + resolverFunctionName?: StringFilter; + /** Filter by the object’s `routeBindingsTableId` field. */ + routeBindingsTableId?: UUIDFilter; + /** Filter by the object’s `routeBindingsTableName` field. */ + routeBindingsTableName?: StringFilter; + /** Filter by the object’s `routesTableId` field. */ + routesTableId?: UUIDFilter; + /** Filter by the object’s `routesTableName` field. */ + routesTableName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; +} export interface SecureTableProvisionFilter { /** Checks for all expressions in this list. */ and?: SecureTableProvisionFilter[]; @@ -6268,6 +6874,50 @@ export interface SessionsModuleFilter { /** Filter by the object’s `usersTableId` field. */ usersTableId?: UUIDFilter; } +export interface SiteSurfaceModuleFilter { + /** Checks for all expressions in this list. */ + and?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `apiName` field. */ + apiName?: StringFilter; + /** Filter by the object’s `catalogModule` relation. */ + catalogModule?: CatalogModuleFilter; + /** A related `catalogModule` exists. */ + catalogModuleExists?: boolean; + /** Filter by the object’s `catalogModuleId` field. */ + catalogModuleId?: UUIDFilter; + /** Filter by the object’s `databaseId` field. */ + databaseId?: UUIDFilter; + /** Filter by the object’s `defaultPermissions` field. */ + defaultPermissions?: StringListFilter; + /** Filter by the object’s `entityField` field. */ + entityField?: StringFilter; + /** Filter by the object’s `entityTableId` field. */ + entityTableId?: UUIDFilter; + /** Filter by the object’s `id` field. */ + id?: UUIDFilter; + /** Negates the expression. */ + not?: SiteSurfaceModuleFilter; + /** Checks for any expressions in this list. */ + or?: SiteSurfaceModuleFilter[]; + /** Filter by the object’s `policies` field. */ + policies?: JSONFilter; + /** Filter by the object’s `prefix` field. */ + prefix?: StringFilter; + /** Filter by the object’s `privateApiName` field. */ + privateApiName?: StringFilter; + /** Filter by the object’s `provisions` field. */ + provisions?: JSONFilter; + /** Filter by the object’s `publicSchemaName` field. */ + publicSchemaName?: StringFilter; + /** Filter by the object’s `schemaId` field. */ + schemaId?: UUIDFilter; + /** Filter by the object’s `scope` field. */ + scope?: StringFilter; + /** Filter by the object’s `sitesTableId` field. */ + sitesTableId?: UUIDFilter; + /** Filter by the object’s `sitesTableName` field. */ + sitesTableName?: StringFilter; +} export interface StorageLogModuleFilter { /** Filter by the object’s `actorFkTableId` field. */ actorFkTableId?: UUIDFilter; @@ -6819,6 +7469,86 @@ export type AgentModuleOrderBy = | 'THREAD_TABLE_ID_DESC' | 'THREAD_TABLE_NAME_ASC' | 'THREAD_TABLE_NAME_DESC'; +export type ApiSurfaceModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; +export type AppModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'APP_MEMBERS_TABLE_ID_ASC' + | 'APP_MEMBERS_TABLE_ID_DESC' + | 'APP_MEMBERS_TABLE_NAME_ASC' + | 'APP_MEMBERS_TABLE_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type BillingModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' @@ -7023,6 +7753,68 @@ export type BlueprintTemplateOrderBy = | 'VERSION_DESC' | 'VISIBILITY_ASC' | 'VISIBILITY_DESC'; +export type CatalogModuleOrderBy = + | 'APIS_TABLE_ID_ASC' + | 'APIS_TABLE_ID_DESC' + | 'APIS_TABLE_NAME_ASC' + | 'APIS_TABLE_NAME_DESC' + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'APPS_TABLE_ID_ASC' + | 'APPS_TABLE_ID_DESC' + | 'APPS_TABLE_NAME_ASC' + | 'APPS_TABLE_NAME_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_ID_ASC' + | 'FUNCTIONS_TABLE_ID_DESC' + | 'FUNCTIONS_TABLE_NAME_ASC' + | 'FUNCTIONS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NAMESPACES_TABLE_ID_ASC' + | 'NAMESPACES_TABLE_ID_DESC' + | 'NAMESPACES_TABLE_NAME_ASC' + | 'NAMESPACES_TABLE_NAME_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOURCES_TABLE_ID_ASC' + | 'RESOURCES_TABLE_ID_DESC' + | 'RESOURCES_TABLE_NAME_ASC' + | 'RESOURCES_TABLE_NAME_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_ID_DESC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_ASC' + | 'RESOURCE_DEFINITIONS_TABLE_NAME_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_ID_DESC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_ASC' + | 'RESOURCE_INSTALLATIONS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; export type ComputeLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' | 'ACTOR_FK_TABLE_ID_DESC' @@ -7166,6 +7958,8 @@ export type CryptoAuthModuleOrderBy = | 'USER_FIELD_ASC' | 'USER_FIELD_DESC'; export type DatabaseProvisionModuleOrderBy = + | 'ASYNC_ASC' + | 'ASYNC_DESC' | 'BOOTSTRAP_ERROR_ASC' | 'BOOTSTRAP_ERROR_DESC' | 'BOOTSTRAP_STATUS_ASC' @@ -7409,6 +8203,50 @@ export type DevicesModuleOrderBy = | 'USER_DEVICES_TABLE_ID_DESC' | 'USER_DEVICES_TABLE_NAME_ASC' | 'USER_DEVICES_TABLE_NAME_DESC'; +export type DomainModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAINS_TABLE_ID_ASC' + | 'DOMAINS_TABLE_ID_DESC' + | 'DOMAINS_TABLE_NAME_ASC' + | 'DOMAINS_TABLE_NAME_DESC' + | 'DOMAIN_EVENTS_TABLE_ID_ASC' + | 'DOMAIN_EVENTS_TABLE_ID_DESC' + | 'DOMAIN_EVENTS_TABLE_NAME_ASC' + | 'DOMAIN_EVENTS_TABLE_NAME_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_ID_DESC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_ASC' + | 'DOMAIN_VERIFICATIONS_TABLE_NAME_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type EmailsModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' @@ -7654,6 +8492,10 @@ export type FunctionDeploymentModuleOrderBy = export type FunctionInvocationModuleOrderBy = | 'API_NAME_ASC' | 'API_NAME_DESC' + | 'ATTEMPTS_TABLE_ID_ASC' + | 'ATTEMPTS_TABLE_ID_DESC' + | 'ATTEMPTS_TABLE_NAME_ASC' + | 'ATTEMPTS_TABLE_NAME_DESC' | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' | 'DEFAULT_PERMISSIONS_ASC' @@ -8975,6 +9817,58 @@ export type RlsModuleOrderBy = | 'SESSION_CREDENTIALS_TABLE_ID_DESC' | 'USERS_TABLE_ID_ASC' | 'USERS_TABLE_ID_DESC'; +export type RouteModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'DOMAIN_MODULE_ID_ASC' + | 'DOMAIN_MODULE_ID_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_ID_ASC' + | 'HOSTNAME_BINDINGS_TABLE_ID_DESC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_ASC' + | 'HOSTNAME_BINDINGS_TABLE_NAME_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PRIVATE_SCHEMA_ID_ASC' + | 'PRIVATE_SCHEMA_ID_DESC' + | 'PRIVATE_SCHEMA_NAME_ASC' + | 'PRIVATE_SCHEMA_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'RESOLVER_FUNCTION_NAME_ASC' + | 'RESOLVER_FUNCTION_NAME_DESC' + | 'ROUTES_TABLE_ID_ASC' + | 'ROUTES_TABLE_ID_DESC' + | 'ROUTES_TABLE_NAME_ASC' + | 'ROUTES_TABLE_NAME_DESC' + | 'ROUTE_BINDINGS_TABLE_ID_ASC' + | 'ROUTE_BINDINGS_TABLE_ID_DESC' + | 'ROUTE_BINDINGS_TABLE_NAME_ASC' + | 'ROUTE_BINDINGS_TABLE_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC'; export type SecureTableProvisionOrderBy = | 'DATABASE_ID_ASC' | 'DATABASE_ID_DESC' @@ -9031,18 +9925,54 @@ export type SessionsModuleOrderBy = | 'PRIMARY_KEY_DESC' | 'SCHEMA_ID_ASC' | 'SCHEMA_ID_DESC' - | 'SESSIONS_DEFAULT_EXPIRATION_ASC' - | 'SESSIONS_DEFAULT_EXPIRATION_DESC' - | 'SESSIONS_TABLE_ID_ASC' - | 'SESSIONS_TABLE_ID_DESC' - | 'SESSIONS_TABLE_NAME_ASC' - | 'SESSIONS_TABLE_NAME_DESC' - | 'SESSION_CREDENTIALS_TABLE_ID_ASC' - | 'SESSION_CREDENTIALS_TABLE_ID_DESC' - | 'SESSION_CREDENTIALS_TABLE_NAME_ASC' - | 'SESSION_CREDENTIALS_TABLE_NAME_DESC' - | 'USERS_TABLE_ID_ASC' - | 'USERS_TABLE_ID_DESC'; + | 'SESSIONS_DEFAULT_EXPIRATION_ASC' + | 'SESSIONS_DEFAULT_EXPIRATION_DESC' + | 'SESSIONS_TABLE_ID_ASC' + | 'SESSIONS_TABLE_ID_DESC' + | 'SESSIONS_TABLE_NAME_ASC' + | 'SESSIONS_TABLE_NAME_DESC' + | 'SESSION_CREDENTIALS_TABLE_ID_ASC' + | 'SESSION_CREDENTIALS_TABLE_ID_DESC' + | 'SESSION_CREDENTIALS_TABLE_NAME_ASC' + | 'SESSION_CREDENTIALS_TABLE_NAME_DESC' + | 'USERS_TABLE_ID_ASC' + | 'USERS_TABLE_ID_DESC'; +export type SiteSurfaceModuleOrderBy = + | 'API_NAME_ASC' + | 'API_NAME_DESC' + | 'CATALOG_MODULE_ID_ASC' + | 'CATALOG_MODULE_ID_DESC' + | 'DATABASE_ID_ASC' + | 'DATABASE_ID_DESC' + | 'DEFAULT_PERMISSIONS_ASC' + | 'DEFAULT_PERMISSIONS_DESC' + | 'ENTITY_FIELD_ASC' + | 'ENTITY_FIELD_DESC' + | 'ENTITY_TABLE_ID_ASC' + | 'ENTITY_TABLE_ID_DESC' + | 'ID_ASC' + | 'ID_DESC' + | 'NATURAL' + | 'POLICIES_ASC' + | 'POLICIES_DESC' + | 'PREFIX_ASC' + | 'PREFIX_DESC' + | 'PRIMARY_KEY_ASC' + | 'PRIMARY_KEY_DESC' + | 'PRIVATE_API_NAME_ASC' + | 'PRIVATE_API_NAME_DESC' + | 'PROVISIONS_ASC' + | 'PROVISIONS_DESC' + | 'PUBLIC_SCHEMA_NAME_ASC' + | 'PUBLIC_SCHEMA_NAME_DESC' + | 'SCHEMA_ID_ASC' + | 'SCHEMA_ID_DESC' + | 'SCOPE_ASC' + | 'SCOPE_DESC' + | 'SITES_TABLE_ID_ASC' + | 'SITES_TABLE_ID_DESC' + | 'SITES_TABLE_NAME_ASC' + | 'SITES_TABLE_NAME_DESC'; export type StorageLogModuleOrderBy = | 'ACTOR_FK_TABLE_ID_ASC' | 'ACTOR_FK_TABLE_ID_DESC' @@ -9544,6 +10474,106 @@ export interface DeleteAgentModuleInput { clientMutationId?: string; id: string; } +export interface CreateApiSurfaceModuleInput { + clientMutationId?: string; + apiSurfaceModule: { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface ApiSurfaceModulePatch { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateApiSurfaceModuleInput { + clientMutationId?: string; + id: string; + apiSurfaceModulePatch: ApiSurfaceModulePatch; +} +export interface DeleteApiSurfaceModuleInput { + clientMutationId?: string; + id: string; +} +export interface CreateAppModuleInput { + clientMutationId?: string; + appModule: { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface AppModulePatch { + apiName?: string | null; + appMembersTableId?: string | null; + appMembersTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateAppModuleInput { + clientMutationId?: string; + id: string; + appModulePatch: AppModulePatch; +} +export interface DeleteAppModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateBillingModuleInput { clientMutationId?: string; billingModule: { @@ -9786,6 +10816,78 @@ export interface DeleteBlueprintTemplateInput { clientMutationId?: string; id: string; } +export interface CreateCatalogModuleInput { + clientMutationId?: string; + catalogModule: { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: Record; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; + }; +} +export interface CatalogModulePatch { + apiName?: string | null; + apisTableId?: string | null; + apisTableName?: string | null; + appsTableId?: string | null; + appsTableName?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityTableId?: string | null; + functionsTableId?: string | null; + functionsTableName?: string | null; + namespacesTableId?: string | null; + namespacesTableName?: string | null; + policies?: Record | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resourceDefinitionsTableId?: string | null; + resourceDefinitionsTableName?: string | null; + resourceInstallationsTableId?: string | null; + resourceInstallationsTableName?: string | null; + resourcesTableId?: string | null; + resourcesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; +} +export interface UpdateCatalogModuleInput { + clientMutationId?: string; + id: string; + catalogModulePatch: CatalogModulePatch; +} +export interface DeleteCatalogModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateComputeLogModuleInput { clientMutationId?: string; computeLogModule: { @@ -9981,6 +11083,7 @@ export interface DeleteCryptoAuthModuleInput { export interface CreateDatabaseProvisionModuleInput { clientMutationId?: string; databaseProvisionModule: { + async?: boolean; bootstrapError?: string; bootstrapStatus?: string; bootstrapUser?: boolean; @@ -9999,6 +11102,7 @@ export interface CreateDatabaseProvisionModuleInput { }; } export interface DatabaseProvisionModulePatch { + async?: boolean | null; bootstrapError?: string | null; bootstrapStatus?: string | null; bootstrapUser?: boolean | null; @@ -10288,6 +11392,60 @@ export interface DeleteDevicesModuleInput { clientMutationId?: string; id: string; } +export interface CreateDomainModuleInput { + clientMutationId?: string; + domainModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface DomainModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainEventsTableId?: string | null; + domainEventsTableName?: string | null; + domainVerificationsTableId?: string | null; + domainVerificationsTableName?: string | null; + domainsTableId?: string | null; + domainsTableName?: string | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateDomainModuleInput { + clientMutationId?: string; + id: string; + domainModulePatch: DomainModulePatch; +} +export interface DeleteDomainModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateEmailsModuleInput { clientMutationId?: string; emailsModule: { @@ -10574,6 +11732,8 @@ export interface CreateFunctionInvocationModuleInput { clientMutationId?: string; functionInvocationModule: { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId: string; defaultPermissions?: string[]; entityField?: string; @@ -10595,6 +11755,8 @@ export interface CreateFunctionInvocationModuleInput { } export interface FunctionInvocationModulePatch { apiName?: string | null; + attemptsTableId?: string | null; + attemptsTableName?: string | null; databaseId?: string | null; defaultPermissions?: string[] | null; entityField?: string | null; @@ -12196,6 +13358,68 @@ export interface DeleteRlsModuleInput { clientMutationId?: string; id: string; } +export interface CreateRouteModuleInput { + clientMutationId?: string; + routeModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; + }; +} +export interface RouteModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + domainModuleId?: string | null; + entityField?: string | null; + entityTableId?: string | null; + hostnameBindingsTableId?: string | null; + hostnameBindingsTableName?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + privateSchemaId?: string | null; + privateSchemaName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + resolverFunctionName?: string | null; + routeBindingsTableId?: string | null; + routeBindingsTableName?: string | null; + routesTableId?: string | null; + routesTableName?: string | null; + schemaId?: string | null; + scope?: string | null; +} +export interface UpdateRouteModuleInput { + clientMutationId?: string; + id: string; + routeModulePatch: RouteModulePatch; +} +export interface DeleteRouteModuleInput { + clientMutationId?: string; + id: string; +} export interface CreateSecureTableProvisionInput { clientMutationId?: string; secureTableProvision: { @@ -12278,19 +13502,65 @@ export interface SessionsModulePatch { authSettingsTableName?: string | null; databaseId?: string | null; schemaId?: string | null; - sessionCredentialsTableId?: string | null; - sessionCredentialsTableName?: string | null; - sessionsDefaultExpiration?: IntervalInput | null; - sessionsTableId?: string | null; - sessionsTableName?: string | null; - usersTableId?: string | null; + sessionCredentialsTableId?: string | null; + sessionCredentialsTableName?: string | null; + sessionsDefaultExpiration?: IntervalInput | null; + sessionsTableId?: string | null; + sessionsTableName?: string | null; + usersTableId?: string | null; +} +export interface UpdateSessionsModuleInput { + clientMutationId?: string; + id: string; + sessionsModulePatch: SessionsModulePatch; +} +export interface DeleteSessionsModuleInput { + clientMutationId?: string; + id: string; +} +export interface CreateSiteSurfaceModuleInput { + clientMutationId?: string; + siteSurfaceModule: { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; + }; +} +export interface SiteSurfaceModulePatch { + apiName?: string | null; + catalogModuleId?: string | null; + databaseId?: string | null; + defaultPermissions?: string[] | null; + entityField?: string | null; + entityTableId?: string | null; + policies?: Record | null; + prefix?: string | null; + privateApiName?: string | null; + provisions?: Record | null; + publicSchemaName?: string | null; + schemaId?: string | null; + scope?: string | null; + sitesTableId?: string | null; + sitesTableName?: string | null; } -export interface UpdateSessionsModuleInput { +export interface UpdateSiteSurfaceModuleInput { clientMutationId?: string; id: string; - sessionsModulePatch: SessionsModulePatch; + siteSurfaceModulePatch: SiteSurfaceModulePatch; } -export interface DeleteSessionsModuleInput { +export interface DeleteSiteSurfaceModuleInput { clientMutationId?: string; id: string; } @@ -12897,14 +14167,14 @@ export interface ProvisionRelationInput { } export interface ProvisionSpatialRelationInput { clientMutationId?: string; - pDatabaseId?: string; - pName?: string; - pOperator?: string; - pParamName?: string; - pSourceFieldId?: string; - pSourceTableId?: string; - pTargetFieldId?: string; - pTargetTableId?: string; + databaseId?: string; + name?: string; + operator?: string; + paramName?: string; + sourceFieldId?: string; + sourceTableId?: string; + targetFieldId?: string; + targetTableId?: string; } export interface ProvisionTableInput { clientMutationId?: string; @@ -13076,6 +14346,48 @@ export interface AgentModuleInput { threadTableId?: string; threadTableName?: string; } +/** An input for mutations affecting `ApiSurfaceModule` */ +export interface ApiSurfaceModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} +/** An input for mutations affecting `AppModule` */ +export interface AppModuleInput { + apiName?: string; + appMembersTableId?: string; + appMembersTableName?: string; + appsTableId?: string; + appsTableName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `BillingModule` */ export interface BillingModuleInput { apiName?: string; @@ -13226,6 +14538,38 @@ export interface BlueprintTemplateInput { /** Access control for the template. private: only the owner can see and copy. public: anyone can browse and copy from the marketplace. Defaults to private. */ visibility?: string; } +/** An input for mutations affecting `CatalogModule` */ +export interface CatalogModuleInput { + apiName?: string; + apisTableId?: string; + apisTableName?: string; + appsTableId?: string; + appsTableName?: string; + databaseId: string; + defaultPermissions?: string[]; + domainsTableId?: string; + domainsTableName?: string; + entityTableId?: string; + functionsTableId?: string; + functionsTableName?: string; + id?: string; + namespacesTableId?: string; + namespacesTableName?: string; + policies?: Record; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + resourceDefinitionsTableId?: string; + resourceDefinitionsTableName?: string; + resourceInstallationsTableId?: string; + resourceInstallationsTableName?: string; + resourcesTableId?: string; + resourcesTableName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** An input for mutations affecting `ComputeLogModule` */ export interface ComputeLogModuleInput { actorFkTableId?: string; @@ -13304,6 +14648,8 @@ export interface CryptoAuthModuleInput { } /** An input for mutations affecting `DatabaseProvisionModule` */ export interface DatabaseProvisionModuleInput { + /** When true, cold provisioning runs in the database:provision background job and the insert returns a pending ticket; when false, provisioning runs inline in the insert trigger */ + async?: boolean; /** Error message from the most recent failed bootstrap attempt */ bootstrapError?: string; /** Status of the deferred owner bootstrap job: not_requested, pending, completed, or failed */ @@ -13477,6 +14823,29 @@ export interface DevicesModuleInput { userDevicesTableId?: string; userDevicesTableName?: string; } +/** An input for mutations affecting `DomainModule` */ +export interface DomainModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainEventsTableId?: string; + domainEventsTableName?: string; + domainVerificationsTableId?: string; + domainVerificationsTableName?: string; + domainsTableId?: string; + domainsTableName?: string; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `EmailsModule` */ export interface EmailsModuleInput { apiName?: string; @@ -13815,6 +15184,8 @@ export interface FunctionDeploymentModuleInput { /** An input for mutations affecting `FunctionInvocationModule` */ export interface FunctionInvocationModuleInput { apiName?: string; + attemptsTableId?: string; + attemptsTableName?: string; databaseId: string; defaultPermissions?: string[]; entityField?: string; @@ -14603,6 +15974,33 @@ export interface RlsModuleInput { sessionsTableId?: string; usersTableId?: string; } +/** An input for mutations affecting `RouteModule` */ +export interface RouteModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + domainModuleId?: string; + entityField?: string; + entityTableId?: string; + hostnameBindingsTableId?: string; + hostnameBindingsTableName?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + privateSchemaId?: string; + privateSchemaName?: string; + provisions?: Record; + publicSchemaName?: string; + resolverFunctionName?: string; + routeBindingsTableId?: string; + routeBindingsTableName?: string; + routesTableId?: string; + routesTableName?: string; + schemaId?: string; + scope?: string; +} /** An input for mutations affecting `SecureTableProvision` */ export interface SecureTableProvisionInput { /** The database this provision belongs to. Required. */ @@ -14652,6 +16050,25 @@ export interface SessionsModuleInput { sessionsTableName?: string; usersTableId?: string; } +/** An input for mutations affecting `SiteSurfaceModule` */ +export interface SiteSurfaceModuleInput { + apiName?: string; + catalogModuleId?: string; + databaseId: string; + defaultPermissions?: string[]; + entityField?: string; + entityTableId?: string; + id?: string; + policies?: Record; + prefix?: string; + privateApiName?: string; + provisions?: Record; + publicSchemaName?: string; + schemaId?: string; + scope?: string; + sitesTableId?: string; + sitesTableName?: string; +} /** An input for mutations affecting `StorageLogModule` */ export interface StorageLogModuleInput { actorFkTableId?: string; @@ -15517,6 +16934,96 @@ export type DeleteAgentModulePayloadSelect = { }; clientMutationId?: boolean; }; +export interface CreateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was created by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was updated by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteApiSurfaceModulePayload { + /** The `ApiSurfaceModule` that was deleted by this mutation. */ + apiSurfaceModule?: ApiSurfaceModule | null; + apiSurfaceModuleEdge?: ApiSurfaceModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteApiSurfaceModulePayloadSelect = { + apiSurfaceModule?: { + select: ApiSurfaceModuleSelect; + }; + apiSurfaceModuleEdge?: { + select: ApiSurfaceModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface CreateAppModulePayload { + /** The `AppModule` that was created by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateAppModulePayload { + /** The `AppModule` that was updated by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteAppModulePayload { + /** The `AppModule` that was deleted by this mutation. */ + appModule?: AppModule | null; + appModuleEdge?: AppModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteAppModulePayloadSelect = { + appModule?: { + select: AppModuleSelect; + }; + appModuleEdge?: { + select: AppModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; export interface CreateBillingModulePayload { /** The `BillingModule` that was created by this mutation. */ billingModule?: BillingModule | null; @@ -15742,6 +17249,51 @@ export type DeleteBlueprintTemplatePayloadSelect = { }; clientMutationId?: boolean; }; +export interface CreateCatalogModulePayload { + /** The `CatalogModule` that was created by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type CreateCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface UpdateCatalogModulePayload { + /** The `CatalogModule` that was updated by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type UpdateCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; +export interface DeleteCatalogModulePayload { + /** The `CatalogModule` that was deleted by this mutation. */ + catalogModule?: CatalogModule | null; + catalogModuleEdge?: CatalogModuleEdge | null; + clientMutationId?: string | null; +} +export type DeleteCatalogModulePayloadSelect = { + catalogModule?: { + select: CatalogModuleSelect; + }; + catalogModuleEdge?: { + select: CatalogModuleEdgeSelect; + }; + clientMutationId?: boolean; +}; export interface CreateComputeLogModulePayload { clientMutationId?: string | null; /** The `ComputeLogModule` that was created by this mutation. */ @@ -16327,6 +17879,51 @@ export type DeleteDevicesModulePayloadSelect = { select: DevicesModuleEdgeSelect; }; }; +export interface CreateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was created by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type CreateDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; +export interface UpdateDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was updated by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type UpdateDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; +export interface DeleteDomainModulePayload { + clientMutationId?: string | null; + /** The `DomainModule` that was deleted by this mutation. */ + domainModule?: DomainModule | null; + domainModuleEdge?: DomainModuleEdge | null; +} +export type DeleteDomainModulePayloadSelect = { + clientMutationId?: boolean; + domainModule?: { + select: DomainModuleSelect; + }; + domainModuleEdge?: { + select: DomainModuleEdgeSelect; + }; +}; export interface CreateEmailsModulePayload { clientMutationId?: string | null; /** The `EmailsModule` that was created by this mutation. */ @@ -17902,6 +19499,51 @@ export type DeleteRlsModulePayloadSelect = { select: RlsModuleEdgeSelect; }; }; +export interface CreateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was created by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type CreateRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; +export interface UpdateRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was updated by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type UpdateRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; +export interface DeleteRouteModulePayload { + clientMutationId?: string | null; + /** The `RouteModule` that was deleted by this mutation. */ + routeModule?: RouteModule | null; + routeModuleEdge?: RouteModuleEdge | null; +} +export type DeleteRouteModulePayloadSelect = { + clientMutationId?: boolean; + routeModule?: { + select: RouteModuleSelect; + }; + routeModuleEdge?: { + select: RouteModuleEdgeSelect; + }; +}; export interface CreateSecureTableProvisionPayload { clientMutationId?: string | null; /** The `SecureTableProvision` that was created by this mutation. */ @@ -18037,6 +19679,51 @@ export type DeleteSessionsModulePayloadSelect = { select: SessionsModuleEdgeSelect; }; }; +export interface CreateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was created by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type CreateSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; +export interface UpdateSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was updated by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type UpdateSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; +export interface DeleteSiteSurfaceModulePayload { + clientMutationId?: string | null; + /** The `SiteSurfaceModule` that was deleted by this mutation. */ + siteSurfaceModule?: SiteSurfaceModule | null; + siteSurfaceModuleEdge?: SiteSurfaceModuleEdge | null; +} +export type DeleteSiteSurfaceModulePayloadSelect = { + clientMutationId?: boolean; + siteSurfaceModule?: { + select: SiteSurfaceModuleSelect; + }; + siteSurfaceModuleEdge?: { + select: SiteSurfaceModuleEdgeSelect; + }; +}; export interface CreateStorageLogModulePayload { clientMutationId?: string | null; /** The `StorageLogModule` that was created by this mutation. */ @@ -18564,6 +20251,30 @@ export type AgentModuleEdgeSelect = { select: AgentModuleSelect; }; }; +/** A `ApiSurfaceModule` edge in the connection. */ +export interface ApiSurfaceModuleEdge { + cursor?: string | null; + /** The `ApiSurfaceModule` at the end of the edge. */ + node?: ApiSurfaceModule | null; +} +export type ApiSurfaceModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: ApiSurfaceModuleSelect; + }; +}; +/** A `AppModule` edge in the connection. */ +export interface AppModuleEdge { + cursor?: string | null; + /** The `AppModule` at the end of the edge. */ + node?: AppModule | null; +} +export type AppModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: AppModuleSelect; + }; +}; /** A `BillingModule` edge in the connection. */ export interface BillingModuleEdge { cursor?: string | null; @@ -18624,6 +20335,18 @@ export type BlueprintTemplateEdgeSelect = { select: BlueprintTemplateSelect; }; }; +/** A `CatalogModule` edge in the connection. */ +export interface CatalogModuleEdge { + cursor?: string | null; + /** The `CatalogModule` at the end of the edge. */ + node?: CatalogModule | null; +} +export type CatalogModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: CatalogModuleSelect; + }; +}; /** A `ComputeLogModule` edge in the connection. */ export interface ComputeLogModuleEdge { cursor?: string | null; @@ -18780,6 +20503,18 @@ export type DevicesModuleEdgeSelect = { select: DevicesModuleSelect; }; }; +/** A `DomainModule` edge in the connection. */ +export interface DomainModuleEdge { + cursor?: string | null; + /** The `DomainModule` at the end of the edge. */ + node?: DomainModule | null; +} +export type DomainModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: DomainModuleSelect; + }; +}; /** A `EmailsModule` edge in the connection. */ export interface EmailsModuleEdge { cursor?: string | null; @@ -19200,6 +20935,18 @@ export type RlsModuleEdgeSelect = { select: RlsModuleSelect; }; }; +/** A `RouteModule` edge in the connection. */ +export interface RouteModuleEdge { + cursor?: string | null; + /** The `RouteModule` at the end of the edge. */ + node?: RouteModule | null; +} +export type RouteModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: RouteModuleSelect; + }; +}; /** A `SecureTableProvision` edge in the connection. */ export interface SecureTableProvisionEdge { cursor?: string | null; @@ -19236,6 +20983,18 @@ export type SessionsModuleEdgeSelect = { select: SessionsModuleSelect; }; }; +/** A `SiteSurfaceModule` edge in the connection. */ +export interface SiteSurfaceModuleEdge { + cursor?: string | null; + /** The `SiteSurfaceModule` at the end of the edge. */ + node?: SiteSurfaceModule | null; +} +export type SiteSurfaceModuleEdgeSelect = { + cursor?: boolean; + node?: { + select: SiteSurfaceModuleSelect; + }; +}; /** A `StorageLogModule` edge in the connection. */ export interface StorageLogModuleEdge { cursor?: string | null; diff --git a/sdk/constructive-sdk/src/modules/orm/models/apiSurfaceModule.ts b/sdk/constructive-sdk/src/modules/orm/models/apiSurfaceModule.ts new file mode 100644 index 000000000..12cb1d83e --- /dev/null +++ b/sdk/constructive-sdk/src/modules/orm/models/apiSurfaceModule.ts @@ -0,0 +1,245 @@ +/** + * ApiSurfaceModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + ApiSurfaceModule, + ApiSurfaceModuleWithRelations, + ApiSurfaceModuleSelect, + ApiSurfaceModuleFilter, + ApiSurfaceModuleOrderBy, + CreateApiSurfaceModuleInput, + UpdateApiSurfaceModuleInput, + ApiSurfaceModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class ApiSurfaceModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModule', + document, + variables, + transform: (data: { + apiSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + apiSurfaceModule: data.apiSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + apiSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'ApiSurfaceModule', + 'apiSurfaceModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'ApiSurfaceModuleFilter', + 'ApiSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'ApiSurfaceModule', + fieldName: 'apiSurfaceModule', + document, + variables, + transform: (data: { + apiSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + apiSurfaceModule: data.apiSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'ApiSurfaceModule', + 'createApiSurfaceModule', + 'apiSurfaceModule', + args.select, + args.data, + 'CreateApiSurfaceModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'createApiSurfaceModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + ApiSurfaceModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'ApiSurfaceModule', + 'updateApiSurfaceModule', + 'apiSurfaceModule', + args.select, + args.where.id, + args.data, + 'UpdateApiSurfaceModuleInput', + 'id', + 'apiSurfaceModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'updateApiSurfaceModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteApiSurfaceModule: { + apiSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'ApiSurfaceModule', + 'deleteApiSurfaceModule', + 'apiSurfaceModule', + { + id: args.where.id, + }, + 'DeleteApiSurfaceModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'ApiSurfaceModule', + fieldName: 'deleteApiSurfaceModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/modules/orm/models/appModule.ts b/sdk/constructive-sdk/src/modules/orm/models/appModule.ts new file mode 100644 index 000000000..78c5786d0 --- /dev/null +++ b/sdk/constructive-sdk/src/modules/orm/models/appModule.ts @@ -0,0 +1,245 @@ +/** + * AppModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + AppModule, + AppModuleWithRelations, + AppModuleSelect, + AppModuleFilter, + AppModuleOrderBy, + CreateAppModuleInput, + UpdateAppModuleInput, + AppModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class AppModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'AppModule', + 'appModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'AppModule', + 'appModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModule', + document, + variables, + transform: (data: { + appModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + appModule: data.appModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + appModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'AppModule', + 'appModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'AppModuleFilter', + 'AppModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'AppModule', + fieldName: 'appModule', + document, + variables, + transform: (data: { + appModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + appModule: data.appModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'AppModule', + 'createAppModule', + 'appModule', + args.select, + args.data, + 'CreateAppModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'createAppModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + AppModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'AppModule', + 'updateAppModule', + 'appModule', + args.select, + args.where.id, + args.data, + 'UpdateAppModuleInput', + 'id', + 'appModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'updateAppModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteAppModule: { + appModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'AppModule', + 'deleteAppModule', + 'appModule', + { + id: args.where.id, + }, + 'DeleteAppModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'AppModule', + fieldName: 'deleteAppModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/modules/orm/models/catalogModule.ts b/sdk/constructive-sdk/src/modules/orm/models/catalogModule.ts new file mode 100644 index 000000000..f03b06347 --- /dev/null +++ b/sdk/constructive-sdk/src/modules/orm/models/catalogModule.ts @@ -0,0 +1,245 @@ +/** + * CatalogModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + CatalogModule, + CatalogModuleWithRelations, + CatalogModuleSelect, + CatalogModuleFilter, + CatalogModuleOrderBy, + CreateCatalogModuleInput, + UpdateCatalogModuleInput, + CatalogModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class CatalogModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModule', + document, + variables, + transform: (data: { + catalogModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + catalogModule: data.catalogModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + catalogModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'CatalogModule', + 'catalogModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'CatalogModuleFilter', + 'CatalogModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'CatalogModule', + fieldName: 'catalogModule', + document, + variables, + transform: (data: { + catalogModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + catalogModule: data.catalogModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'CatalogModule', + 'createCatalogModule', + 'catalogModule', + args.select, + args.data, + 'CreateCatalogModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'createCatalogModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + CatalogModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'CatalogModule', + 'updateCatalogModule', + 'catalogModule', + args.select, + args.where.id, + args.data, + 'UpdateCatalogModuleInput', + 'id', + 'catalogModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'updateCatalogModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteCatalogModule: { + catalogModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'CatalogModule', + 'deleteCatalogModule', + 'catalogModule', + { + id: args.where.id, + }, + 'DeleteCatalogModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'CatalogModule', + fieldName: 'deleteCatalogModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/modules/orm/models/domainModule.ts b/sdk/constructive-sdk/src/modules/orm/models/domainModule.ts new file mode 100644 index 000000000..fd1f53622 --- /dev/null +++ b/sdk/constructive-sdk/src/modules/orm/models/domainModule.ts @@ -0,0 +1,245 @@ +/** + * DomainModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + DomainModule, + DomainModuleWithRelations, + DomainModuleSelect, + DomainModuleFilter, + DomainModuleOrderBy, + CreateDomainModuleInput, + UpdateDomainModuleInput, + DomainModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class DomainModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModule', + document, + variables, + transform: (data: { + domainModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainModule: data.domainModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + domainModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'DomainModule', + 'domainModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'DomainModuleFilter', + 'DomainModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'DomainModule', + fieldName: 'domainModule', + document, + variables, + transform: (data: { + domainModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + domainModule: data.domainModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'DomainModule', + 'createDomainModule', + 'domainModule', + args.select, + args.data, + 'CreateDomainModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'createDomainModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + DomainModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'DomainModule', + 'updateDomainModule', + 'domainModule', + args.select, + args.where.id, + args.data, + 'UpdateDomainModuleInput', + 'id', + 'domainModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'updateDomainModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteDomainModule: { + domainModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'DomainModule', + 'deleteDomainModule', + 'domainModule', + { + id: args.where.id, + }, + 'DeleteDomainModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'DomainModule', + fieldName: 'deleteDomainModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/modules/orm/models/index.ts b/sdk/constructive-sdk/src/modules/orm/models/index.ts index 4cabf5cd9..2143a553f 100644 --- a/sdk/constructive-sdk/src/modules/orm/models/index.ts +++ b/sdk/constructive-sdk/src/modules/orm/models/index.ts @@ -4,11 +4,14 @@ * DO NOT EDIT - changes will be overwritten */ export { AgentModuleModel } from './agentModule'; +export { ApiSurfaceModuleModel } from './apiSurfaceModule'; +export { AppModuleModel } from './appModule'; export { BillingModuleModel } from './billingModule'; export { BillingProviderModuleModel } from './billingProviderModule'; export { BlueprintModel } from './blueprint'; export { BlueprintConstructionModel } from './blueprintConstruction'; export { BlueprintTemplateModel } from './blueprintTemplate'; +export { CatalogModuleModel } from './catalogModule'; export { ComputeLogModuleModel } from './computeLogModule'; export { ConfigSecretsUserModuleModel } from './configSecretsUserModule'; export { ConnectedAccountsModuleModel } from './connectedAccountsModule'; @@ -22,6 +25,7 @@ export { DbUsageModuleModel } from './dbUsageModule'; export { DefaultIdsModuleModel } from './defaultIdsModule'; export { DenormalizedTableFieldModel } from './denormalizedTableField'; export { DevicesModuleModel } from './devicesModule'; +export { DomainModuleModel } from './domainModule'; export { EmailsModuleModel } from './emailsModule'; export { EntityTypeProvisionModel } from './entityTypeProvision'; export { EventsModuleModel } from './eventsModule'; @@ -57,9 +61,11 @@ export { RealtimeModuleModel } from './realtimeModule'; export { RelationProvisionModel } from './relationProvision'; export { ResourceModuleModel } from './resourceModule'; export { RlsModuleModel } from './rlsModule'; +export { RouteModuleModel } from './routeModule'; export { SecureTableProvisionModel } from './secureTableProvision'; export { SessionSecretsModuleModel } from './sessionSecretsModule'; export { SessionsModuleModel } from './sessionsModule'; +export { SiteSurfaceModuleModel } from './siteSurfaceModule'; export { StorageLogModuleModel } from './storageLogModule'; export { StorageModuleModel } from './storageModule'; export { TransferLogModuleModel } from './transferLogModule'; diff --git a/sdk/constructive-sdk/src/modules/orm/models/routeModule.ts b/sdk/constructive-sdk/src/modules/orm/models/routeModule.ts new file mode 100644 index 000000000..d57b13cea --- /dev/null +++ b/sdk/constructive-sdk/src/modules/orm/models/routeModule.ts @@ -0,0 +1,245 @@ +/** + * RouteModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + RouteModule, + RouteModuleWithRelations, + RouteModuleSelect, + RouteModuleFilter, + RouteModuleOrderBy, + CreateRouteModuleInput, + UpdateRouteModuleInput, + RouteModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class RouteModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModule', + document, + variables, + transform: (data: { + routeModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + routeModule: data.routeModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + routeModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'RouteModule', + 'routeModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'RouteModuleFilter', + 'RouteModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'RouteModule', + fieldName: 'routeModule', + document, + variables, + transform: (data: { + routeModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + routeModule: data.routeModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'RouteModule', + 'createRouteModule', + 'routeModule', + args.select, + args.data, + 'CreateRouteModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'createRouteModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + RouteModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'RouteModule', + 'updateRouteModule', + 'routeModule', + args.select, + args.where.id, + args.data, + 'UpdateRouteModuleInput', + 'id', + 'routeModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'updateRouteModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteRouteModule: { + routeModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'RouteModule', + 'deleteRouteModule', + 'routeModule', + { + id: args.where.id, + }, + 'DeleteRouteModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'RouteModule', + fieldName: 'deleteRouteModule', + document, + variables, + }); + } +} diff --git a/sdk/constructive-sdk/src/modules/orm/models/siteSurfaceModule.ts b/sdk/constructive-sdk/src/modules/orm/models/siteSurfaceModule.ts new file mode 100644 index 000000000..891f21403 --- /dev/null +++ b/sdk/constructive-sdk/src/modules/orm/models/siteSurfaceModule.ts @@ -0,0 +1,245 @@ +/** + * SiteSurfaceModule model for ORM client + * @generated by @constructive-io/graphql-codegen + * DO NOT EDIT - changes will be overwritten + */ +import { OrmClient } from '../client'; +import { + QueryBuilder, + buildFindManyDocument, + buildFindFirstDocument, + buildFindOneDocument, + buildCreateDocument, + buildUpdateByPkDocument, + buildDeleteByPkDocument, +} from '../query-builder'; +import type { + ConnectionResult, + FindManyArgs, + FindFirstArgs, + CreateArgs, + UpdateArgs, + DeleteArgs, + InferSelectResult, + StrictSelect, +} from '../select-types'; +import type { + SiteSurfaceModule, + SiteSurfaceModuleWithRelations, + SiteSurfaceModuleSelect, + SiteSurfaceModuleFilter, + SiteSurfaceModuleOrderBy, + CreateSiteSurfaceModuleInput, + UpdateSiteSurfaceModuleInput, + SiteSurfaceModulePatch, +} from '../input-types'; +import { connectionFieldsMap } from '../input-types'; +export class SiteSurfaceModuleModel { + constructor(private client: OrmClient) {} + findMany( + args: FindManyArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModules: ConnectionResult>; + }> { + const { document, variables } = buildFindManyDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + first: args?.first, + last: args?.last, + after: args?.after, + before: args?.before, + offset: args?.offset, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModules', + document, + variables, + }); + } + findFirst( + args: FindFirstArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindFirstDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: args?.where, + orderBy: args?.orderBy as string[] | undefined, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModule', + document, + variables, + transform: (data: { + siteSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + siteSurfaceModule: data.siteSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + findOne( + args: { + id: string; + select: S; + } & StrictSelect + ): QueryBuilder<{ + siteSurfaceModule: InferSelectResult | null; + }> { + const { document, variables } = buildFindManyDocument( + 'SiteSurfaceModule', + 'siteSurfaceModules', + args.select, + { + where: { + id: { + equalTo: args.id, + }, + }, + first: 1, + }, + 'SiteSurfaceModuleFilter', + 'SiteSurfaceModuleOrderBy', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'query', + operationName: 'SiteSurfaceModule', + fieldName: 'siteSurfaceModule', + document, + variables, + transform: (data: { + siteSurfaceModules?: { + nodes?: InferSelectResult[]; + }; + }) => ({ + siteSurfaceModule: data.siteSurfaceModules?.nodes?.[0] ?? null, + }), + }); + } + create( + args: CreateArgs & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + createSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildCreateDocument( + 'SiteSurfaceModule', + 'createSiteSurfaceModule', + 'siteSurfaceModule', + args.select, + args.data, + 'CreateSiteSurfaceModuleInput', + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'createSiteSurfaceModule', + document, + variables, + }); + } + update( + args: UpdateArgs< + S, + { + id: string; + }, + SiteSurfaceModulePatch + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + updateSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildUpdateByPkDocument( + 'SiteSurfaceModule', + 'updateSiteSurfaceModule', + 'siteSurfaceModule', + args.select, + args.where.id, + args.data, + 'UpdateSiteSurfaceModuleInput', + 'id', + 'siteSurfaceModulePatch', + connectionFieldsMap, + undefined + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'updateSiteSurfaceModule', + document, + variables, + }); + } + delete( + args: DeleteArgs< + { + id: string; + }, + S + > & { + select: S; + } & StrictSelect + ): QueryBuilder<{ + deleteSiteSurfaceModule: { + siteSurfaceModule: InferSelectResult; + }; + }> { + const { document, variables } = buildDeleteByPkDocument( + 'SiteSurfaceModule', + 'deleteSiteSurfaceModule', + 'siteSurfaceModule', + { + id: args.where.id, + }, + 'DeleteSiteSurfaceModuleInput', + args.select, + connectionFieldsMap + ); + return new QueryBuilder({ + client: this.client, + operation: 'mutation', + operationName: 'SiteSurfaceModule', + fieldName: 'deleteSiteSurfaceModule', + document, + variables, + }); + } +} diff --git a/sdk/migrate-client/schemas/migrate.graphql b/sdk/migrate-client/schemas/migrate.graphql index ad29a0a1a..b6764d4bd 100644 --- a/sdk/migrate-client/schemas/migrate.graphql +++ b/sdk/migrate-client/schemas/migrate.graphql @@ -432,11 +432,58 @@ type MetaRelations { manyToMany: [MetaManyToManyRelation!]! } +""" +How a client must serialize/parse a scalar — the one field-type detail standard GraphQL introspection cannot describe. Null for plain scalars whose wire format is obvious from gqlType. +""" +type MetaScalarEncoding { + """For 'vector': declared length, else null.""" + dimensions: Int + + """For 'ltree': values are dot-separated path strings.""" + dotPath: Boolean + + """For 'vector': element scalar (e.g. 'float').""" + elementType: String + + """For 'geojson': Point/LineString/Polygon/…, else null.""" + geometrySubtype: String + + """ + Machine kind: bigint, datetime, date, time, interval, uuid, geojson, point, inet, ltree, vector, bytea, or composite. + """ + kind: String! + + """For 'geojson': spatial reference id, else null.""" + srid: Int +} + """Root meta schema type""" type MetaSchema { tables: [MetaTable!]! } +"""Provisioning scope metadata for a table""" +type MetaScope { + """SQL name of the entity table for entity scopes, else null""" + entityTable: String + + """ + Inflected scope key column (e.g. databaseId, orgId), null for global tiers + """ + keyColumn: String + + """ + Provisioning scope: 'platform', 'app', 'database', or an entity scope (e.g. 'org') + """ + scope: String! + + """Provenance of the scope metadata (always 'smartTag')""" + source: String! + + """Coarse bucket: 'global', 'database', or 'entity'""" + tier: String! +} + """Search metadata for a table""" type MetaSearch { """Active search algorithms on this table""" @@ -504,6 +551,9 @@ type MetaTable { relations: MetaRelations! schemaName: String! + """Provisioning scope metadata (null if no @scope tag)""" + scope: MetaScope + """Search metadata (null if no search configured)""" search: MetaSearch @@ -514,6 +564,8 @@ type MetaTable { """Information about a PostgreSQL type""" type MetaType { + """Scalar serialization contract (null for plain scalars)""" + encoding: MetaScalarEncoding gqlType: String! hasDefault: Boolean isArray: Boolean!