@owox/backend 0.35.0 → 0.36.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/src/common/exceptions/concurrency-limit-exceeded.exception.d.ts +1 -1
- package/dist/src/common/exceptions/concurrency-limit-exceeded.exception.js +2 -2
- package/dist/src/common/markdown/markdown-parser.service.d.ts +2 -0
- package/dist/src/common/markdown/markdown-parser.service.js +15 -8
- package/dist/src/common/validators/max-byte-length.validator.d.ts +2 -0
- package/dist/src/common/validators/max-byte-length.validator.js +29 -0
- package/dist/src/config/env-validation.config.d.ts +12 -0
- package/dist/src/config/env-validation.config.js +7 -0
- package/dist/src/data-marts/ai-insights/agent/types.d.ts +6 -6
- package/dist/src/data-marts/calculated-fields/calculated-field-validator.service.js +22 -30
- package/dist/src/data-marts/calculated-fields/calculated-field.utils.d.ts +1 -0
- package/dist/src/data-marts/calculated-fields/calculated-field.utils.js +21 -0
- package/dist/src/data-marts/calculated-fields/formula-analyzer.d.ts +1 -0
- package/dist/src/data-marts/calculated-fields/formula-analyzer.js +2 -0
- package/dist/src/data-marts/calculated-fields/formula-violations.d.ts +7 -0
- package/dist/src/data-marts/calculated-fields/formula-violations.js +82 -1
- package/dist/src/data-marts/calculated-fields/join-grain.d.ts +32 -0
- package/dist/src/data-marts/calculated-fields/join-grain.js +107 -0
- package/dist/src/data-marts/calculated-fields/set-quantifier.d.ts +8 -0
- package/dist/src/data-marts/calculated-fields/set-quantifier.js +12 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/connector-message.schema.d.ts +66 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/connector-message.schema.js +13 -1
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-credentials-update.schema.d.ts +3 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-credentials-update.schema.js +1 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-error.schema.d.ts +3 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-error.schema.js +1 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-log.schema.d.ts +12 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-log.schema.js +4 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-requested-date.schema.d.ts +3 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-requested-date.schema.js +1 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-state-update.schema.d.ts +16 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-state-update.schema.js +16 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-status.schema.d.ts +3 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-status.schema.js +1 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-warning.schema.d.ts +3 -0
- package/dist/src/data-marts/connector-types/connector-message/schemas/types/message-warning.schema.js +1 -0
- package/dist/src/data-marts/connector-types/connector-message/services/connector-event.translator.d.ts +10 -0
- package/dist/src/data-marts/connector-types/connector-message/services/connector-event.translator.js +138 -0
- package/dist/src/data-marts/connector-types/connector-message/services/connector-message-parser.service.d.ts +1 -3
- package/dist/src/data-marts/connector-types/connector-message/services/connector-message-parser.service.js +30 -34
- package/dist/src/data-marts/connector-types/connector-message/services/connector-output-capture.service.js +10 -12
- package/dist/src/data-marts/connector-types/connector-message/services/connector-state.service.js +3 -1
- package/dist/src/data-marts/connector-types/enums/connector-message-type-enum.d.ts +1 -0
- package/dist/src/data-marts/connector-types/enums/connector-message-type-enum.js +1 -0
- package/dist/src/data-marts/controllers/connector-definition.controller.d.ts +30 -0
- package/dist/src/data-marts/controllers/connector-definition.controller.js +252 -0
- package/dist/src/data-marts/controllers/data-mart-preview.controller.d.ts +10 -0
- package/dist/src/data-marts/controllers/data-mart-preview.controller.js +58 -0
- package/dist/src/data-marts/controllers/data-mart.controller.d.ts +5 -1
- package/dist/src/data-marts/controllers/data-mart.controller.js +25 -4
- package/dist/src/data-marts/controllers/insight-template.controller.js +4 -4
- package/dist/src/data-marts/controllers/insight.controller.js +5 -5
- package/dist/src/data-marts/controllers/project-data-mart-runs.controller.js +1 -1
- package/dist/src/data-marts/controllers/spec/connector-definition.api.d.ts +12 -0
- package/dist/src/data-marts/controllers/spec/connector-definition.api.js +179 -0
- package/dist/src/data-marts/controllers/spec/data-mart.api.d.ts +1 -0
- package/dist/src/data-marts/controllers/spec/data-mart.api.js +5 -0
- package/dist/src/data-marts/controllers/spec/report-openapi.d.ts +18 -0
- package/dist/src/data-marts/controllers/spec/report-openapi.js +3 -0
- package/dist/src/data-marts/data-marts.module.js +20 -2
- package/dist/src/data-marts/data-storage-types/blending/metric-sleeve.planner.js +3 -12
- package/dist/src/data-marts/data-storage-types/data-mart-schema.utils.d.ts +1 -0
- package/dist/src/data-marts/data-storage-types/data-mart-schema.utils.js +16 -0
- package/dist/src/data-marts/dto/domain/blendable-schema.dto.d.ts +10 -0
- package/dist/src/data-marts/dto/domain/blendable-schema.dto.js +71 -1
- package/dist/src/data-marts/dto/domain/create-data-mart.command.d.ts +3 -1
- package/dist/src/data-marts/dto/domain/create-data-mart.command.js +3 -1
- package/dist/src/data-marts/dto/domain/create-report.command.d.ts +3 -1
- package/dist/src/data-marts/dto/domain/create-report.command.js +3 -1
- package/dist/src/data-marts/dto/domain/data-mart-list-item.dto.d.ts +3 -1
- package/dist/src/data-marts/dto/domain/data-mart-list-item.dto.js +3 -1
- package/dist/src/data-marts/dto/domain/data-mart.dto.d.ts +4 -1
- package/dist/src/data-marts/dto/domain/data-mart.dto.js +5 -1
- package/dist/src/data-marts/dto/domain/model-canvas.dto.d.ts +4 -0
- package/dist/src/data-marts/dto/domain/report-like-read-plan.d.ts +2 -0
- package/dist/src/data-marts/dto/domain/report.dto.d.ts +3 -1
- package/dist/src/data-marts/dto/domain/report.dto.js +3 -1
- package/dist/src/data-marts/dto/domain/update-data-mart-icon.command.d.ts +9 -0
- package/dist/src/data-marts/dto/domain/update-data-mart-icon.command.js +19 -0
- package/dist/src/data-marts/dto/domain/update-report.command.d.ts +3 -1
- package/dist/src/data-marts/dto/domain/update-report.command.js +3 -1
- package/dist/src/data-marts/dto/presentation/create-data-mart-request-api.dto.d.ts +2 -0
- package/dist/src/data-marts/dto/presentation/create-data-mart-request-api.dto.js +13 -0
- package/dist/src/data-marts/dto/presentation/create-report-request-api.dto.d.ts +2 -0
- package/dist/src/data-marts/dto/presentation/create-report-request-api.dto.js +10 -0
- package/dist/src/data-marts/dto/presentation/custom-connector-response.dto.d.ts +46 -0
- package/dist/src/data-marts/dto/presentation/custom-connector-response.dto.js +216 -0
- package/dist/src/data-marts/dto/presentation/custom-connector.dto.d.ts +27 -0
- package/dist/src/data-marts/dto/presentation/custom-connector.dto.js +159 -0
- package/dist/src/data-marts/dto/presentation/data-mart-list-item-response-api.dto.d.ts +2 -0
- package/dist/src/data-marts/dto/presentation/data-mart-list-item-response-api.dto.js +10 -0
- package/dist/src/data-marts/dto/presentation/data-mart-response-api.dto.d.ts +2 -0
- package/dist/src/data-marts/dto/presentation/data-mart-response-api.dto.js +10 -0
- package/dist/src/data-marts/dto/presentation/model-canvas-response-api.dto.d.ts +4 -0
- package/dist/src/data-marts/dto/presentation/model-canvas-response-api.dto.js +20 -0
- package/dist/src/data-marts/dto/presentation/preview-data-mart-request-api.dto.d.ts +7 -0
- package/dist/src/data-marts/dto/presentation/preview-data-mart-request-api.dto.js +56 -0
- package/dist/src/data-marts/dto/presentation/preview-data-mart-response-api.dto.d.ts +12 -0
- package/dist/src/data-marts/dto/presentation/preview-data-mart-response-api.dto.js +64 -0
- package/dist/src/data-marts/dto/presentation/report-response-api.dto.d.ts +2 -0
- package/dist/src/data-marts/dto/presentation/report-response-api.dto.js +6 -0
- package/dist/src/data-marts/dto/presentation/run-data-mart-request-api.dto.js +67 -0
- package/dist/src/data-marts/dto/presentation/update-data-mart-description-api.dto.js +3 -0
- package/dist/src/data-marts/dto/presentation/update-data-mart-icon-api.dto.d.ts +4 -0
- package/dist/src/data-marts/dto/presentation/update-data-mart-icon-api.dto.js +30 -0
- package/dist/src/data-marts/dto/presentation/update-report-request-api.dto.d.ts +2 -0
- package/dist/src/data-marts/dto/presentation/update-report-request-api.dto.js +10 -0
- package/dist/src/data-marts/dto/schemas/auto-aggregation-opt-out.schema.d.ts +15 -0
- package/dist/src/data-marts/dto/schemas/auto-aggregation-opt-out.schema.js +29 -0
- package/dist/src/data-marts/dto/schemas/data-mart-run/data-mart-run.schema.d.ts +9 -0
- package/dist/src/data-marts/dto/schemas/data-mart-table-definitions/connector-definition.schema.d.ts +15 -0
- package/dist/src/data-marts/dto/schemas/data-mart-table-definitions/connector-definition.schema.js +1 -0
- package/dist/src/data-marts/dto/schemas/data-mart-table-definitions/data-mart-definition.schema.d.ts +7 -0
- package/dist/src/data-marts/dto/schemas/data-quality/data-quality-run.schema.d.ts +20 -0
- package/dist/src/data-marts/entities/connector-definition-version.entity.d.ts +16 -0
- package/dist/src/data-marts/entities/connector-definition-version.entity.js +78 -0
- package/dist/src/data-marts/entities/connector-definition.entity.d.ts +14 -0
- package/dist/src/data-marts/entities/connector-definition.entity.js +82 -0
- package/dist/src/data-marts/entities/data-mart.entity.d.ts +2 -0
- package/dist/src/data-marts/entities/data-mart.entity.js +5 -0
- package/dist/src/data-marts/entities/report.entity.d.ts +2 -0
- package/dist/src/data-marts/entities/report.entity.js +11 -0
- package/dist/src/data-marts/enums/data-mart-icon.enum.d.ts +75 -0
- package/dist/src/data-marts/enums/data-mart-icon.enum.js +80 -0
- package/dist/src/data-marts/errors/connector-credential-boundary.error.d.ts +3 -0
- package/dist/src/data-marts/errors/connector-credential-boundary.error.js +14 -0
- package/dist/src/data-marts/facades/mcp-data-marts.facade.d.ts +2 -0
- package/dist/src/data-marts/facades/mcp-data-marts.facade.impl.d.ts +7 -1
- package/dist/src/data-marts/facades/mcp-data-marts.facade.impl.js +70 -5
- package/dist/src/data-marts/mappers/connector-definition.mapper.d.ts +14 -0
- package/dist/src/data-marts/mappers/connector-definition.mapper.js +57 -0
- package/dist/src/data-marts/mappers/data-mart.mapper.d.ts +9 -6
- package/dist/src/data-marts/mappers/data-mart.mapper.js +44 -19
- package/dist/src/data-marts/mappers/insight-template.mapper.d.ts +1 -1
- package/dist/src/data-marts/mappers/insight-template.mapper.js +2 -2
- package/dist/src/data-marts/mappers/insight.mapper.d.ts +1 -1
- package/dist/src/data-marts/mappers/insight.mapper.js +2 -2
- package/dist/src/data-marts/mappers/model-canvas.mapper.d.ts +10 -2
- package/dist/src/data-marts/mappers/model-canvas.mapper.js +9 -3
- package/dist/src/data-marts/mappers/report.mapper.js +4 -3
- package/dist/src/data-marts/services/auto-collapse.resolver.d.ts +1 -1
- package/dist/src/data-marts/services/auto-collapse.resolver.js +4 -0
- package/dist/src/data-marts/services/blendable-schema.service.d.ts +2 -0
- package/dist/src/data-marts/services/blendable-schema.service.js +59 -0
- package/dist/src/data-marts/services/connector/connector-credential-injector.service.d.ts +1 -1
- package/dist/src/data-marts/services/connector/connector-credential-injector.service.js +15 -1
- package/dist/src/data-marts/services/connector/connector-definition.service.d.ts +59 -0
- package/dist/src/data-marts/services/connector/connector-definition.service.js +491 -0
- package/dist/src/data-marts/services/connector/connector-executor.service.d.ts +9 -1
- package/dist/src/data-marts/services/connector/connector-executor.service.js +173 -63
- package/dist/src/data-marts/services/connector/connector-fields-preview.service.js +1 -1
- package/dist/src/data-marts/services/connector/connector-message.utils.js +2 -2
- package/dist/src/data-marts/services/connector/connector-preview-credentials.service.js +1 -1
- package/dist/src/data-marts/services/connector/connector-preview-support.d.ts +1 -1
- package/dist/src/data-marts/services/connector/connector-preview-support.js +14 -21
- package/dist/src/data-marts/services/connector/connector-process-spawner.service.d.ts +11 -2
- package/dist/src/data-marts/services/connector/connector-process-spawner.service.js +88 -60
- package/dist/src/data-marts/services/connector/connector-secret.service.d.ts +6 -3
- package/dist/src/data-marts/services/connector/connector-secret.service.js +77 -12
- package/dist/src/data-marts/services/connector/connector-source-config.service.js +1 -1
- package/dist/src/data-marts/services/connector/connector-source-credentials.service.d.ts +6 -2
- package/dist/src/data-marts/services/connector/connector-source-credentials.service.js +18 -16
- package/dist/src/data-marts/services/connector/connector-specification.mapper.d.ts +47 -0
- package/dist/src/data-marts/services/connector/connector-specification.mapper.js +46 -0
- package/dist/src/data-marts/services/connector/connector-test.service.d.ts +43 -0
- package/dist/src/data-marts/services/connector/connector-test.service.js +343 -0
- package/dist/src/data-marts/services/connector/connector.service.d.ts +8 -2
- package/dist/src/data-marts/services/connector/connector.service.js +65 -54
- package/dist/src/data-marts/services/connector/declarative-manifest-schemas.d.ts +4 -0
- package/dist/src/data-marts/services/connector/declarative-manifest-schemas.js +48 -0
- package/dist/src/data-marts/services/connector/run-log-flusher.d.ts +21 -0
- package/dist/src/data-marts/services/connector/run-log-flusher.js +67 -0
- package/dist/src/data-marts/services/data-mart.service.js +2 -0
- package/dist/src/data-marts/services/report-sql-composer.service.js +15 -1
- package/dist/src/data-marts/services/report.service.d.ts +1 -0
- package/dist/src/data-marts/services/report.service.js +13 -0
- package/dist/src/data-marts/services/scheduled-trigger.service.d.ts +1 -0
- package/dist/src/data-marts/services/scheduled-trigger.service.js +13 -0
- package/dist/src/data-marts/use-cases/create-data-mart.service.js +1 -0
- package/dist/src/data-marts/use-cases/create-report.service.js +2 -0
- package/dist/src/data-marts/use-cases/get-model-canvas-data-marts.service.d.ts +5 -1
- package/dist/src/data-marts/use-cases/get-model-canvas-data-marts.service.js +16 -3
- package/dist/src/data-marts/use-cases/list-project-scheduled-triggers.service.js +1 -1
- package/dist/src/data-marts/use-cases/preview-data-mart.service.d.ts +59 -0
- package/dist/src/data-marts/use-cases/preview-data-mart.service.js +293 -0
- package/dist/src/data-marts/use-cases/stream-http-data.service.js +1 -0
- package/dist/src/data-marts/use-cases/update-data-mart-definition.service.d.ts +1 -1
- package/dist/src/data-marts/use-cases/update-data-mart-definition.service.js +8 -6
- package/dist/src/data-marts/use-cases/update-data-mart-icon.service.d.ts +12 -0
- package/dist/src/data-marts/use-cases/update-data-mart-icon.service.js +46 -0
- package/dist/src/data-marts/use-cases/update-data-mart-schema.service.js +14 -1
- package/dist/src/data-marts/use-cases/update-report.service.js +9 -1
- package/dist/src/ee/ee.module.js +5 -8
- package/dist/src/ee/mcp/auth/mcp-auth-context.d.ts +0 -4
- package/dist/src/ee/mcp/auth/mcp-auth.middleware.d.ts +26 -0
- package/dist/src/ee/mcp/auth/mcp-auth.middleware.js +184 -0
- package/dist/src/ee/mcp/http-headers.util.d.ts +2 -0
- package/dist/src/ee/mcp/http-headers.util.js +8 -0
- package/dist/src/ee/mcp/observability/mcp-bus-wiring.js +4 -4
- package/dist/src/ee/mcp/observability/mcp-call-instrumentation.d.ts +2 -4
- package/dist/src/ee/mcp/observability/mcp-call-instrumentation.js +6 -6
- package/dist/src/ee/mcp/sdk/mcp-sdk-server.factory.d.ts +1 -1
- package/dist/src/ee/mcp/sdk/mcp-sdk-server.factory.js +5 -5
- package/dist/src/ee/mcp/tools/add-destination.tool.d.ts +20 -14
- package/dist/src/ee/mcp/tools/add-destination.tool.js +10 -10
- package/dist/src/ee/mcp/tools/add-report.tool.d.ts +88 -228
- package/dist/src/ee/mcp/tools/add-report.tool.js +28 -28
- package/dist/src/ee/mcp/tools/create-report-run-schedule.tool.d.ts +2 -12
- package/dist/src/ee/mcp/tools/create-report-run-schedule.tool.js +13 -13
- package/dist/src/ee/mcp/tools/data-mart-catalog.tool.d.ts +15 -81
- package/dist/src/ee/mcp/tools/data-mart-catalog.tool.js +11 -11
- package/dist/src/ee/mcp/tools/data-mart-details.tool.d.ts +19 -111
- package/dist/src/ee/mcp/tools/data-mart-details.tool.js +64 -48
- package/dist/src/ee/mcp/tools/delete-report-run-schedule.tool.d.ts +2 -6
- package/dist/src/ee/mcp/tools/delete-report-run-schedule.tool.js +7 -7
- package/dist/src/ee/mcp/tools/delete-report.tool.d.ts +2 -6
- package/dist/src/ee/mcp/tools/delete-report.tool.js +4 -4
- package/dist/src/ee/mcp/tools/get-data-mart-reports.tool.d.ts +30 -195
- package/dist/src/ee/mcp/tools/get-data-mart-reports.tool.js +22 -22
- package/dist/src/ee/mcp/tools/get-report-output-schema.tool.d.ts +3 -21
- package/dist/src/ee/mcp/tools/get-report-output-schema.tool.js +10 -10
- package/dist/src/ee/mcp/tools/get-report-run-status.tool.d.ts +15 -11
- package/dist/src/ee/mcp/tools/get-report-run-status.tool.js +14 -14
- package/dist/src/ee/mcp/tools/list-destinations.tool.d.ts +12 -20
- package/dist/src/ee/mcp/tools/list-destinations.tool.js +10 -10
- package/dist/src/ee/mcp/tools/list-report-run-schedules.tool.d.ts +5 -61
- package/dist/src/ee/mcp/tools/list-report-run-schedules.tool.js +14 -14
- package/dist/src/ee/mcp/tools/mcp-getting-started.util.d.ts +4 -52
- package/dist/src/ee/mcp/tools/mcp-getting-started.util.js +13 -13
- package/dist/src/ee/mcp/tools/mcp-tool.definition.d.ts +2 -2
- package/dist/src/ee/mcp/tools/project-context.tool.d.ts +3 -17
- package/dist/src/ee/mcp/tools/project-context.tool.js +10 -10
- package/dist/src/ee/mcp/tools/query-data-mart.input.d.ts +111 -152
- package/dist/src/ee/mcp/tools/query-data-mart.input.js +39 -39
- package/dist/src/ee/mcp/tools/query-data-mart.tool.d.ts +60 -130
- package/dist/src/ee/mcp/tools/query-data-mart.tool.js +35 -35
- package/dist/src/ee/mcp/tools/report-output-controls-output.d.ts +17 -60
- package/dist/src/ee/mcp/tools/report-output-controls-output.js +20 -20
- package/dist/src/ee/mcp/tools/report-run-outcome.d.ts +6 -42
- package/dist/src/ee/mcp/tools/report-run-outcome.js +20 -20
- package/dist/src/ee/mcp/tools/run-report.tool.d.ts +2 -6
- package/dist/src/ee/mcp/tools/run-report.tool.js +5 -5
- package/dist/src/ee/mcp/tools/search-data-marts.tool.d.ts +7 -79
- package/dist/src/ee/mcp/tools/search-data-marts.tool.js +11 -11
- package/dist/src/ee/mcp/tools/search-reports.tool.d.ts +15 -61
- package/dist/src/ee/mcp/tools/search-reports.tool.js +15 -15
- package/dist/src/ee/mcp/tools/summarize-data-catalog.tool.d.ts +7 -79
- package/dist/src/ee/mcp/tools/summarize-data-catalog.tool.js +15 -15
- package/dist/src/ee/mcp/tools/update-report-run-schedule.tool.d.ts +2 -12
- package/dist/src/ee/mcp/tools/update-report-run-schedule.tool.js +13 -13
- package/dist/src/ee/mcp/tools/update-report.tool.d.ts +105 -414
- package/dist/src/ee/mcp/tools/update-report.tool.js +20 -20
- package/dist/src/ee/mcp/transport/mcp-http-entry.service.d.ts +30 -0
- package/dist/src/ee/mcp/transport/mcp-http-entry.service.js +193 -0
- package/dist/src/idp/guards/idp.guard.js +2 -8
- package/dist/src/idp/oauth/controllers/oauth-authorization.controller.d.ts +4 -0
- package/dist/src/idp/oauth/controllers/oauth-authorization.controller.js +77 -1
- package/dist/src/idp/oauth/controllers/oauth-metadata.controller.d.ts +2 -1
- package/dist/src/idp/oauth/controllers/oauth-metadata.controller.js +5 -8
- package/dist/src/idp/oauth/controllers/oauth-token.controller.js +14 -1
- package/dist/src/idp/oauth/oauth-request.validator.d.ts +8 -0
- package/dist/src/idp/oauth/oauth-request.validator.js +27 -0
- package/dist/src/idp/utils/is-authentication-error.d.ts +1 -0
- package/dist/src/idp/utils/is-authentication-error.js +9 -0
- package/dist/src/idp/utils/role-hierarchy.d.ts +3 -0
- package/dist/src/idp/utils/role-hierarchy.js +14 -0
- package/dist/src/index.d.ts +1 -0
- package/dist/src/index.js +3 -1
- package/dist/src/migrations/1788048000000-create-connector-definition-tables.d.ts +6 -0
- package/dist/src/migrations/1788048000000-create-connector-definition-tables.js +116 -0
- package/dist/src/migrations/1790156789783-add-auto-aggregation-opt-out-to-report.d.ts +8 -0
- package/dist/src/migrations/1790156789783-add-auto-aggregation-opt-out-to-report.js +30 -0
- package/dist/src/migrations/1790247861000-add-icon-to-data-mart.d.ts +8 -0
- package/dist/src/migrations/1790247861000-add-icon-to-data-mart.js +31 -0
- package/package.json +10 -6
- package/dist/src/ee/mcp/auth/mcp-auth.exception-filter.d.ts +0 -14
- package/dist/src/ee/mcp/auth/mcp-auth.exception-filter.js +0 -84
- package/dist/src/ee/mcp/auth/mcp-auth.guard.d.ts +0 -14
- package/dist/src/ee/mcp/auth/mcp-auth.guard.js +0 -99
- package/dist/src/ee/mcp/controllers/mcp-transport.controller.d.ts +0 -17
- package/dist/src/ee/mcp/controllers/mcp-transport.controller.js +0 -134
- package/dist/src/ee/mcp/sdk/mcp-streamable-http-transport.handler.d.ts +0 -16
- package/dist/src/ee/mcp/sdk/mcp-streamable-http-transport.handler.js +0 -133
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
1
|
+
import { z } from 'zod-v4';
|
|
2
2
|
import type { McpScope } from '@owox/idp-protocol';
|
|
3
3
|
import { type McpDataMartsFacade } from '../../../data-marts/facades/mcp-data-marts.facade';
|
|
4
4
|
import { ClsContextService } from '../../../common/logger/cls-context.service';
|
|
@@ -14,174 +14,104 @@ export declare class QueryDataMartTool implements McpToolDefinition<QueryDataMar
|
|
|
14
14
|
readonly description: string;
|
|
15
15
|
readonly zodSchema: {
|
|
16
16
|
data_mart_id: z.ZodString;
|
|
17
|
-
fields: z.ZodArray<z.ZodString
|
|
17
|
+
fields: z.ZodArray<z.ZodString>;
|
|
18
18
|
slices: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
19
19
|
field: z.ZodString;
|
|
20
|
-
operator: z.
|
|
21
|
-
value: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnknown
|
|
22
|
-
},
|
|
23
|
-
operator: "between" | "in" | "this_week" | "last_week" | "this_month" | "this_quarter" | "last_quarter" | "this_year" | "eq" | "neq" | "contains" | "not_contains" | "starts_with" | "ends_with" | "gt" | "lt" | "gte" | "lte" | "is_blank" | "is_not_blank" | "is_empty" | "is_not_empty" | "is_null" | "is_not_null" | "not_in" | "in_last_n_days" | "in_next_n_days" | "before" | "after";
|
|
24
|
-
field: string;
|
|
25
|
-
value?: string | number | boolean | unknown[] | Record<string, unknown> | null | undefined;
|
|
26
|
-
}, {
|
|
27
|
-
field: string;
|
|
28
|
-
value?: string | number | boolean | unknown[] | Record<string, unknown> | null | undefined;
|
|
29
|
-
operator?: unknown;
|
|
30
|
-
}>, "many">>;
|
|
20
|
+
operator: z.ZodType<"between" | "in" | "this_week" | "last_week" | "this_month" | "this_quarter" | "last_quarter" | "this_year" | "eq" | "neq" | "contains" | "not_contains" | "starts_with" | "ends_with" | "gt" | "lt" | "gte" | "lte" | "is_blank" | "is_not_blank" | "is_empty" | "is_not_empty" | "is_null" | "is_not_null" | "not_in" | "in_last_n_days" | "in_next_n_days" | "before" | "after", unknown, z.core.$ZodTypeInternals<"between" | "in" | "this_week" | "last_week" | "this_month" | "this_quarter" | "last_quarter" | "this_year" | "eq" | "neq" | "contains" | "not_contains" | "starts_with" | "ends_with" | "gt" | "lt" | "gte" | "lte" | "is_blank" | "is_not_blank" | "is_empty" | "is_not_empty" | "is_null" | "is_not_null" | "not_in" | "in_last_n_days" | "in_next_n_days" | "before" | "after", unknown>>;
|
|
21
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnknown>, z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodNull]>>;
|
|
22
|
+
}, z.core.$strip>>>;
|
|
31
23
|
filters: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
32
24
|
field: z.ZodString;
|
|
33
|
-
operator: z.
|
|
34
|
-
value: z.ZodOptional<z.ZodUnion<[z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnknown
|
|
35
|
-
},
|
|
36
|
-
operator: "between" | "in" | "this_week" | "last_week" | "this_month" | "this_quarter" | "last_quarter" | "this_year" | "eq" | "neq" | "contains" | "not_contains" | "starts_with" | "ends_with" | "gt" | "lt" | "gte" | "lte" | "is_blank" | "is_not_blank" | "is_empty" | "is_not_empty" | "is_null" | "is_not_null" | "not_in" | "in_last_n_days" | "in_next_n_days" | "before" | "after";
|
|
37
|
-
field: string;
|
|
38
|
-
value?: string | number | boolean | unknown[] | Record<string, unknown> | null | undefined;
|
|
39
|
-
}, {
|
|
40
|
-
field: string;
|
|
41
|
-
value?: string | number | boolean | unknown[] | Record<string, unknown> | null | undefined;
|
|
42
|
-
operator?: unknown;
|
|
43
|
-
}>, "many">>;
|
|
25
|
+
operator: z.ZodType<"between" | "in" | "this_week" | "last_week" | "this_month" | "this_quarter" | "last_quarter" | "this_year" | "eq" | "neq" | "contains" | "not_contains" | "starts_with" | "ends_with" | "gt" | "lt" | "gte" | "lte" | "is_blank" | "is_not_blank" | "is_empty" | "is_not_empty" | "is_null" | "is_not_null" | "not_in" | "in_last_n_days" | "in_next_n_days" | "before" | "after", unknown, z.core.$ZodTypeInternals<"between" | "in" | "this_week" | "last_week" | "this_month" | "this_quarter" | "last_quarter" | "this_year" | "eq" | "neq" | "contains" | "not_contains" | "starts_with" | "ends_with" | "gt" | "lt" | "gte" | "lte" | "is_blank" | "is_not_blank" | "is_empty" | "is_not_empty" | "is_null" | "is_not_null" | "not_in" | "in_last_n_days" | "in_next_n_days" | "before" | "after", unknown>>;
|
|
26
|
+
value: z.ZodOptional<z.ZodUnion<readonly [z.ZodString, z.ZodNumber, z.ZodBoolean, z.ZodArray<z.ZodUnknown>, z.ZodRecord<z.ZodString, z.ZodUnknown>, z.ZodNull]>>;
|
|
27
|
+
}, z.core.$strip>>>;
|
|
44
28
|
aggregations: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
45
29
|
field: z.ZodString;
|
|
46
|
-
function: z.ZodEnum<
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
|
|
51
|
-
|
|
52
|
-
|
|
53
|
-
|
|
30
|
+
function: z.ZodEnum<{
|
|
31
|
+
MAX: "MAX";
|
|
32
|
+
MIN: "MIN";
|
|
33
|
+
SUM: "SUM";
|
|
34
|
+
AVG: "AVG";
|
|
35
|
+
COUNT: "COUNT";
|
|
36
|
+
COUNT_DISTINCT: "COUNT_DISTINCT";
|
|
37
|
+
P25: "P25";
|
|
38
|
+
P50: "P50";
|
|
39
|
+
P75: "P75";
|
|
40
|
+
P95: "P95";
|
|
41
|
+
}>;
|
|
42
|
+
}, z.core.$strip>>>;
|
|
54
43
|
date_buckets: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
55
44
|
field: z.ZodString;
|
|
56
|
-
unit: z.ZodEnum<
|
|
45
|
+
unit: z.ZodEnum<{
|
|
46
|
+
DAY: "DAY";
|
|
47
|
+
WEEK: "WEEK";
|
|
48
|
+
MONTH: "MONTH";
|
|
49
|
+
QUARTER: "QUARTER";
|
|
50
|
+
YEAR: "YEAR";
|
|
51
|
+
}>;
|
|
57
52
|
time_zone: z.ZodOptional<z.ZodString>;
|
|
58
|
-
},
|
|
59
|
-
unit: "DAY" | "WEEK" | "MONTH" | "QUARTER" | "YEAR";
|
|
60
|
-
field: string;
|
|
61
|
-
time_zone?: string | undefined;
|
|
62
|
-
}, {
|
|
63
|
-
unit: "DAY" | "WEEK" | "MONTH" | "QUARTER" | "YEAR";
|
|
64
|
-
field: string;
|
|
65
|
-
time_zone?: string | undefined;
|
|
66
|
-
}>, "many">>;
|
|
53
|
+
}, z.core.$strip>>>;
|
|
67
54
|
sort: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
68
55
|
field: z.ZodString;
|
|
69
|
-
direction: z.ZodEnum<
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
},
|
|
74
|
-
direction: "asc" | "desc";
|
|
75
|
-
field: string;
|
|
76
|
-
}>, "many">>;
|
|
56
|
+
direction: z.ZodEnum<{
|
|
57
|
+
asc: "asc";
|
|
58
|
+
desc: "desc";
|
|
59
|
+
}>;
|
|
60
|
+
}, z.core.$strip>>>;
|
|
77
61
|
limit: z.ZodOptional<z.ZodNumber>;
|
|
78
62
|
};
|
|
79
63
|
readonly outputSchema: {
|
|
80
|
-
columns: z.ZodArray<z.ZodString
|
|
64
|
+
columns: z.ZodArray<z.ZodString>;
|
|
81
65
|
column_metadata: z.ZodArray<z.ZodObject<{
|
|
82
66
|
name: z.ZodString;
|
|
83
67
|
display_name: z.ZodString;
|
|
84
68
|
description: z.ZodOptional<z.ZodString>;
|
|
85
69
|
type: z.ZodOptional<z.ZodString>;
|
|
86
|
-
},
|
|
87
|
-
name: string;
|
|
88
|
-
display_name: string;
|
|
89
|
-
type?: string | undefined;
|
|
90
|
-
description?: string | undefined;
|
|
91
|
-
}, {
|
|
92
|
-
name: string;
|
|
93
|
-
display_name: string;
|
|
94
|
-
type?: string | undefined;
|
|
95
|
-
description?: string | undefined;
|
|
96
|
-
}>, "many">;
|
|
70
|
+
}, z.core.$strip>>;
|
|
97
71
|
rows: z.ZodString;
|
|
98
72
|
returned_rows: z.ZodNumber;
|
|
99
73
|
truncated: z.ZodBoolean;
|
|
100
74
|
truncation: z.ZodOptional<z.ZodObject<{
|
|
101
|
-
reasons: z.ZodArray<z.ZodEnum<
|
|
102
|
-
|
|
103
|
-
|
|
104
|
-
|
|
105
|
-
|
|
106
|
-
}>>;
|
|
75
|
+
reasons: z.ZodArray<z.ZodEnum<{
|
|
76
|
+
row_limit: "row_limit";
|
|
77
|
+
payload_byte_cap: "payload_byte_cap";
|
|
78
|
+
}>>;
|
|
79
|
+
}, z.core.$strip>>;
|
|
107
80
|
totals: z.ZodNullable<z.ZodRecord<z.ZodString, z.ZodUnknown>>;
|
|
108
81
|
data_last_updated: z.ZodObject<{
|
|
109
82
|
data_last_updated_at: z.ZodNullable<z.ZodString>;
|
|
110
83
|
computed_at: z.ZodString;
|
|
111
|
-
coverage: z.ZodEnum<
|
|
84
|
+
coverage: z.ZodEnum<{
|
|
85
|
+
partial: "partial";
|
|
86
|
+
complete: "complete";
|
|
87
|
+
unavailable: "unavailable";
|
|
88
|
+
}>;
|
|
112
89
|
sources: z.ZodArray<z.ZodObject<{
|
|
113
90
|
table: z.ZodString;
|
|
114
91
|
data_last_updated_at: z.ZodNullable<z.ZodString>;
|
|
115
92
|
note: z.ZodOptional<z.ZodString>;
|
|
116
|
-
},
|
|
117
|
-
|
|
118
|
-
data_last_updated_at: string | null;
|
|
119
|
-
note?: string | undefined;
|
|
120
|
-
}, {
|
|
121
|
-
table: string;
|
|
122
|
-
data_last_updated_at: string | null;
|
|
123
|
-
note?: string | undefined;
|
|
124
|
-
}>, "many">;
|
|
125
|
-
}, "strip", z.ZodTypeAny, {
|
|
126
|
-
sources: {
|
|
127
|
-
table: string;
|
|
128
|
-
data_last_updated_at: string | null;
|
|
129
|
-
note?: string | undefined;
|
|
130
|
-
}[];
|
|
131
|
-
coverage: "partial" | "complete" | "unavailable";
|
|
132
|
-
data_last_updated_at: string | null;
|
|
133
|
-
computed_at: string;
|
|
134
|
-
}, {
|
|
135
|
-
sources: {
|
|
136
|
-
table: string;
|
|
137
|
-
data_last_updated_at: string | null;
|
|
138
|
-
note?: string | undefined;
|
|
139
|
-
}[];
|
|
140
|
-
coverage: "partial" | "complete" | "unavailable";
|
|
141
|
-
data_last_updated_at: string | null;
|
|
142
|
-
computed_at: string;
|
|
143
|
-
}>;
|
|
93
|
+
}, z.core.$strip>>;
|
|
94
|
+
}, z.core.$strip>;
|
|
144
95
|
totals_error: z.ZodOptional<z.ZodString>;
|
|
145
96
|
source: z.ZodObject<{
|
|
146
97
|
data_mart: z.ZodObject<{
|
|
147
98
|
id: z.ZodString;
|
|
148
99
|
title: z.ZodString;
|
|
149
100
|
url: z.ZodString;
|
|
150
|
-
},
|
|
151
|
-
|
|
152
|
-
title: string;
|
|
153
|
-
url: string;
|
|
154
|
-
}, {
|
|
155
|
-
id: string;
|
|
156
|
-
title: string;
|
|
157
|
-
url: string;
|
|
158
|
-
}>;
|
|
159
|
-
}, "strip", z.ZodTypeAny, {
|
|
160
|
-
data_mart: {
|
|
161
|
-
id: string;
|
|
162
|
-
title: string;
|
|
163
|
-
url: string;
|
|
164
|
-
};
|
|
165
|
-
}, {
|
|
166
|
-
data_mart: {
|
|
167
|
-
id: string;
|
|
168
|
-
title: string;
|
|
169
|
-
url: string;
|
|
170
|
-
};
|
|
171
|
-
}>;
|
|
101
|
+
}, z.core.$strip>;
|
|
102
|
+
}, z.core.$strip>;
|
|
172
103
|
calculation_origin: z.ZodObject<{
|
|
173
104
|
rows: z.ZodLiteral<"taken_from_owox">;
|
|
174
|
-
totals: z.ZodEnum<
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
|
|
179
|
-
data_last_updated:
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
}>;
|
|
105
|
+
totals: z.ZodEnum<{
|
|
106
|
+
failed: "failed";
|
|
107
|
+
calculated_by_owox: "calculated_by_owox";
|
|
108
|
+
not_available: "not_available";
|
|
109
|
+
}>;
|
|
110
|
+
data_last_updated: z.ZodEnum<{
|
|
111
|
+
not_available: "not_available";
|
|
112
|
+
measured_by_owox: "measured_by_owox";
|
|
113
|
+
}>;
|
|
114
|
+
}, z.core.$strip>;
|
|
185
115
|
_instruction: z.ZodString;
|
|
186
116
|
};
|
|
187
117
|
readonly annotations: {
|
|
@@ -14,7 +14,7 @@ var __param = (this && this.__param) || function (paramIndex, decorator) {
|
|
|
14
14
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
15
15
|
exports.QueryDataMartTool = void 0;
|
|
16
16
|
const common_1 = require("@nestjs/common");
|
|
17
|
-
const
|
|
17
|
+
const zod_v4_1 = require("zod-v4");
|
|
18
18
|
const mcp_data_marts_facade_1 = require("../../../data-marts/facades/mcp-data-marts.facade");
|
|
19
19
|
const business_violation_exception_1 = require("../../../common/exceptions/business-violation.exception");
|
|
20
20
|
const project_operation_blocked_exception_1 = require("../../../common/exceptions/project-operation-blocked.exception");
|
|
@@ -94,61 +94,61 @@ Using the results:
|
|
|
94
94
|
If truncated is true, not all matching rows were returned: narrow the query (fewer fields, tighter slices/filters) or raise limit (up to 1000). Always use the source metadata in the response: name the Data Mart the answer came from, distinguish numbers calculated by OWOX from arithmetic you perform yourself, and clearly warn the user when rows were truncated.`;
|
|
95
95
|
zodSchema = query_data_mart_input_1.queryDataMartInputSchema.shape;
|
|
96
96
|
outputSchema = {
|
|
97
|
-
columns:
|
|
98
|
-
column_metadata:
|
|
99
|
-
name:
|
|
100
|
-
display_name:
|
|
101
|
-
description:
|
|
102
|
-
type:
|
|
97
|
+
columns: zod_v4_1.z.array(zod_v4_1.z.string()).describe('Business-friendly result headers, in rows order.'),
|
|
98
|
+
column_metadata: zod_v4_1.z.array(zod_v4_1.z.object({
|
|
99
|
+
name: zod_v4_1.z.string().describe('Exact output column name.'),
|
|
100
|
+
display_name: zod_v4_1.z.string().describe('Business-friendly label for presentation.'),
|
|
101
|
+
description: zod_v4_1.z.string().optional(),
|
|
102
|
+
type: zod_v4_1.z.string().optional(),
|
|
103
103
|
})),
|
|
104
|
-
rows:
|
|
105
|
-
returned_rows:
|
|
106
|
-
truncated:
|
|
107
|
-
truncation:
|
|
104
|
+
rows: zod_v4_1.z.string(),
|
|
105
|
+
returned_rows: zod_v4_1.z.number(),
|
|
106
|
+
truncated: zod_v4_1.z.boolean(),
|
|
107
|
+
truncation: zod_v4_1.z
|
|
108
108
|
.object({
|
|
109
|
-
reasons:
|
|
109
|
+
reasons: zod_v4_1.z.array(zod_v4_1.z.enum(['row_limit', 'payload_byte_cap'])).min(1),
|
|
110
110
|
})
|
|
111
111
|
.optional(),
|
|
112
|
-
totals:
|
|
113
|
-
.record(
|
|
112
|
+
totals: zod_v4_1.z
|
|
113
|
+
.record(zod_v4_1.z.string(), zod_v4_1.z.unknown())
|
|
114
114
|
.nullable()
|
|
115
115
|
.describe('Server-side totals keyed by technical output column name. Match each key to column_metadata[].name.'),
|
|
116
|
-
data_last_updated:
|
|
117
|
-
data_last_updated_at:
|
|
116
|
+
data_last_updated: zod_v4_1.z.object({
|
|
117
|
+
data_last_updated_at: zod_v4_1.z
|
|
118
118
|
.string()
|
|
119
119
|
.nullable()
|
|
120
120
|
.describe('When the SOURCE TABLES last changed in the warehouse (ISO-8601 UTC), not a claim about which period the data covers. null = the warehouse does not report it; treat as unknown, never as stale or fresh.'),
|
|
121
|
-
computed_at:
|
|
121
|
+
computed_at: zod_v4_1.z
|
|
122
122
|
.string()
|
|
123
123
|
.describe('When this was measured. Computed live for this query; never cached.'),
|
|
124
|
-
coverage:
|
|
124
|
+
coverage: zod_v4_1.z
|
|
125
125
|
.enum(['complete', 'partial', 'unavailable'])
|
|
126
126
|
.describe('complete = every source table resolved. partial = some could not be read, so the true time is at least as recent as reported. unavailable = nothing could be determined.'),
|
|
127
|
-
sources:
|
|
128
|
-
.array(
|
|
129
|
-
table:
|
|
130
|
-
data_last_updated_at:
|
|
131
|
-
note:
|
|
127
|
+
sources: zod_v4_1.z
|
|
128
|
+
.array(zod_v4_1.z.object({
|
|
129
|
+
table: zod_v4_1.z.string(),
|
|
130
|
+
data_last_updated_at: zod_v4_1.z.string().nullable(),
|
|
131
|
+
note: zod_v4_1.z.string().optional(),
|
|
132
132
|
}))
|
|
133
133
|
.describe('Per-table detail behind the value. Views are excluded deliberately.'),
|
|
134
134
|
}),
|
|
135
|
-
totals_error:
|
|
135
|
+
totals_error: zod_v4_1.z
|
|
136
136
|
.string()
|
|
137
137
|
.optional()
|
|
138
138
|
.describe('Present only when totals were requested but FAILED. Totals are null in that case for a reason, not because the report has none — do not substitute a total summed from the returned rows.'),
|
|
139
|
-
source:
|
|
140
|
-
data_mart:
|
|
141
|
-
id:
|
|
142
|
-
title:
|
|
143
|
-
url:
|
|
139
|
+
source: zod_v4_1.z.object({
|
|
140
|
+
data_mart: zod_v4_1.z.object({
|
|
141
|
+
id: zod_v4_1.z.string(),
|
|
142
|
+
title: zod_v4_1.z.string(),
|
|
143
|
+
url: zod_v4_1.z.string(),
|
|
144
144
|
}),
|
|
145
145
|
}),
|
|
146
|
-
calculation_origin:
|
|
147
|
-
rows:
|
|
148
|
-
totals:
|
|
149
|
-
data_last_updated:
|
|
146
|
+
calculation_origin: zod_v4_1.z.object({
|
|
147
|
+
rows: zod_v4_1.z.literal('taken_from_owox'),
|
|
148
|
+
totals: zod_v4_1.z.enum(['calculated_by_owox', 'not_available', 'failed']),
|
|
149
|
+
data_last_updated: zod_v4_1.z.enum(['measured_by_owox', 'not_available']),
|
|
150
150
|
}),
|
|
151
|
-
_instruction:
|
|
151
|
+
_instruction: zod_v4_1.z.string(),
|
|
152
152
|
};
|
|
153
153
|
annotations = {
|
|
154
154
|
title: 'Query Data Mart',
|
|
@@ -295,7 +295,7 @@ If truncated is true, not all matching rows were returned: narrow the query (few
|
|
|
295
295
|
}
|
|
296
296
|
}
|
|
297
297
|
mapError(err) {
|
|
298
|
-
if (err instanceof
|
|
298
|
+
if (err instanceof zod_v4_1.z.ZodError) {
|
|
299
299
|
const detail = err.issues
|
|
300
300
|
.map(i => (i.path.length ? `${i.path.join('.')}: ${i.message}` : i.message))
|
|
301
301
|
.join('; ');
|
|
@@ -1,86 +1,43 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
1
|
+
import { z } from 'zod-v4';
|
|
2
2
|
export declare const reportOutputControlsOutputShape: {
|
|
3
|
-
fields: z.ZodArray<z.ZodString
|
|
4
|
-
unique_count_sources: z.ZodArray<z.ZodString
|
|
3
|
+
fields: z.ZodArray<z.ZodString>;
|
|
4
|
+
unique_count_sources: z.ZodArray<z.ZodString>;
|
|
5
5
|
filters: z.ZodArray<z.ZodObject<{
|
|
6
6
|
field: z.ZodString;
|
|
7
7
|
operator: z.ZodString;
|
|
8
8
|
value: z.ZodOptional<z.ZodUnknown>;
|
|
9
|
-
},
|
|
10
|
-
operator: string;
|
|
11
|
-
field: string;
|
|
12
|
-
value?: unknown;
|
|
13
|
-
}, {
|
|
14
|
-
operator: string;
|
|
15
|
-
field: string;
|
|
16
|
-
value?: unknown;
|
|
17
|
-
}>, "many">;
|
|
9
|
+
}, z.core.$strip>>;
|
|
18
10
|
slices: z.ZodArray<z.ZodObject<{
|
|
19
11
|
field: z.ZodString;
|
|
20
12
|
operator: z.ZodString;
|
|
21
13
|
value: z.ZodOptional<z.ZodUnknown>;
|
|
22
|
-
},
|
|
23
|
-
operator: string;
|
|
24
|
-
field: string;
|
|
25
|
-
value?: unknown;
|
|
26
|
-
}, {
|
|
27
|
-
operator: string;
|
|
28
|
-
field: string;
|
|
29
|
-
value?: unknown;
|
|
30
|
-
}>, "many">;
|
|
14
|
+
}, z.core.$strip>>;
|
|
31
15
|
ui_only_filters: z.ZodOptional<z.ZodArray<z.ZodObject<{
|
|
32
16
|
field: z.ZodString;
|
|
33
17
|
operator: z.ZodString;
|
|
34
18
|
value: z.ZodOptional<z.ZodUnknown>;
|
|
35
|
-
|
|
36
|
-
|
|
19
|
+
placement: z.ZodEnum<{
|
|
20
|
+
"pre-join": "pre-join";
|
|
21
|
+
"post-join": "post-join";
|
|
22
|
+
}>;
|
|
37
23
|
function: z.ZodOptional<z.ZodString>;
|
|
38
|
-
},
|
|
39
|
-
operator: string;
|
|
40
|
-
placement: "pre-join" | "post-join";
|
|
41
|
-
field: string;
|
|
42
|
-
function?: string | undefined;
|
|
43
|
-
value?: unknown;
|
|
44
|
-
}, {
|
|
45
|
-
operator: string;
|
|
46
|
-
placement: "pre-join" | "post-join";
|
|
47
|
-
field: string;
|
|
48
|
-
function?: string | undefined;
|
|
49
|
-
value?: unknown;
|
|
50
|
-
}>, "many">>;
|
|
24
|
+
}, z.core.$strip>>>;
|
|
51
25
|
aggregations: z.ZodArray<z.ZodObject<{
|
|
52
26
|
field: z.ZodString;
|
|
53
27
|
function: z.ZodString;
|
|
54
|
-
},
|
|
55
|
-
function: string;
|
|
56
|
-
field: string;
|
|
57
|
-
}, {
|
|
58
|
-
function: string;
|
|
59
|
-
field: string;
|
|
60
|
-
}>, "many">;
|
|
28
|
+
}, z.core.$strip>>;
|
|
61
29
|
date_buckets: z.ZodArray<z.ZodObject<{
|
|
62
30
|
field: z.ZodString;
|
|
63
31
|
unit: z.ZodString;
|
|
64
32
|
time_zone: z.ZodOptional<z.ZodString>;
|
|
65
|
-
},
|
|
66
|
-
unit: string;
|
|
67
|
-
field: string;
|
|
68
|
-
time_zone?: string | undefined;
|
|
69
|
-
}, {
|
|
70
|
-
unit: string;
|
|
71
|
-
field: string;
|
|
72
|
-
time_zone?: string | undefined;
|
|
73
|
-
}>, "many">;
|
|
33
|
+
}, z.core.$strip>>;
|
|
74
34
|
sort: z.ZodArray<z.ZodObject<{
|
|
75
35
|
field: z.ZodString;
|
|
76
|
-
direction: z.ZodEnum<
|
|
77
|
-
|
|
78
|
-
|
|
79
|
-
|
|
80
|
-
},
|
|
81
|
-
direction: "asc" | "desc";
|
|
82
|
-
field: string;
|
|
83
|
-
}>, "many">;
|
|
36
|
+
direction: z.ZodEnum<{
|
|
37
|
+
asc: "asc";
|
|
38
|
+
desc: "desc";
|
|
39
|
+
}>;
|
|
40
|
+
}, z.core.$strip>>;
|
|
84
41
|
limit: z.ZodNullable<z.ZodNumber>;
|
|
85
42
|
};
|
|
86
43
|
export declare const reportSheetInfoOutputShape: {
|
|
@@ -1,45 +1,45 @@
|
|
|
1
1
|
"use strict";
|
|
2
2
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
3
3
|
exports.reportSheetInfoOutputShape = exports.reportOutputControlsOutputShape = void 0;
|
|
4
|
-
const
|
|
5
|
-
const filterOutputSchema = () =>
|
|
6
|
-
field:
|
|
7
|
-
operator:
|
|
8
|
-
value:
|
|
4
|
+
const zod_v4_1 = require("zod-v4");
|
|
5
|
+
const filterOutputSchema = () => zod_v4_1.z.object({
|
|
6
|
+
field: zod_v4_1.z.string(),
|
|
7
|
+
operator: zod_v4_1.z.string().describe('query_data_mart operator vocabulary.'),
|
|
8
|
+
value: zod_v4_1.z.unknown().optional(),
|
|
9
9
|
});
|
|
10
10
|
exports.reportOutputControlsOutputShape = {
|
|
11
|
-
fields:
|
|
12
|
-
.array(
|
|
11
|
+
fields: zod_v4_1.z
|
|
12
|
+
.array(zod_v4_1.z.string())
|
|
13
13
|
.describe("Column names the report exports, or ['*'] when it exports every field. [] is a metrics-only report: no dimension column, only its Unique Count metric(s)."),
|
|
14
|
-
unique_count_sources:
|
|
15
|
-
.array(
|
|
14
|
+
unique_count_sources: zod_v4_1.z
|
|
15
|
+
.array(zod_v4_1.z.string())
|
|
16
16
|
.describe("Unique Count metrics the report carries: 'unique_count' for its own data mart, '<source>__unique_count' for joined sources (the names get_data_mart_details_by_id lists). Set only in the OWOX UI; update_report keeps them."),
|
|
17
|
-
filters:
|
|
17
|
+
filters: zod_v4_1.z
|
|
18
18
|
.array(filterOutputSchema())
|
|
19
19
|
.describe('Row filters applied on every run that update_report "filters" can replace, in add_report/update_report vocabulary.'),
|
|
20
|
-
slices:
|
|
20
|
+
slices: zod_v4_1.z
|
|
21
21
|
.array(filterOutputSchema())
|
|
22
22
|
.describe('Pre-join filters of a blended report that update_report "slices" can replace; empty for non-blended reports.'),
|
|
23
|
-
ui_only_filters:
|
|
23
|
+
ui_only_filters: zod_v4_1.z
|
|
24
24
|
.array(filterOutputSchema().extend({
|
|
25
|
-
placement:
|
|
26
|
-
function:
|
|
25
|
+
placement: zod_v4_1.z.enum(['pre-join', 'post-join']),
|
|
26
|
+
function: zod_v4_1.z
|
|
27
27
|
.string()
|
|
28
28
|
.optional()
|
|
29
29
|
.describe('Set for a post-aggregation (HAVING) rule: the aggregate it constrains.'),
|
|
30
30
|
}))
|
|
31
31
|
.optional()
|
|
32
32
|
.describe('Present only when the report also applies rules created in the OWOX UI that MCP cannot express (post-aggregation constraints, regex, calendar presets such as today or last month). update_report keeps them untouched whatever you send in filters/slices; they are changed or removed in the OWOX UI. Returned as stored — never re-send them.'),
|
|
33
|
-
aggregations:
|
|
34
|
-
date_buckets:
|
|
35
|
-
sort:
|
|
36
|
-
limit:
|
|
33
|
+
aggregations: zod_v4_1.z.array(zod_v4_1.z.object({ field: zod_v4_1.z.string(), function: zod_v4_1.z.string() })),
|
|
34
|
+
date_buckets: zod_v4_1.z.array(zod_v4_1.z.object({ field: zod_v4_1.z.string(), unit: zod_v4_1.z.string(), time_zone: zod_v4_1.z.string().optional() })),
|
|
35
|
+
sort: zod_v4_1.z.array(zod_v4_1.z.object({ field: zod_v4_1.z.string(), direction: zod_v4_1.z.enum(['asc', 'desc']) })),
|
|
36
|
+
limit: zod_v4_1.z.number().nullable().describe('Max rows per run, or null when uncapped.'),
|
|
37
37
|
};
|
|
38
38
|
exports.reportSheetInfoOutputShape = {
|
|
39
|
-
spreadsheet_id:
|
|
39
|
+
spreadsheet_id: zod_v4_1.z
|
|
40
40
|
.string()
|
|
41
41
|
.optional()
|
|
42
42
|
.describe('Google Sheets only. Id of the spreadsheet the report writes to — pass it as spreadsheet_id to add_report to put a related export into the same document.'),
|
|
43
|
-
sheet_url:
|
|
43
|
+
sheet_url: zod_v4_1.z.string().optional().describe("Google Sheets only. Link to the report's sheet."),
|
|
44
44
|
};
|
|
45
45
|
//# sourceMappingURL=report-output-controls-output.js.map
|
|
@@ -1,60 +1,24 @@
|
|
|
1
|
-
import { z } from 'zod';
|
|
1
|
+
import { z } from 'zod-v4';
|
|
2
2
|
import type { McpReportRunOutcome } from '../../../data-marts/facades/mcp-reports.facade';
|
|
3
|
-
export declare const reportRunOutcomeSchema: z.ZodDiscriminatedUnion<
|
|
3
|
+
export declare const reportRunOutcomeSchema: z.ZodDiscriminatedUnion<[z.ZodObject<{
|
|
4
4
|
status: z.ZodLiteral<"queued">;
|
|
5
5
|
run_id: z.ZodString;
|
|
6
6
|
should_poll: z.ZodLiteral<true>;
|
|
7
7
|
message: z.ZodString;
|
|
8
|
-
},
|
|
9
|
-
status: "queued";
|
|
10
|
-
message: string;
|
|
11
|
-
run_id: string;
|
|
12
|
-
should_poll: true;
|
|
13
|
-
}, {
|
|
14
|
-
status: "queued";
|
|
15
|
-
message: string;
|
|
16
|
-
run_id: string;
|
|
17
|
-
should_poll: true;
|
|
18
|
-
}>, z.ZodObject<{
|
|
8
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
19
9
|
status: z.ZodLiteral<"not_requested">;
|
|
20
10
|
should_poll: z.ZodLiteral<false>;
|
|
21
11
|
message: z.ZodString;
|
|
22
|
-
},
|
|
23
|
-
status: "not_requested";
|
|
24
|
-
message: string;
|
|
25
|
-
should_poll: false;
|
|
26
|
-
}, {
|
|
27
|
-
status: "not_requested";
|
|
28
|
-
message: string;
|
|
29
|
-
should_poll: false;
|
|
30
|
-
}>, z.ZodObject<{
|
|
12
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
31
13
|
status: z.ZodLiteral<"not_applicable">;
|
|
32
14
|
should_poll: z.ZodLiteral<false>;
|
|
33
15
|
message: z.ZodString;
|
|
34
|
-
},
|
|
35
|
-
status: "not_applicable";
|
|
36
|
-
message: string;
|
|
37
|
-
should_poll: false;
|
|
38
|
-
}, {
|
|
39
|
-
status: "not_applicable";
|
|
40
|
-
message: string;
|
|
41
|
-
should_poll: false;
|
|
42
|
-
}>, z.ZodObject<{
|
|
16
|
+
}, z.core.$strip>, z.ZodObject<{
|
|
43
17
|
status: z.ZodLiteral<"failed_to_queue">;
|
|
44
18
|
should_poll: z.ZodLiteral<false>;
|
|
45
19
|
error: z.ZodString;
|
|
46
20
|
message: z.ZodString;
|
|
47
|
-
},
|
|
48
|
-
status: "failed_to_queue";
|
|
49
|
-
message: string;
|
|
50
|
-
error: string;
|
|
51
|
-
should_poll: false;
|
|
52
|
-
}, {
|
|
53
|
-
status: "failed_to_queue";
|
|
54
|
-
message: string;
|
|
55
|
-
error: string;
|
|
56
|
-
should_poll: false;
|
|
57
|
-
}>]>;
|
|
21
|
+
}, z.core.$strip>], "status">;
|
|
58
22
|
export type ReportRunOutcomeOutput = z.infer<typeof reportRunOutcomeSchema>;
|
|
59
23
|
export interface ReportRunOutcomeMessages {
|
|
60
24
|
queued: string;
|