@autobe/agent 0.19.1 → 0.21.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/lib/agent/src/AutoBeAgent.js +3 -2
- package/lib/agent/src/AutoBeAgent.js.map +1 -1
- package/lib/agent/src/AutoBeMockAgent.js +4 -3
- package/lib/agent/src/AutoBeMockAgent.js.map +1 -1
- package/lib/agent/src/constants/AutoBeSystemPromptConstant.d.ts +12 -11
- package/lib/agent/src/constants/AutoBeSystemPromptConstant.js.map +1 -1
- package/lib/agent/src/context/AutoBeContext.d.ts +3 -2
- package/lib/agent/src/factory/consentFunctionCall.js +3 -2
- package/lib/agent/src/factory/consentFunctionCall.js.map +1 -1
- package/lib/agent/src/factory/createAutoBeContext.js +11 -6
- package/lib/agent/src/factory/createAutoBeContext.js.map +1 -1
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeReviewHistories.d.ts +6 -0
- package/lib/agent/src/orchestrate/analyze/histories/{transformAnalyzeReviewerHistories.js → transformAnalyzeReviewHistories.js} +24 -29
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeReviewHistories.js.map +1 -0
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeScenarioHistories.js +12 -9
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeScenarioHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeWriteHistories.js +31 -29
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeWriteHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyze.js +19 -5
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyze.js.map +1 -1
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeReview.d.ts +7 -1
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeReview.js +9 -6
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeReview.js.map +1 -1
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeScenario.js +11 -9
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeScenario.js.map +1 -1
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeWrite.d.ts +6 -4
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeWrite.js +5 -1
- package/lib/agent/src/orchestrate/analyze/orchestrateAnalyzeWrite.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceAssetHistories.js +45 -46
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceAssetHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceAuthorizationsHistories.js +13 -13
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceAuthorizationsHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceComplementHistories.js +31 -30
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceComplementHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceEndpointHistories.js +23 -22
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceEndpointHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.d.ts +4 -0
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.js +33 -0
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.js.map +1 -0
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceGroupHistories.js +2 -2
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceOperationHistories.js +27 -26
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceOperationHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceOperationsReviewHistories.js +13 -12
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceOperationsReviewHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.js +4 -4
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceSchemaHistories.js +11 -10
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceSchemaHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceSchemasReviewHistories.js +32 -31
- package/lib/agent/src/orchestrate/interface/histories/transformInterfaceSchemasReviewHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterface.js +3 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterface.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceAuthorizations.js +28 -24
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceAuthorizations.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceComplement.js +2 -0
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceComplement.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceEndpoints.js +11 -5
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceEndpoints.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceEndpointsReview.d.ts +10 -0
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceEndpointsReview.js +365 -0
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceEndpointsReview.js.map +1 -0
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceGroups.js +2 -0
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceGroups.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceOperations.js +80 -54
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceOperations.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceOperationsReview.js +1635 -1180
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceOperationsReview.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceSchemas.js +30 -24
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceSchemas.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceSchemasReview.d.ts +2 -5
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceSchemasReview.js +178 -0
- package/lib/agent/src/orchestrate/interface/orchestrateInterfaceSchemasReview.js.map +1 -1
- package/lib/agent/src/orchestrate/interface/structures/IAutoBeInterfaceEndpointsReviewApplication.d.ts +60 -0
- package/lib/agent/src/orchestrate/interface/structures/IAutoBeInterfaceEndpointsReviewApplication.js +3 -0
- package/lib/agent/src/orchestrate/interface/structures/IAutoBeInterfaceEndpointsReviewApplication.js.map +1 -0
- package/lib/agent/src/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.d.ts +38 -0
- package/lib/agent/src/orchestrate/interface/structures/IAutoBeInterfaceOperationsReviewApplication.d.ts +78 -0
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaComponentsHistories.js +54 -54
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaComponentsHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaCorrectHistories.js +18 -29
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaCorrectHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaReviewHistories.js +37 -34
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaReviewHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaSchemaHistories.js +38 -25
- package/lib/agent/src/orchestrate/prisma/histories/transformPrismaSchemaHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/orchestratePrisma.js +3 -1
- package/lib/agent/src/orchestrate/prisma/orchestratePrisma.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaComponent.js +2 -0
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaComponent.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaCorrect.js +3 -0
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaCorrect.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaReview.js +19 -9
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaReview.js.map +1 -1
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaSchemas.js +28 -21
- package/lib/agent/src/orchestrate/prisma/orchestratePrismaSchemas.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeAuthorization.js +24 -21
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeAuthorization.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeAuthorizationCorrectHistories.js +58 -56
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeAuthorizationCorrectHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeCorrectHistories.js +17 -13
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeCorrectHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeWriteAuthorizationsHistories.js +12 -3
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeWriteAuthorizationsHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeWriteHistories.js +35 -30
- package/lib/agent/src/orchestrate/realize/histories/transformRealizeWriteHistories.js.map +1 -1
- package/lib/{orchestrate/realize/internal/compile.d.ts → agent/src/orchestrate/realize/internal/compileRealizeFiles.d.ts} +1 -1
- package/lib/agent/src/orchestrate/realize/internal/{compile.js → compileRealizeFiles.js} +6 -6
- package/lib/agent/src/orchestrate/realize/internal/compileRealizeFiles.js.map +1 -0
- package/lib/agent/src/orchestrate/realize/orchestrateRealize.js +26 -12
- package/lib/agent/src/orchestrate/realize/orchestrateRealize.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeAuthorization.js +9 -3
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeAuthorization.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js +3 -1
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeCorrect.d.ts +2 -6
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeCorrect.js +12 -8
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeCorrect.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeScenario.d.ts +0 -66
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeScenario.js +2 -2
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeScenario.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeWrite.d.ts +3 -6
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeWrite.js +25 -21
- package/lib/agent/src/orchestrate/realize/orchestrateRealizeWrite.js.map +1 -1
- package/lib/agent/src/orchestrate/realize/structures/IAutoBeRealizeScenarioApplication.d.ts +2 -2
- package/lib/agent/src/orchestrate/realize/structures/IAutoBeRealizeWriteApplication.d.ts +7 -2
- package/lib/agent/src/orchestrate/test/compile/completeTestCode.js +13 -10
- package/lib/agent/src/orchestrate/test/compile/completeTestCode.js.map +1 -1
- package/lib/agent/src/orchestrate/test/compile/getTestExternalDeclarations.js +1 -1
- package/lib/agent/src/orchestrate/test/compile/getTestExternalDeclarations.js.map +1 -1
- package/lib/agent/src/orchestrate/test/histories/transformTestCorrectHistories.d.ts +3 -1
- package/lib/agent/src/orchestrate/test/histories/transformTestCorrectHistories.js +44 -27
- package/lib/agent/src/orchestrate/test/histories/transformTestCorrectHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/test/histories/transformTestScenarioHistories.js +63 -60
- package/lib/agent/src/orchestrate/test/histories/transformTestScenarioHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/test/histories/transformTestWriteHistories.d.ts +3 -1
- package/lib/agent/src/orchestrate/test/histories/transformTestWriteHistories.js +118 -96
- package/lib/agent/src/orchestrate/test/histories/transformTestWriteHistories.js.map +1 -1
- package/lib/agent/src/orchestrate/test/orchestrateTest.js +6 -5
- package/lib/agent/src/orchestrate/test/orchestrateTest.js.map +1 -1
- package/lib/agent/src/orchestrate/test/orchestrateTestCorrect.js +17 -8
- package/lib/agent/src/orchestrate/test/orchestrateTestCorrect.js.map +1 -1
- package/lib/agent/src/orchestrate/test/orchestrateTestScenario.js +30 -18
- package/lib/agent/src/orchestrate/test/orchestrateTestScenario.js.map +1 -1
- package/lib/agent/src/orchestrate/test/orchestrateTestWrite.js +18 -18
- package/lib/agent/src/orchestrate/test/orchestrateTestWrite.js.map +1 -1
- package/lib/agent/src/orchestrate/test/structures/IAutoBeTestCorrectApplication.d.ts +2 -2
- package/lib/agent/src/orchestrate/test/structures/IAutoBeTestScenarioApplication.d.ts +28 -1
- package/lib/agent/src/orchestrate/test/structures/IAutoBeTestWriteApplication.d.ts +2 -2
- package/lib/agent/src/utils/executeCachedBatch.d.ts +1 -0
- package/lib/agent/src/utils/executeCachedBatch.js +23 -0
- package/lib/agent/src/utils/executeCachedBatch.js.map +1 -0
- package/lib/constants/AutoBeSystemPromptConstant.d.ts +12 -11
- package/lib/context/AutoBeContext.d.ts +3 -2
- package/lib/index.mjs +3265 -1702
- package/lib/index.mjs.map +1 -1
- package/lib/orchestrate/analyze/histories/transformAnalyzeReviewHistories.d.ts +6 -0
- package/lib/orchestrate/analyze/orchestrateAnalyzeReview.d.ts +7 -1
- package/lib/orchestrate/analyze/orchestrateAnalyzeWrite.d.ts +6 -4
- package/lib/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.d.ts +4 -0
- package/lib/orchestrate/interface/orchestrateInterfaceEndpointsReview.d.ts +10 -0
- package/lib/orchestrate/interface/orchestrateInterfaceSchemasReview.d.ts +2 -5
- package/lib/orchestrate/interface/structures/IAutoBeInterfaceEndpointsReviewApplication.d.ts +60 -0
- package/lib/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.d.ts +38 -0
- package/lib/orchestrate/interface/structures/IAutoBeInterfaceOperationsReviewApplication.d.ts +78 -0
- package/lib/{agent/src/orchestrate/realize/internal/compile.d.ts → orchestrate/realize/internal/compileRealizeFiles.d.ts} +1 -1
- package/lib/orchestrate/realize/orchestrateRealizeCorrect.d.ts +2 -6
- package/lib/orchestrate/realize/orchestrateRealizeScenario.d.ts +0 -66
- package/lib/orchestrate/realize/orchestrateRealizeWrite.d.ts +3 -6
- package/lib/orchestrate/realize/structures/IAutoBeRealizeScenarioApplication.d.ts +2 -2
- package/lib/orchestrate/realize/structures/IAutoBeRealizeWriteApplication.d.ts +7 -2
- package/lib/orchestrate/test/histories/transformTestCorrectHistories.d.ts +3 -1
- package/lib/orchestrate/test/histories/transformTestWriteHistories.d.ts +3 -1
- package/lib/orchestrate/test/structures/IAutoBeTestCorrectApplication.d.ts +2 -2
- package/lib/orchestrate/test/structures/IAutoBeTestScenarioApplication.d.ts +28 -1
- package/lib/orchestrate/test/structures/IAutoBeTestWriteApplication.d.ts +2 -2
- package/lib/utils/executeCachedBatch.d.ts +1 -0
- package/package.json +7 -7
- package/src/AutoBeAgent.ts +4 -3
- package/src/AutoBeMockAgent.ts +5 -4
- package/src/constants/AutoBeSystemPromptConstant.ts +12 -11
- package/src/context/AutoBeContext.ts +3 -0
- package/src/factory/consentFunctionCall.ts +4 -3
- package/src/factory/createAutoBeContext.ts +11 -7
- package/src/orchestrate/analyze/histories/{transformAnalyzeReviewerHistories.ts → transformAnalyzeReviewHistories.ts} +23 -30
- package/src/orchestrate/analyze/histories/transformAnalyzeScenarioHistories.ts +13 -10
- package/src/orchestrate/analyze/histories/transformAnalyzeWriteHistories.ts +60 -61
- package/src/orchestrate/analyze/orchestrateAnalyze.ts +20 -13
- package/src/orchestrate/analyze/orchestrateAnalyzeReview.ts +20 -9
- package/src/orchestrate/analyze/orchestrateAnalyzeScenario.ts +13 -11
- package/src/orchestrate/analyze/orchestrateAnalyzeWrite.ts +10 -5
- package/src/orchestrate/interface/histories/transformInterfaceAssetHistories.ts +47 -48
- package/src/orchestrate/interface/histories/transformInterfaceAuthorizationsHistories.ts +14 -14
- package/src/orchestrate/interface/histories/transformInterfaceComplementHistories.ts +31 -30
- package/src/orchestrate/interface/histories/transformInterfaceEndpointHistories.ts +20 -19
- package/src/orchestrate/interface/histories/transformInterfaceEndpointsReviewHistories.ts +39 -0
- package/src/orchestrate/interface/histories/transformInterfaceGroupHistories.ts +3 -3
- package/src/orchestrate/interface/histories/transformInterfaceOperationHistories.ts +23 -22
- package/src/orchestrate/interface/histories/transformInterfaceOperationsReviewHistories.ts +12 -11
- package/src/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.ts +5 -5
- package/src/orchestrate/interface/histories/transformInterfaceSchemaHistories.ts +11 -10
- package/src/orchestrate/interface/histories/transformInterfaceSchemasReviewHistories.ts +31 -30
- package/src/orchestrate/interface/orchestrateInterface.ts +4 -2
- package/src/orchestrate/interface/orchestrateInterfaceAuthorizations.ts +36 -29
- package/src/orchestrate/interface/orchestrateInterfaceComplement.ts +2 -0
- package/src/orchestrate/interface/orchestrateInterfaceEndpoints.ts +18 -10
- package/src/orchestrate/interface/orchestrateInterfaceEndpointsReview.ts +95 -0
- package/src/orchestrate/interface/orchestrateInterfaceGroups.ts +2 -0
- package/src/orchestrate/interface/orchestrateInterfaceOperations.ts +53 -50
- package/src/orchestrate/interface/orchestrateInterfaceOperationsReview.ts +120 -10
- package/src/orchestrate/interface/orchestrateInterfaceSchemas.ts +47 -23
- package/src/orchestrate/interface/orchestrateInterfaceSchemasReview.ts +85 -1
- package/src/orchestrate/interface/structures/IAutoBeInterfaceEndpointsReviewApplication.ts +65 -0
- package/src/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.ts +39 -0
- package/src/orchestrate/interface/structures/IAutoBeInterfaceOperationsReviewApplication.ts +82 -1
- package/src/orchestrate/prisma/histories/transformPrismaComponentsHistories.ts +57 -55
- package/src/orchestrate/prisma/histories/transformPrismaCorrectHistories.ts +19 -30
- package/src/orchestrate/prisma/histories/transformPrismaReviewHistories.ts +38 -35
- package/src/orchestrate/prisma/histories/transformPrismaSchemaHistories.ts +36 -23
- package/src/orchestrate/prisma/orchestratePrisma.ts +4 -2
- package/src/orchestrate/prisma/orchestratePrismaComponent.ts +2 -0
- package/src/orchestrate/prisma/orchestratePrismaCorrect.ts +3 -0
- package/src/orchestrate/prisma/orchestratePrismaReview.ts +26 -13
- package/src/orchestrate/prisma/orchestratePrismaSchemas.ts +25 -17
- package/src/orchestrate/realize/histories/transformRealizeAuthorization.ts +24 -21
- package/src/orchestrate/realize/histories/transformRealizeAuthorizationCorrectHistories.ts +42 -40
- package/src/orchestrate/realize/histories/transformRealizeCorrectHistories.ts +17 -13
- package/src/orchestrate/realize/histories/transformRealizeWriteAuthorizationsHistories.ts +14 -5
- package/src/orchestrate/realize/histories/transformRealizeWriteHistories.ts +35 -30
- package/src/orchestrate/realize/internal/{compile.ts → compileRealizeFiles.ts} +15 -11
- package/src/orchestrate/realize/orchestrateRealize.ts +59 -40
- package/src/orchestrate/realize/orchestrateRealizeAuthorization.ts +19 -10
- package/src/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.ts +3 -0
- package/src/orchestrate/realize/orchestrateRealizeCorrect.ts +10 -10
- package/src/orchestrate/realize/orchestrateRealizeScenario.ts +7 -77
- package/src/orchestrate/realize/orchestrateRealizeWrite.ts +24 -23
- package/src/orchestrate/realize/structures/IAutoBeRealizeScenarioApplication.ts +6 -2
- package/src/orchestrate/realize/structures/IAutoBeRealizeWriteApplication.ts +10 -5
- package/src/orchestrate/test/compile/completeTestCode.ts +17 -13
- package/src/orchestrate/test/compile/getTestExternalDeclarations.ts +2 -0
- package/src/orchestrate/test/experimental/transformTestCorrectHistories.ast +4 -4
- package/src/orchestrate/test/histories/transformTestCorrectHistories.ts +50 -37
- package/src/orchestrate/test/histories/transformTestScenarioHistories.ts +62 -57
- package/src/orchestrate/test/histories/transformTestWriteHistories.ts +27 -7
- package/src/orchestrate/test/orchestrateTest.ts +7 -9
- package/src/orchestrate/test/orchestrateTestCorrect.ts +39 -25
- package/src/orchestrate/test/orchestrateTestScenario.ts +28 -21
- package/src/orchestrate/test/orchestrateTestWrite.ts +17 -18
- package/src/orchestrate/test/structures/IAutoBeTestCorrectApplication.ts +3 -3
- package/src/orchestrate/test/structures/IAutoBeTestScenarioApplication.ts +28 -1
- package/src/orchestrate/test/structures/IAutoBeTestWriteApplication.ts +2 -2
- package/src/utils/executeCachedBatch.ts +15 -0
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeReviewerHistories.d.ts +0 -6
- package/lib/agent/src/orchestrate/analyze/histories/transformAnalyzeReviewerHistories.js.map +0 -1
- package/lib/agent/src/orchestrate/realize/internal/compile.js.map +0 -1
- package/lib/agent/src/orchestrate/test/histories/transformTestHistories.d.ts +0 -3
- package/lib/agent/src/orchestrate/test/histories/transformTestHistories.js +0 -74
- package/lib/agent/src/orchestrate/test/histories/transformTestHistories.js.map +0 -1
- package/lib/orchestrate/analyze/histories/transformAnalyzeReviewerHistories.d.ts +0 -6
- package/lib/orchestrate/test/histories/transformTestHistories.d.ts +0 -3
- package/src/orchestrate/test/histories/transformTestHistories.ts +0 -77
|
@@ -47,12 +47,15 @@ var __importDefault = (this && this.__importDefault) || function (mod) {
|
|
|
47
47
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
48
48
|
exports.orchestrateInterfaceOperationsReview = orchestrateInterfaceOperationsReview;
|
|
49
49
|
const __typia_transform__validateReport = __importStar(require("typia/lib/internal/_validateReport.js"));
|
|
50
|
+
const __typia_transform__llmApplicationFinalize = __importStar(require("typia/lib/internal/_llmApplicationFinalize.js"));
|
|
50
51
|
const typia_1 = __importDefault(require("typia"));
|
|
52
|
+
const uuid_1 = require("uuid");
|
|
51
53
|
const transformInterfaceOperationsReviewHistories_1 = require("./histories/transformInterfaceOperationsReviewHistories");
|
|
52
54
|
function orchestrateInterfaceOperationsReview(ctx, operations, progress) {
|
|
53
55
|
return __awaiter(this, void 0, void 0, function* () {
|
|
54
|
-
var _a, _b;
|
|
56
|
+
var _a, _b, _c;
|
|
55
57
|
try {
|
|
58
|
+
const files = (_a = ctx.state().prisma) === null || _a === void 0 ? void 0 : _a.result.data.files;
|
|
56
59
|
const pointer = {
|
|
57
60
|
value: null,
|
|
58
61
|
};
|
|
@@ -61,6 +64,7 @@ function orchestrateInterfaceOperationsReview(ctx, operations, progress) {
|
|
|
61
64
|
histories: (0, transformInterfaceOperationsReviewHistories_1.transformInterfaceOperationsReviewHistories)(ctx, operations),
|
|
62
65
|
controller: createReviewController({
|
|
63
66
|
model: ctx.model,
|
|
67
|
+
prismaSchemas: files,
|
|
64
68
|
build: (next) => {
|
|
65
69
|
pointer.value = next;
|
|
66
70
|
},
|
|
@@ -76,13 +80,14 @@ function orchestrateInterfaceOperationsReview(ctx, operations, progress) {
|
|
|
76
80
|
const content = pointer.value.content.map((op) => (Object.assign(Object.assign({}, op), { authorizationType: null })));
|
|
77
81
|
ctx.dispatch({
|
|
78
82
|
type: "interfaceOperationsReview",
|
|
83
|
+
id: (0, uuid_1.v7)(),
|
|
79
84
|
operations: content,
|
|
80
85
|
review: pointer.value.review,
|
|
81
86
|
plan: pointer.value.plan,
|
|
82
87
|
content,
|
|
83
88
|
tokenUsage,
|
|
84
89
|
created_at: new Date().toISOString(),
|
|
85
|
-
step: (
|
|
90
|
+
step: (_c = (_b = ctx.state().analyze) === null || _b === void 0 ? void 0 : _b.step) !== null && _c !== void 0 ? _c : 0,
|
|
86
91
|
total: progress.total,
|
|
87
92
|
completed: ++progress.completed,
|
|
88
93
|
});
|
|
@@ -96,7 +101,373 @@ function orchestrateInterfaceOperationsReview(ctx, operations, progress) {
|
|
|
96
101
|
});
|
|
97
102
|
}
|
|
98
103
|
function createReviewController(props) {
|
|
99
|
-
const
|
|
104
|
+
const validate = (next) => {
|
|
105
|
+
const result = (() => { const _io0 = input => "string" === typeof input.review && "string" === typeof input.plan && (Array.isArray(input.content) && input.content.every(elem => "object" === typeof elem && null !== elem && _io1(elem))); const _io1 = input => "string" === typeof input.prisma_schemas && "string" === typeof input.model_name && (null === input.soft_delete_column || "string" === typeof input.soft_delete_column) && "string" === typeof input.description && ("string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name)) && "string" === typeof input.specification && "string" === typeof input.summary && ("string" === typeof input.path && RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path)) && (Array.isArray(input.parameters) && input.parameters.every(elem => "object" === typeof elem && null !== elem && _io2(elem))) && (null === input.requestBody || "object" === typeof input.requestBody && null !== input.requestBody && _io6(input.requestBody)) && (null === input.responseBody || "object" === typeof input.responseBody && null !== input.responseBody && _io7(input.responseBody)) && (null === input.authorizationRole || "string" === typeof input.authorizationRole && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationRole) && 1 <= input.authorizationRole.length)) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) && "string" === typeof input.description && ("object" === typeof input.schema && null !== input.schema && _iu0(input.schema)); const _io3 = input => (undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000)) && (undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000)) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 && 0 < input.multipleOf)) && "integer" === input.type; const _io4 = input => (undefined === input.minimum || "number" === typeof input.minimum) && (undefined === input.maximum || "number" === typeof input.maximum) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && 0 < input.multipleOf) && "number" === input.type; const _io5 = input => (undefined === input.format || "string" === typeof input.format) && (undefined === input.pattern || "string" === typeof input.pattern) && (undefined === input.contentMediaType || "string" === typeof input.contentMediaType) && (undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 18446744073709552000)) && (undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 18446744073709552000)) && "string" === input.type; const _io6 = input => "string" === typeof input.description && "string" === typeof input.typeName; const _io7 = input => "string" === typeof input.description && "string" === typeof input.typeName; const _iu0 = input => (() => {
|
|
106
|
+
if ("number" === input.type)
|
|
107
|
+
return _io4(input);
|
|
108
|
+
else if ("integer" === input.type)
|
|
109
|
+
return _io3(input);
|
|
110
|
+
else if ("string" === input.type)
|
|
111
|
+
return _io5(input);
|
|
112
|
+
else
|
|
113
|
+
return false;
|
|
114
|
+
})(); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.review || _report(_exceptionable, {
|
|
115
|
+
path: _path + ".review",
|
|
116
|
+
expected: "string",
|
|
117
|
+
value: input.review
|
|
118
|
+
}), "string" === typeof input.plan || _report(_exceptionable, {
|
|
119
|
+
path: _path + ".plan",
|
|
120
|
+
expected: "string",
|
|
121
|
+
value: input.plan
|
|
122
|
+
}), (Array.isArray(input.content) || _report(_exceptionable, {
|
|
123
|
+
path: _path + ".content",
|
|
124
|
+
expected: "Array<IAutoBeInterfaceOperationsReviewApplication.IOperation>",
|
|
125
|
+
value: input.content
|
|
126
|
+
})) && input.content.map((elem, _index3) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
127
|
+
path: _path + ".content[" + _index3 + "]",
|
|
128
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IOperation",
|
|
129
|
+
value: elem
|
|
130
|
+
})) && _vo1(elem, _path + ".content[" + _index3 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
131
|
+
path: _path + ".content[" + _index3 + "]",
|
|
132
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IOperation",
|
|
133
|
+
value: elem
|
|
134
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
135
|
+
path: _path + ".content",
|
|
136
|
+
expected: "Array<IAutoBeInterfaceOperationsReviewApplication.IOperation>",
|
|
137
|
+
value: input.content
|
|
138
|
+
})].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.prisma_schemas || _report(_exceptionable, {
|
|
139
|
+
path: _path + ".prisma_schemas",
|
|
140
|
+
expected: "string",
|
|
141
|
+
value: input.prisma_schemas
|
|
142
|
+
}), "string" === typeof input.model_name || _report(_exceptionable, {
|
|
143
|
+
path: _path + ".model_name",
|
|
144
|
+
expected: "string",
|
|
145
|
+
value: input.model_name
|
|
146
|
+
}), null === input.soft_delete_column || "string" === typeof input.soft_delete_column || _report(_exceptionable, {
|
|
147
|
+
path: _path + ".soft_delete_column",
|
|
148
|
+
expected: "(null | string)",
|
|
149
|
+
value: input.soft_delete_column
|
|
150
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
151
|
+
path: _path + ".description",
|
|
152
|
+
expected: "string",
|
|
153
|
+
value: input.description
|
|
154
|
+
}), "string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
155
|
+
path: _path + ".name",
|
|
156
|
+
expected: "string & CamelPattern",
|
|
157
|
+
value: input.name
|
|
158
|
+
})) || _report(_exceptionable, {
|
|
159
|
+
path: _path + ".name",
|
|
160
|
+
expected: "(string & CamelPattern)",
|
|
161
|
+
value: input.name
|
|
162
|
+
}), "string" === typeof input.specification || _report(_exceptionable, {
|
|
163
|
+
path: _path + ".specification",
|
|
164
|
+
expected: "string",
|
|
165
|
+
value: input.specification
|
|
166
|
+
}), "string" === typeof input.summary || _report(_exceptionable, {
|
|
167
|
+
path: _path + ".summary",
|
|
168
|
+
expected: "string",
|
|
169
|
+
value: input.summary
|
|
170
|
+
}), "string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
|
|
171
|
+
path: _path + ".path",
|
|
172
|
+
expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
|
|
173
|
+
value: input.path
|
|
174
|
+
})) || _report(_exceptionable, {
|
|
175
|
+
path: _path + ".path",
|
|
176
|
+
expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
|
|
177
|
+
value: input.path
|
|
178
|
+
}), (Array.isArray(input.parameters) || _report(_exceptionable, {
|
|
179
|
+
path: _path + ".parameters",
|
|
180
|
+
expected: "Array<AutoBeOpenApi.IParameter>",
|
|
181
|
+
value: input.parameters
|
|
182
|
+
})) && input.parameters.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
183
|
+
path: _path + ".parameters[" + _index4 + "]",
|
|
184
|
+
expected: "AutoBeOpenApi.IParameter",
|
|
185
|
+
value: elem
|
|
186
|
+
})) && _vo2(elem, _path + ".parameters[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
187
|
+
path: _path + ".parameters[" + _index4 + "]",
|
|
188
|
+
expected: "AutoBeOpenApi.IParameter",
|
|
189
|
+
value: elem
|
|
190
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
191
|
+
path: _path + ".parameters",
|
|
192
|
+
expected: "Array<AutoBeOpenApi.IParameter>",
|
|
193
|
+
value: input.parameters
|
|
194
|
+
}), null === input.requestBody || ("object" === typeof input.requestBody && null !== input.requestBody || _report(_exceptionable, {
|
|
195
|
+
path: _path + ".requestBody",
|
|
196
|
+
expected: "(AutoBeOpenApi.IRequestBody | null)",
|
|
197
|
+
value: input.requestBody
|
|
198
|
+
})) && _vo6(input.requestBody, _path + ".requestBody", true && _exceptionable) || _report(_exceptionable, {
|
|
199
|
+
path: _path + ".requestBody",
|
|
200
|
+
expected: "(AutoBeOpenApi.IRequestBody | null)",
|
|
201
|
+
value: input.requestBody
|
|
202
|
+
}), null === input.responseBody || ("object" === typeof input.responseBody && null !== input.responseBody || _report(_exceptionable, {
|
|
203
|
+
path: _path + ".responseBody",
|
|
204
|
+
expected: "(AutoBeOpenApi.IResponseBody | null)",
|
|
205
|
+
value: input.responseBody
|
|
206
|
+
})) && _vo7(input.responseBody, _path + ".responseBody", true && _exceptionable) || _report(_exceptionable, {
|
|
207
|
+
path: _path + ".responseBody",
|
|
208
|
+
expected: "(AutoBeOpenApi.IResponseBody | null)",
|
|
209
|
+
value: input.responseBody
|
|
210
|
+
}), null === input.authorizationRole || "string" === typeof input.authorizationRole && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationRole) || _report(_exceptionable, {
|
|
211
|
+
path: _path + ".authorizationRole",
|
|
212
|
+
expected: "string & CamelPattern",
|
|
213
|
+
value: input.authorizationRole
|
|
214
|
+
})) && (1 <= input.authorizationRole.length || _report(_exceptionable, {
|
|
215
|
+
path: _path + ".authorizationRole",
|
|
216
|
+
expected: "string & MinLength<1>",
|
|
217
|
+
value: input.authorizationRole
|
|
218
|
+
})) || _report(_exceptionable, {
|
|
219
|
+
path: _path + ".authorizationRole",
|
|
220
|
+
expected: "((string & CamelPattern & MinLength<1>) | null)",
|
|
221
|
+
value: input.authorizationRole
|
|
222
|
+
}), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
|
|
223
|
+
path: _path + ".method",
|
|
224
|
+
expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
|
|
225
|
+
value: input.method
|
|
226
|
+
})].every(flag => flag); const _vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
227
|
+
path: _path + ".name",
|
|
228
|
+
expected: "string & CamelPattern",
|
|
229
|
+
value: input.name
|
|
230
|
+
})) || _report(_exceptionable, {
|
|
231
|
+
path: _path + ".name",
|
|
232
|
+
expected: "(string & CamelPattern)",
|
|
233
|
+
value: input.name
|
|
234
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
235
|
+
path: _path + ".description",
|
|
236
|
+
expected: "string",
|
|
237
|
+
value: input.description
|
|
238
|
+
}), ("object" === typeof input.schema && null !== input.schema || _report(_exceptionable, {
|
|
239
|
+
path: _path + ".schema",
|
|
240
|
+
expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
|
|
241
|
+
value: input.schema
|
|
242
|
+
})) && _vu0(input.schema, _path + ".schema", true && _exceptionable) || _report(_exceptionable, {
|
|
243
|
+
path: _path + ".schema",
|
|
244
|
+
expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
|
|
245
|
+
value: input.schema
|
|
246
|
+
})].every(flag => flag); const _vo3 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000 || _report(_exceptionable, {
|
|
247
|
+
path: _path + ".minimum",
|
|
248
|
+
expected: "number & Type<\"int64\">",
|
|
249
|
+
value: input.minimum
|
|
250
|
+
})) || _report(_exceptionable, {
|
|
251
|
+
path: _path + ".minimum",
|
|
252
|
+
expected: "((number & Type<\"int64\">) | undefined)",
|
|
253
|
+
value: input.minimum
|
|
254
|
+
}), undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000 || _report(_exceptionable, {
|
|
255
|
+
path: _path + ".maximum",
|
|
256
|
+
expected: "number & Type<\"int64\">",
|
|
257
|
+
value: input.maximum
|
|
258
|
+
})) || _report(_exceptionable, {
|
|
259
|
+
path: _path + ".maximum",
|
|
260
|
+
expected: "((number & Type<\"int64\">) | undefined)",
|
|
261
|
+
value: input.maximum
|
|
262
|
+
}), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
|
|
263
|
+
path: _path + ".exclusiveMinimum",
|
|
264
|
+
expected: "(number | undefined)",
|
|
265
|
+
value: input.exclusiveMinimum
|
|
266
|
+
}), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
|
|
267
|
+
path: _path + ".exclusiveMaximum",
|
|
268
|
+
expected: "(number | undefined)",
|
|
269
|
+
value: input.exclusiveMaximum
|
|
270
|
+
}), undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 || _report(_exceptionable, {
|
|
271
|
+
path: _path + ".multipleOf",
|
|
272
|
+
expected: "number & Type<\"uint64\">",
|
|
273
|
+
value: input.multipleOf
|
|
274
|
+
})) && (0 < input.multipleOf || _report(_exceptionable, {
|
|
275
|
+
path: _path + ".multipleOf",
|
|
276
|
+
expected: "number & ExclusiveMinimum<0>",
|
|
277
|
+
value: input.multipleOf
|
|
278
|
+
})) || _report(_exceptionable, {
|
|
279
|
+
path: _path + ".multipleOf",
|
|
280
|
+
expected: "((number & Type<\"uint64\"> & ExclusiveMinimum<0>) | undefined)",
|
|
281
|
+
value: input.multipleOf
|
|
282
|
+
}), "integer" === input.type || _report(_exceptionable, {
|
|
283
|
+
path: _path + ".type",
|
|
284
|
+
expected: "\"integer\"",
|
|
285
|
+
value: input.type
|
|
286
|
+
})].every(flag => flag); const _vo4 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum || _report(_exceptionable, {
|
|
287
|
+
path: _path + ".minimum",
|
|
288
|
+
expected: "(number | undefined)",
|
|
289
|
+
value: input.minimum
|
|
290
|
+
}), undefined === input.maximum || "number" === typeof input.maximum || _report(_exceptionable, {
|
|
291
|
+
path: _path + ".maximum",
|
|
292
|
+
expected: "(number | undefined)",
|
|
293
|
+
value: input.maximum
|
|
294
|
+
}), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
|
|
295
|
+
path: _path + ".exclusiveMinimum",
|
|
296
|
+
expected: "(number | undefined)",
|
|
297
|
+
value: input.exclusiveMinimum
|
|
298
|
+
}), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
|
|
299
|
+
path: _path + ".exclusiveMaximum",
|
|
300
|
+
expected: "(number | undefined)",
|
|
301
|
+
value: input.exclusiveMaximum
|
|
302
|
+
}), undefined === input.multipleOf || "number" === typeof input.multipleOf && (0 < input.multipleOf || _report(_exceptionable, {
|
|
303
|
+
path: _path + ".multipleOf",
|
|
304
|
+
expected: "number & ExclusiveMinimum<0>",
|
|
305
|
+
value: input.multipleOf
|
|
306
|
+
})) || _report(_exceptionable, {
|
|
307
|
+
path: _path + ".multipleOf",
|
|
308
|
+
expected: "((number & ExclusiveMinimum<0>) | undefined)",
|
|
309
|
+
value: input.multipleOf
|
|
310
|
+
}), "number" === input.type || _report(_exceptionable, {
|
|
311
|
+
path: _path + ".type",
|
|
312
|
+
expected: "\"number\"",
|
|
313
|
+
value: input.type
|
|
314
|
+
})].every(flag => flag); const _vo5 = (input, _path, _exceptionable = true) => [undefined === input.format || "string" === typeof input.format || _report(_exceptionable, {
|
|
315
|
+
path: _path + ".format",
|
|
316
|
+
expected: "(string | undefined)",
|
|
317
|
+
value: input.format
|
|
318
|
+
}), undefined === input.pattern || "string" === typeof input.pattern || _report(_exceptionable, {
|
|
319
|
+
path: _path + ".pattern",
|
|
320
|
+
expected: "(string | undefined)",
|
|
321
|
+
value: input.pattern
|
|
322
|
+
}), undefined === input.contentMediaType || "string" === typeof input.contentMediaType || _report(_exceptionable, {
|
|
323
|
+
path: _path + ".contentMediaType",
|
|
324
|
+
expected: "(string | undefined)",
|
|
325
|
+
value: input.contentMediaType
|
|
326
|
+
}), undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 18446744073709552000 || _report(_exceptionable, {
|
|
327
|
+
path: _path + ".minLength",
|
|
328
|
+
expected: "number & Type<\"uint64\">",
|
|
329
|
+
value: input.minLength
|
|
330
|
+
})) || _report(_exceptionable, {
|
|
331
|
+
path: _path + ".minLength",
|
|
332
|
+
expected: "((number & Type<\"uint64\">) | undefined)",
|
|
333
|
+
value: input.minLength
|
|
334
|
+
}), undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 18446744073709552000 || _report(_exceptionable, {
|
|
335
|
+
path: _path + ".maxLength",
|
|
336
|
+
expected: "number & Type<\"uint64\">",
|
|
337
|
+
value: input.maxLength
|
|
338
|
+
})) || _report(_exceptionable, {
|
|
339
|
+
path: _path + ".maxLength",
|
|
340
|
+
expected: "((number & Type<\"uint64\">) | undefined)",
|
|
341
|
+
value: input.maxLength
|
|
342
|
+
}), "string" === input.type || _report(_exceptionable, {
|
|
343
|
+
path: _path + ".type",
|
|
344
|
+
expected: "\"string\"",
|
|
345
|
+
value: input.type
|
|
346
|
+
})].every(flag => flag); const _vo6 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
|
|
347
|
+
path: _path + ".description",
|
|
348
|
+
expected: "string",
|
|
349
|
+
value: input.description
|
|
350
|
+
}), "string" === typeof input.typeName || _report(_exceptionable, {
|
|
351
|
+
path: _path + ".typeName",
|
|
352
|
+
expected: "string",
|
|
353
|
+
value: input.typeName
|
|
354
|
+
})].every(flag => flag); const _vo7 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
|
|
355
|
+
path: _path + ".description",
|
|
356
|
+
expected: "string",
|
|
357
|
+
value: input.description
|
|
358
|
+
}), "string" === typeof input.typeName || _report(_exceptionable, {
|
|
359
|
+
path: _path + ".typeName",
|
|
360
|
+
expected: "string",
|
|
361
|
+
value: input.typeName
|
|
362
|
+
})].every(flag => flag); const _vu0 = (input, _path, _exceptionable = true) => (() => {
|
|
363
|
+
if ("number" === input.type)
|
|
364
|
+
return _vo4(input, _path, true && _exceptionable);
|
|
365
|
+
else if ("integer" === input.type)
|
|
366
|
+
return _vo3(input, _path, true && _exceptionable);
|
|
367
|
+
else if ("string" === input.type)
|
|
368
|
+
return _vo5(input, _path, true && _exceptionable);
|
|
369
|
+
else
|
|
370
|
+
return _report(_exceptionable, {
|
|
371
|
+
path: _path,
|
|
372
|
+
expected: "(AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.IString)",
|
|
373
|
+
value: input
|
|
374
|
+
});
|
|
375
|
+
})(); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
|
|
376
|
+
if (false === __is(input)) {
|
|
377
|
+
errors = [];
|
|
378
|
+
_report = __typia_transform__validateReport._validateReport(errors);
|
|
379
|
+
((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
|
|
380
|
+
path: _path + "",
|
|
381
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IProps",
|
|
382
|
+
value: input
|
|
383
|
+
})) && _vo0(input, _path + "", true) || _report(true, {
|
|
384
|
+
path: _path + "",
|
|
385
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IProps",
|
|
386
|
+
value: input
|
|
387
|
+
}))(input, "$input", true);
|
|
388
|
+
const success = 0 === errors.length;
|
|
389
|
+
return success ? {
|
|
390
|
+
success,
|
|
391
|
+
data: input
|
|
392
|
+
} : {
|
|
393
|
+
success,
|
|
394
|
+
errors,
|
|
395
|
+
data: input
|
|
396
|
+
};
|
|
397
|
+
}
|
|
398
|
+
return {
|
|
399
|
+
success: true,
|
|
400
|
+
data: input
|
|
401
|
+
};
|
|
402
|
+
}; })()(next);
|
|
403
|
+
if (result.success === false)
|
|
404
|
+
return result;
|
|
405
|
+
const errors = [];
|
|
406
|
+
const models = props.prismaSchemas.flatMap((schema) => schema.models);
|
|
407
|
+
result.data.content.forEach((op, index) => {
|
|
408
|
+
// Check if summary or description mentions soft delete
|
|
409
|
+
const mentionsSoftDelete = (op.summary && /soft[\s-]?delet/i.test(op.summary)) ||
|
|
410
|
+
(op.description && /soft[\s-]?delet/i.test(op.description));
|
|
411
|
+
if (op.method === "delete") {
|
|
412
|
+
const model = models.find((model) => model.name === op.model_name);
|
|
413
|
+
if (mentionsSoftDelete) {
|
|
414
|
+
// If soft delete is mentioned but no soft_delete_column is specified
|
|
415
|
+
if (!op.soft_delete_column) {
|
|
416
|
+
// Check if any soft-delete capable column exists in the model
|
|
417
|
+
const hasSoftDeleteCapableColumn = model === null || model === void 0 ? void 0 : model.plainFields.some((field) => /delete|deleted|deleted_at|deletedAt|is_deleted|isDeleted/i.test(field.name));
|
|
418
|
+
if (hasSoftDeleteCapableColumn) {
|
|
419
|
+
errors.push({
|
|
420
|
+
expected: `Soft delete column to be specified or summary/description to not mention soft delete`,
|
|
421
|
+
value: "null",
|
|
422
|
+
description: `Mismatch: Operation mentions soft delete but soft_delete_column is not specified, while model has soft-delete capable columns`,
|
|
423
|
+
path: `$input.content[${index}].soft_delete_column`,
|
|
424
|
+
});
|
|
425
|
+
}
|
|
426
|
+
else {
|
|
427
|
+
errors.push({
|
|
428
|
+
expected: `Summary/description to not mention soft delete when model lacks soft-delete capability`,
|
|
429
|
+
value: `${op.summary || ""} ${op.description || ""}`,
|
|
430
|
+
description: `Mismatch: Operation mentions soft delete but model '${op.model_name}' has no soft-delete capable columns`,
|
|
431
|
+
path: `$input.content[${index}].summary || $input.content[${index}].description`,
|
|
432
|
+
});
|
|
433
|
+
}
|
|
434
|
+
}
|
|
435
|
+
else {
|
|
436
|
+
// If soft_delete_column is specified, check if it exists in the model
|
|
437
|
+
const column = model === null || model === void 0 ? void 0 : model.plainFields.find((el) => el.name === op.soft_delete_column);
|
|
438
|
+
if (!column) {
|
|
439
|
+
errors.push({
|
|
440
|
+
expected: `Field '${op.soft_delete_column}' to exist in model or operation to not mention soft delete`,
|
|
441
|
+
value: "undefined",
|
|
442
|
+
description: `Mismatch: Either the field '${op.soft_delete_column}' should exist in model '${op.model_name}', or the operation should not mention soft delete`,
|
|
443
|
+
path: `$input.content[${index}].soft_delete_column || $input.content[${index}].summary || $input.content[${index}].description`,
|
|
444
|
+
});
|
|
445
|
+
}
|
|
446
|
+
}
|
|
447
|
+
}
|
|
448
|
+
// Also check if soft_delete_column is specified without mentioning soft delete
|
|
449
|
+
if (op.soft_delete_column && !mentionsSoftDelete) {
|
|
450
|
+
errors.push({
|
|
451
|
+
expected: `Consistency between soft_delete_column and operation description`,
|
|
452
|
+
value: `soft_delete_column: ${op.soft_delete_column}`,
|
|
453
|
+
description: `Mismatch: soft_delete_column is specified but soft delete is not mentioned in summary/description`,
|
|
454
|
+
path: `$input.content[${index}]`,
|
|
455
|
+
});
|
|
456
|
+
}
|
|
457
|
+
}
|
|
458
|
+
});
|
|
459
|
+
// not implemented
|
|
460
|
+
if (errors.length !== 0) {
|
|
461
|
+
console.log(JSON.stringify(errors, null, 2));
|
|
462
|
+
return {
|
|
463
|
+
success: false,
|
|
464
|
+
errors,
|
|
465
|
+
data: next,
|
|
466
|
+
};
|
|
467
|
+
}
|
|
468
|
+
return result;
|
|
469
|
+
};
|
|
470
|
+
const application = collection[props.model === "chatgpt" ? "chatgpt" : "claude"](validate);
|
|
100
471
|
return {
|
|
101
472
|
protocol: "class",
|
|
102
473
|
name: "review",
|
|
@@ -109,1220 +480,1304 @@ function createReviewController(props) {
|
|
|
109
480
|
};
|
|
110
481
|
}
|
|
111
482
|
const collection = {
|
|
112
|
-
chatgpt: {
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
|
|
127
|
-
|
|
128
|
-
|
|
129
|
-
|
|
130
|
-
|
|
131
|
-
|
|
132
|
-
|
|
133
|
-
|
|
134
|
-
|
|
135
|
-
|
|
136
|
-
|
|
137
|
-
|
|
138
|
-
|
|
483
|
+
chatgpt: (validate) => (() => {
|
|
484
|
+
const application = {
|
|
485
|
+
model: "chatgpt",
|
|
486
|
+
options: {
|
|
487
|
+
reference: true,
|
|
488
|
+
strict: false,
|
|
489
|
+
separate: null
|
|
490
|
+
},
|
|
491
|
+
functions: [
|
|
492
|
+
{
|
|
493
|
+
name: "reviewOperations",
|
|
494
|
+
parameters: {
|
|
495
|
+
description: " Collection of operations to review with their validation\nresults\n\n------------------------------\n\nDescription of the current {@link IAutoBeInterfaceOperationsReviewApplication.IProps} type:\n\n> Properties for API operation review and improvement process.\n> \n> Contains both the input operations to be reviewed and the outputs generated\n> by the Interface Operations Review Agent, which will be published as part\n> of the AutoBeInterfaceOperationsReviewEvent.",
|
|
496
|
+
type: "object",
|
|
497
|
+
properties: {
|
|
498
|
+
review: {
|
|
499
|
+
description: "Comprehensive review analysis with prioritized findings.\n\nSystematic assessment organized by severity levels (CRITICAL, HIGH,\nMEDIUM, LOW):\n\n- **Security Analysis**: Authentication boundary violations, exposed\n passwords/tokens, unauthorized data access patterns, SQL injection\n risks\n- **Logic Validation**: Return type consistency (list operations returning\n arrays, single retrieval returning single items), HTTP method semantics\n alignment, parameter usage verification\n- **Schema Compliance**: Field existence in Prisma schema, type accuracy,\n relationship validity, required field handling\n- **Quality Assessment**: Documentation completeness, naming conventions,\n error handling patterns, pagination standards\n\nEach finding includes specific examples, current vs expected behavior,\nand concrete fix recommendations. Critical security issues and logical\ncontradictions are highlighted for immediate attention.",
|
|
500
|
+
type: "string"
|
|
501
|
+
},
|
|
502
|
+
plan: {
|
|
503
|
+
description: "Prioritized action plan for identified issues.\n\nStructured improvement strategy categorized by severity:\n\n- **Immediate Actions (CRITICAL)**: Security vulnerabilities that must be\n fixed before production (password exposure, missing authorization,\n authentication bypass risks)\n- **Required Fixes (HIGH)**: Functional issues affecting API correctness\n (wrong return types, missing required fields, schema mismatches)\n- **Recommended Improvements (MEDIUM)**: Quality enhancements for better\n API design (validation rules, format specifications, consistency)\n- **Optional Enhancements (LOW)**: Documentation and usability improvements\n\nIf all operations pass review without issues, contains: \"No improvements\nrequired. All operations meet AutoBE standards.\"\n\nEach action item includes the specific operation path, the exact change\nneeded, and the rationale for the modification.",
|
|
504
|
+
type: "string"
|
|
505
|
+
},
|
|
506
|
+
content: {
|
|
507
|
+
description: "Production-ready operations with all critical issues resolved.\n\nFinal API operations after systematic enhancement:\n\n- **Security Fixes Applied**: All authentication boundaries enforced,\n sensitive data removed from responses, proper authorization\n implemented\n- **Logic Corrections Made**: Return types match operation intent, HTTP\n methods align with semantics, parameters properly utilized\n- **Schema Alignment Verified**: All fields exist in Prisma schema, types\n correctly mapped, relationships properly defined\n- **Quality Improvements Added**: Enhanced documentation, format\n specifications, validation rules, consistent naming patterns\n\nIf no issues were found during review, this contains the exact original\noperations unchanged. These operations are validated and ready for schema\ngeneration and subsequent implementation phases.",
|
|
508
|
+
type: "array",
|
|
509
|
+
items: {
|
|
510
|
+
$ref: "#/$defs/IAutoBeInterfaceOperationsReviewApplication.IOperation"
|
|
511
|
+
}
|
|
139
512
|
}
|
|
140
|
-
}
|
|
141
|
-
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
|
|
148
|
-
|
|
149
|
-
|
|
150
|
-
|
|
151
|
-
|
|
152
|
-
|
|
153
|
-
|
|
154
|
-
|
|
155
|
-
|
|
156
|
-
|
|
157
|
-
|
|
158
|
-
|
|
159
|
-
|
|
160
|
-
|
|
161
|
-
|
|
162
|
-
|
|
163
|
-
|
|
164
|
-
|
|
165
|
-
|
|
166
|
-
|
|
167
|
-
|
|
168
|
-
|
|
169
|
-
|
|
170
|
-
|
|
171
|
-
|
|
172
|
-
|
|
173
|
-
|
|
174
|
-
|
|
175
|
-
|
|
176
|
-
|
|
177
|
-
|
|
178
|
-
}
|
|
179
|
-
|
|
180
|
-
|
|
181
|
-
|
|
182
|
-
|
|
183
|
-
|
|
184
|
-
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
}
|
|
189
|
-
|
|
190
|
-
|
|
191
|
-
|
|
192
|
-
|
|
193
|
-
|
|
194
|
-
{
|
|
195
|
-
|
|
196
|
-
},
|
|
197
|
-
{
|
|
198
|
-
$ref: "#/$defs/AutoBeOpenApi.IResponseBody"
|
|
199
|
-
}
|
|
200
|
-
]
|
|
201
|
-
},
|
|
202
|
-
authorizationRole: {
|
|
203
|
-
description: "Authorization role required to access this API operation.\n\nThis field specifies which user role is allowed to access this endpoint.\nThe role name must correspond exactly to the actual roles defined in your\nsystem's Prisma schema.\n\n## Naming Convention\n\nRole names MUST use camelCase.\n\n## Role-Based Path Convention\n\nWhen authorizationRole is specified, it should align with the path\nstructure:\n\n- If authorizationRole is \"admin\" \u2192 path might be \"/admin/resources/{id}\"\n- If authorizationRole is \"seller\" \u2192 path might be \"/seller/products\"\n- Special case: For user's own resources, use path prefix \"/my/\" regardless\n of role\n\n## Important Guidelines\n\n- Set to `null` for public endpoints that require no authentication\n- Set to specific role string for role-restricted endpoints\n- The role name MUST match exactly with the user type/role defined in the\n database\n- This role will be used by the Realize Agent to generate appropriate\n decorator and authorization logic in the provider functions\n- The controller will apply the corresponding authentication decorator\n based on this role\n\n## Examples\n\n- `null` - Public endpoint, no authentication required\n- `\"user\"` - Any authenticated user can access\n- `\"admin\"` - Only admin users can access\n- `\"seller\"` - Only seller users can access\n- `\"moderator\"` - Only moderator users can access\n\nNote: The actual authentication/authorization implementation will be\nhandled by decorators at the controller level, and the provider function\nwill receive the authenticated user object with the appropriate type.",
|
|
204
|
-
anyOf: [
|
|
205
|
-
{
|
|
206
|
-
type: "null"
|
|
207
|
-
},
|
|
208
|
-
{
|
|
209
|
-
type: "string",
|
|
210
|
-
description: "@minLength 1\n@pattern ^[a-z][a-zA-Z0-9]*$"
|
|
513
|
+
},
|
|
514
|
+
required: [
|
|
515
|
+
"review",
|
|
516
|
+
"plan",
|
|
517
|
+
"content"
|
|
518
|
+
],
|
|
519
|
+
additionalProperties: false,
|
|
520
|
+
$defs: {
|
|
521
|
+
"IAutoBeInterfaceOperationsReviewApplication.IOperation": {
|
|
522
|
+
description: "Operation of the Restful API.\n\nThis interface defines a single API endpoint with its HTTP {@link method},\n{@link path}, {@link parameters path parameters},\n{@link requestBody request body}, and {@link responseBody} structure. It\ncorresponds to an individual operation in the paths section of an OpenAPI\ndocument.\n\nEach operation requires a detailed explanation of its purpose through the\nreason and description fields, making it clear why the API was designed and\nhow it should be used.\n\nAll request bodies and responses for this operation must be object types\nand must reference named types defined in the components section. The\ncontent-type is always `application/json`. For file upload/download\noperations, use `string & tags.Format<\"uri\">` in the appropriate schema\ninstead of binary data formats.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"/shoppings/customers/orders\": {\n \"post\": {\n \"description\": \"Create a new order application from shopping cart...\",\n \"parameters\": [...],\n \"requestBody\": {...},\n \"responses\": {...}\n }\n }\n}\n```",
|
|
523
|
+
type: "object",
|
|
524
|
+
properties: {
|
|
525
|
+
prisma_schemas: {
|
|
526
|
+
description: "Prisma schema models relevant to this operation.\n\nContains the complete Prisma schema definitions for all entities involved\nin this operation, including their fields, relations, and database\nconstraints. This enables comprehensive validation and schema-aware\noperation design.\n\nThe schema information serves multiple critical purposes:\n\n- **Field Verification**: Ensures all referenced fields actually exist in\n the database schema and have the correct types\n- **Relationship Validation**: Confirms that entity relationships are\n properly defined and can support the operation's data access patterns\n- **Soft-Delete Detection**: For DELETE operations, identifies whether\n entities have soft-delete fields (deleted_at, is_deleted, etc.) to\n determine if the operation should perform logical deletion instead of\n physical removal\n- **Constraint Awareness**: Understands unique constraints, required\n fields, and default values to generate accurate request/response\n schemas\n\nExample content might include:\n\n```prisma\nmodel User {\n id String",
|
|
527
|
+
type: "string"
|
|
528
|
+
},
|
|
529
|
+
model_name: {
|
|
530
|
+
description: "Primary Prisma model name for this operation.\n\nIdentifies the main database table/model that this operation targets.\nThis must match exactly with the Prisma model name defined in the schema.\nWhen soft deletion is specified, this model name indicates which table\nshould be soft-deleted.\n\nFor example:\n- In a \"GET /users/:id\" operation, this would be \"User\"\n- In a \"POST /articles\" operation, this would be \"Article\"\n- In a \"DELETE /comments/:id\" with soft delete, this specifies the \"Comment\" model to soft-delete\n\nThis property is essential for:\n- Determining the primary entity for CRUD operations\n- Identifying which table to apply soft deletion to\n- Validating operations against the correct Prisma model\n- Generating appropriate database queries and validations",
|
|
531
|
+
type: "string"
|
|
532
|
+
},
|
|
533
|
+
soft_delete_column: {
|
|
534
|
+
description: "Soft delete column name for the Prisma models.\n\nSpecifies the column name used for soft deletion in the database tables\nassociated with this operation. When set to a non-null value, it indicates\nthat the related entities support soft deletion through this column\n(typically a timestamp field like `deleted_at` or `deletedAt`).\n\nWhen null, it means the entities involved in this operation use hard\ndeletion or don't support deletion at all. This information is crucial\nfor generating appropriate CRUD operations and ensuring data integrity\npolicies are correctly implemented.\n\nCommon soft delete patterns:\n- `\"deleted_at\"`: Records deletion timestamp\n- `\"deletedAt\"`: Camel-cased deletion timestamp\n- `\"is_deleted\"`: Boolean flag for deletion status\n- `null`: No soft deletion (hard delete only)",
|
|
535
|
+
anyOf: [
|
|
536
|
+
{
|
|
537
|
+
type: "null"
|
|
538
|
+
},
|
|
539
|
+
{
|
|
540
|
+
type: "string"
|
|
541
|
+
}
|
|
542
|
+
]
|
|
543
|
+
},
|
|
544
|
+
description: {
|
|
545
|
+
description: "Detailed description about the API operation.\n\nIMPORTANT: This field MUST be extensively detailed and MUST reference the\ndescription comments from the related Prisma DB schema tables and\ncolumns. The description should be organized into MULTIPLE PARAGRAPHS\nseparated by line breaks to improve readability and comprehension.\n\nFor example, include separate paragraphs for:\n\n- The purpose and overview of the API operation\n- Security considerations and user permissions\n- Relationship to underlying database entities\n- Validation rules and business logic\n- Related API operations that might be used together with this one\n- Expected behavior and error handling\n\nWhen writing the description, be sure to incorporate the corresponding DB\nschema's description comments, matching the level of detail and style of\nthose comments. This ensures consistency between the API documentation\nand database structure.\n\nIf there's a dependency to other APIs, please describe the dependency API\noperation in this field with detailed reason. For example, if this API\noperation needs a pre-execution of other API operation, it must be\nexplicitly described.\n\n- `GET /shoppings/customers/sales` must be pre-executed to get entire list\n of summarized sales. Detailed sale information would be obtained by\n specifying the sale ID in the path parameter.\n\n**CRITICAL WARNING about soft delete keywords**:\nDO NOT use terms like \"soft delete\", \"soft-delete\", or similar variations\nin this description UNLESS the operation actually implements soft deletion.\nThese keywords trigger validation logic that expects a corresponding\nsoft_delete_column to be specified. Only use these terms when you intend\nto implement soft deletion (marking records as deleted without removing\nthem from the database).\n\nExample of problematic description:\n\u274C \"This would normally be a soft-delete, but we intentionally perform\npermanent deletion here\" - This triggers soft delete validation despite\nbeing a hard delete operation.\n\n> MUST be written in English. Never use other languages.",
|
|
546
|
+
type: "string"
|
|
547
|
+
},
|
|
548
|
+
name: {
|
|
549
|
+
description: "Functional name of the API endpoint.\n\nThis is a semantic identifier that represents the primary function or\npurpose of the API endpoint. It serves as a canonical name that can be\nused for code generation, SDK method names, and internal references.\n\n## Reserved Word Restrictions\n\nCRITICAL: The name MUST NOT be a TypeScript/JavaScript reserved word, as\nit will be used as a class method name in generated code. Avoid names\nlike:\n\n- `delete`, `for`, `if`, `else`, `while`, `do`, `switch`, `case`, `break`\n- `continue`, `function`, `return`, `with`, `in`, `of`, `instanceof`\n- `typeof`, `void`, `var`, `let`, `const`, `class`, `extends`, `import`\n- `export`, `default`, `try`, `catch`, `finally`, `throw`, `new`\n- `super`, `this`, `null`, `true`, `false`, `async`, `await`\n- `yield`, `static`, `private`, `protected`, `public`, `implements`\n- `interface`, `package`, `enum`, `debugger`\n\nInstead, use alternative names for these operations:\n\n- Use `erase` instead of `delete`\n- Use `iterate` instead of `for`\n- Use `when` instead of `if`\n- Use `cls` instead of `class`\n\n## Standard Endpoint Names\n\nUse these conventional names based on the endpoint's primary function:\n\n- **`index`**: List/search operations that return multiple entities\n\n - Typically used with PATCH method for complex queries\n - Example: `PATCH /users` \u2192 `name: \"index\"`\n- **`at`**: Retrieve a specific entity by identifier\n\n - Typically used with GET method on single resource\n - Example: `GET /users/{userId}` \u2192 `name: \"at\"`\n- **`create`**: Create a new entity\n\n - Typically used with POST method\n - Example: `POST /users` \u2192 `name: \"create\"`\n- **`update`**: Update an existing entity\n\n - Typically used with PUT method\n - Example: `PUT /users/{userId}` \u2192 `name: \"update\"`\n- **`erase`**: Delete/remove an entity (NOT `delete` - reserved word!)\n\n - Typically used with DELETE method\n - Example: `DELETE /users/{userId}` \u2192 `name: \"erase\"`\n\n## Custom Endpoint Names\n\nFor specialized operations beyond basic CRUD, use descriptive verbs:\n\n- **`activate`**: Enable or turn on a feature/entity\n- **`deactivate`**: Disable or turn off a feature/entity\n- **`approve`**: Approve a request or entity\n- **`reject`**: Reject a request or entity\n- **`publish`**: Make content publicly available\n- **`archive`**: Move to archived state\n- **`restore`**: Restore from archived/deleted state\n- **`duplicate`**: Create a copy of an entity\n- **`transfer`**: Move ownership or change assignment\n- **`validate`**: Validate data or state\n- **`process`**: Execute a business process or workflow\n- **`export`**: Generate downloadable data\n- **`import`**: Process uploaded data\n\n## Naming Guidelines\n\n- MUST use camelCase naming convention\n- Use singular verb forms\n- Be concise but descriptive\n- Avoid abbreviations unless widely understood\n- Ensure the name clearly represents the endpoint's primary action\n- For nested resources, focus on the action rather than hierarchy\n- NEVER use JavaScript/TypeScript reserved words\n\nValid Examples:\n\n- `index`, `create`, `update`, `erase` (single word)\n- `updatePassword`, `cancelOrder`, `publishArticle` (camelCase)\n- `validateEmail`, `generateReport`, `exportData` (camelCase)\n\nInvalid Examples:\n\n- `update_password` (snake_case not allowed)\n- `UpdatePassword` (PascalCase not allowed)\n- `update-password` (kebab-case not allowed)\n\nPath to Name Examples:\n\n- `GET /shopping/orders/{orderId}/items` \u2192 `name: \"index\"` (lists items)\n- `POST /shopping/orders/{orderId}/cancel` \u2192 `name: \"cancel\"`\n- `PUT /users/{userId}/password` \u2192 `name: \"updatePassword\"`\n\n## Uniqueness Rule\n\nThe `name` must be unique within the API's accessor namespace. The\naccessor is formed by combining the path segments (excluding parameters)\nwith the operation name.\n\nAccessor formation:\n\n1. Extract non-parameter segments from the path (remove `{...}` parts)\n2. Join segments with dots\n3. Append the operation name\n\nExamples:\n\n- Path: `/shopping/sale/{saleId}/review/{reviewId}`, Name: `at` \u2192 Accessor:\n `shopping.sale.review.at`\n- Path: `/users/{userId}/posts`, Name: `index` \u2192 Accessor:\n `users.posts.index`\n- Path: `/auth/login`, Name: `signIn` \u2192 Accessor: `auth.login.signIn`\n\nEach accessor must be globally unique across the entire API. This ensures\noperations can be uniquely identified in generated SDKs and prevents\nnaming conflicts.\n\n\n@pattern ^[a-z][a-zA-Z0-9]*$",
|
|
550
|
+
type: "string"
|
|
551
|
+
},
|
|
552
|
+
specification: {
|
|
553
|
+
description: "Specification of the API operation.\n\nBefore defining the API operation interface, please describe what you're\nplanning to write in this `specification` field.\n\nThe specification must be fully detailed and clear, so that anyone can\nunderstand the purpose and functionality of the API operation and its\nrelated components (e.g., {@link path}, {@link parameters},\n{@link requestBody}).\n\nIMPORTANT: The specification MUST identify which Prisma DB table this\noperation is associated with, helping ensure complete coverage of all\ndatabase entities.",
|
|
554
|
+
type: "string"
|
|
555
|
+
},
|
|
556
|
+
summary: {
|
|
557
|
+
description: "Short summary of the API operation.\n\nThis should be a concise description of the API operation, typically one\nsentence long. It should provide a quick overview of what the API does\nwithout going into too much detail.\n\nThis summary will be used in the OpenAPI documentation to give users a\nquick understanding of the API operation's purpose.\n\nIMPORTANT: The summary should clearly indicate which Prisma DB table this\noperation relates to, helping to ensure all tables have API coverage.\n\n**CRITICAL WARNING about soft delete keywords**:\nDO NOT use terms like \"soft delete\", \"soft-delete\", or similar variations\nin this summary UNLESS the operation actually implements soft deletion.\nThese keywords trigger validation logic that expects a corresponding\nsoft_delete_column to be specified. Only use these terms when you intend\nto implement soft deletion (marking records as deleted without removing\nthem from the database).\n\n> MUST be written in English. Never use other languages",
|
|
558
|
+
type: "string"
|
|
559
|
+
},
|
|
560
|
+
path: {
|
|
561
|
+
description: "HTTP path of the API operation.\n\nThe URL path for accessing this API operation, using path parameters\nenclosed in curly braces (e.g., `/shoppings/customers/sales/{saleId}`).\n\nIt must be corresponded to the {@link parameters path parameters}.\n\nThe path structure should clearly indicate which database entity this\noperation is manipulating, helping to ensure all entities have\nappropriate API coverage.\n\nPath validation rules:\n\n- Must start with a forward slash (/)\n- Can contain only: letters (a-z, A-Z), numbers (0-9), forward slashes (/),\n curly braces for parameters ({paramName}), hyphens (-), and underscores\n (_)\n- Parameters must be enclosed in curly braces: {paramName}\n- Resource names should be in camelCase\n- No quotes, spaces, or invalid special characters allowed\n- No domain or role-based prefixes\n\nValid examples:\n\n- \"/users\"\n- \"/users/{userId}\"\n- \"/articles/{articleId}/comments\"\n- \"/attachmentFiles\"\n- \"/orders/{orderId}/items/{itemId}\"\n\nInvalid examples:\n\n- \"'/users'\" (contains quotes)\n- \"/user profile\" (contains space)\n- \"/users/[userId]\" (wrong bracket format)\n- \"/admin/users\" (role prefix)\n- \"/api/v1/users\" (API prefix)\n\n\n@pattern ^\\/[a-zA-Z0-9\\/_{}.-]*$",
|
|
562
|
+
type: "string"
|
|
563
|
+
},
|
|
564
|
+
parameters: {
|
|
565
|
+
description: "List of path parameters.\n\nNote that, the {@link AutoBeOpenApi.IParameter.name identifier name} of\npath parameter must be corresponded to the\n{@link path API operation path}.\n\nFor example, if there's an API operation which has {@link path} of\n`/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}`,\nits list of {@link AutoBeOpenApi.IParameter.name path parameters} must be\nlike:\n\n- `saleId`\n- `questionId`\n- `commentId`",
|
|
566
|
+
type: "array",
|
|
567
|
+
items: {
|
|
568
|
+
$ref: "#/$defs/AutoBeOpenApi.IParameter"
|
|
211
569
|
}
|
|
212
|
-
|
|
570
|
+
},
|
|
571
|
+
requestBody: {
|
|
572
|
+
description: "Request body of the API operation.\n\nDefines the payload structure for the request. Contains a description and\nschema reference to define the expected input data.\n\nShould be `null` for operations that don't require a request body, such\nas most \"get\" operations.",
|
|
573
|
+
anyOf: [
|
|
574
|
+
{
|
|
575
|
+
type: "null"
|
|
576
|
+
},
|
|
577
|
+
{
|
|
578
|
+
$ref: "#/$defs/AutoBeOpenApi.IRequestBody"
|
|
579
|
+
}
|
|
580
|
+
]
|
|
581
|
+
},
|
|
582
|
+
responseBody: {
|
|
583
|
+
description: "Response body of the API operation.\n\nDefines the structure of the successful response data. Contains a\ndescription and schema reference for the returned data.\n\nShould be null for operations that don't return any data.",
|
|
584
|
+
anyOf: [
|
|
585
|
+
{
|
|
586
|
+
type: "null"
|
|
587
|
+
},
|
|
588
|
+
{
|
|
589
|
+
$ref: "#/$defs/AutoBeOpenApi.IResponseBody"
|
|
590
|
+
}
|
|
591
|
+
]
|
|
592
|
+
},
|
|
593
|
+
authorizationRole: {
|
|
594
|
+
description: "Authorization role required to access this API operation.\n\nThis field specifies which user role is allowed to access this endpoint.\nThe role name must correspond exactly to the actual roles defined in your\nsystem's Prisma schema.\n\n## Naming Convention\n\nRole names MUST use camelCase.\n\n## Role-Based Path Convention\n\nWhen authorizationRole is specified, it should align with the path\nstructure:\n\n- If authorizationRole is \"admin\" \u2192 path might be \"/admin/resources/{id}\"\n- If authorizationRole is \"seller\" \u2192 path might be \"/seller/products\"\n- Special case: For user's own resources, use path prefix \"/my/\" regardless\n of role\n\n## Important Guidelines\n\n- Set to `null` for public endpoints that require no authentication\n- Set to specific role string for role-restricted endpoints\n- The role name MUST match exactly with the user type/role defined in the\n database\n- This role will be used by the Realize Agent to generate appropriate\n decorator and authorization logic in the provider functions\n- The controller will apply the corresponding authentication decorator\n based on this role\n\n## Examples\n\n- `null` - Public endpoint, no authentication required\n- `\"user\"` - Any authenticated user can access\n- `\"admin\"` - Only admin users can access\n- `\"seller\"` - Only seller users can access\n- `\"moderator\"` - Only moderator users can access\n\nNote: The actual authentication/authorization implementation will be\nhandled by decorators at the controller level, and the provider function\nwill receive the authenticated user object with the appropriate type.",
|
|
595
|
+
anyOf: [
|
|
596
|
+
{
|
|
597
|
+
type: "null"
|
|
598
|
+
},
|
|
599
|
+
{
|
|
600
|
+
type: "string",
|
|
601
|
+
description: "@minLength 1\n@pattern ^[a-z][a-zA-Z0-9]*$"
|
|
602
|
+
}
|
|
603
|
+
]
|
|
604
|
+
},
|
|
605
|
+
method: {
|
|
606
|
+
description: "HTTP method of the API operation.\n\n**IMPORTANT**: Methods must be written in lowercase only (e.g., \"get\", not \"GET\").\n\nNote that, if the API operation has {@link requestBody}, method must not\nbe `get`.\n\nAlso, even though the API operation has been designed to only get\ninformation, but it needs complicated request information, it must be\ndefined as `patch` method with {@link requestBody} data specification.\n\n- `get`: get information\n- `patch`: get information with complicated request data\n ({@link requestBody})\n- `post`: create new record\n- `put`: update existing record\n- `delete`: remove record",
|
|
607
|
+
type: "string",
|
|
608
|
+
"enum": [
|
|
609
|
+
"get",
|
|
610
|
+
"post",
|
|
611
|
+
"put",
|
|
612
|
+
"delete",
|
|
613
|
+
"patch"
|
|
614
|
+
]
|
|
615
|
+
}
|
|
213
616
|
},
|
|
214
|
-
|
|
215
|
-
|
|
216
|
-
|
|
217
|
-
"
|
|
218
|
-
|
|
219
|
-
|
|
220
|
-
|
|
221
|
-
|
|
222
|
-
|
|
223
|
-
|
|
224
|
-
|
|
617
|
+
required: [
|
|
618
|
+
"prisma_schemas",
|
|
619
|
+
"model_name",
|
|
620
|
+
"soft_delete_column",
|
|
621
|
+
"description",
|
|
622
|
+
"name",
|
|
623
|
+
"specification",
|
|
624
|
+
"summary",
|
|
625
|
+
"path",
|
|
626
|
+
"parameters",
|
|
627
|
+
"requestBody",
|
|
628
|
+
"responseBody",
|
|
629
|
+
"authorizationRole",
|
|
630
|
+
"method"
|
|
631
|
+
]
|
|
225
632
|
},
|
|
226
|
-
|
|
227
|
-
"description",
|
|
228
|
-
"
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
242
|
-
|
|
243
|
-
|
|
244
|
-
|
|
245
|
-
|
|
246
|
-
|
|
247
|
-
|
|
248
|
-
|
|
249
|
-
|
|
250
|
-
|
|
251
|
-
|
|
252
|
-
|
|
253
|
-
|
|
254
|
-
|
|
255
|
-
|
|
256
|
-
|
|
257
|
-
|
|
258
|
-
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger"
|
|
259
|
-
},
|
|
260
|
-
{
|
|
261
|
-
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
262
|
-
}
|
|
263
|
-
],
|
|
264
|
-
"x-discriminator": {
|
|
265
|
-
propertyName: "type",
|
|
266
|
-
mapping: {
|
|
267
|
-
number: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber",
|
|
268
|
-
integer: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger",
|
|
269
|
-
string: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
633
|
+
"AutoBeOpenApi.IParameter": {
|
|
634
|
+
description: "Path parameter information for API routes.\n\nThis interface defines a path parameter that appears in the URL of an API\nendpoint. Path parameters are enclosed in curly braces in the\n{@link AutoBeOpenApi.IOperation.path operation path} and must be defined\nwith their types and descriptions.\n\nFor example, if API operation path is\n`/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}`,\nthe path parameters should be like below:\n\n```json\n{\n \"path\": \"/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}\",\n \"method\": \"get\",\n \"parameters\": [\n {\n \"name\": \"saleId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target sale's ID\"\n },\n {\n \"name\": \"questionId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target question's ID\"\n },\n {\n \"name\": \"commentId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target comment's ID\"\n }\n ]\n}\n```",
|
|
635
|
+
type: "object",
|
|
636
|
+
properties: {
|
|
637
|
+
name: {
|
|
638
|
+
description: "Identifier name of the path parameter.\n\nThis name must match exactly with the parameter name in the route path.\nIt must be corresponded to the\n{@link AutoBeOpenApi.IOperation.path API operation path}.\n\nMUST use camelCase naming convention.\n\n\n@pattern ^[a-z][a-zA-Z0-9]*$",
|
|
639
|
+
type: "string"
|
|
640
|
+
},
|
|
641
|
+
description: {
|
|
642
|
+
description: "Description about the path parameter.\n\nMake short, concise and clear description about the path parameter.\n\n> MUST be written in English. Never use other languages.",
|
|
643
|
+
type: "string"
|
|
644
|
+
},
|
|
645
|
+
schema: {
|
|
646
|
+
description: "Type schema of the path parameter.\n\nPath parameters are typically primitive types like\n{@link AutoBeOpenApi.IJsonSchema.IString strings},\n{@link AutoBeOpenApi.IJsonSchema.IInteger integers},\n{@link AutoBeOpenApi.IJsonSchema.INumber numbers}.\n\nIf you need other types, please use request body instead with object type\nencapsulation.",
|
|
647
|
+
anyOf: [
|
|
648
|
+
{
|
|
649
|
+
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber"
|
|
650
|
+
},
|
|
651
|
+
{
|
|
652
|
+
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger"
|
|
653
|
+
},
|
|
654
|
+
{
|
|
655
|
+
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
656
|
+
}
|
|
657
|
+
],
|
|
658
|
+
"x-discriminator": {
|
|
659
|
+
propertyName: "type",
|
|
660
|
+
mapping: {
|
|
661
|
+
number: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber",
|
|
662
|
+
integer: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger",
|
|
663
|
+
string: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
664
|
+
}
|
|
270
665
|
}
|
|
271
666
|
}
|
|
272
|
-
}
|
|
273
|
-
},
|
|
274
|
-
required: [
|
|
275
|
-
"name",
|
|
276
|
-
"description",
|
|
277
|
-
"schema"
|
|
278
|
-
]
|
|
279
|
-
},
|
|
280
|
-
"AutoBeOpenApi.IJsonSchema.INumber": {
|
|
281
|
-
description: "Number (double) type info.",
|
|
282
|
-
type: "object",
|
|
283
|
-
properties: {
|
|
284
|
-
minimum: {
|
|
285
|
-
description: "Minimum value restriction.",
|
|
286
|
-
type: "number"
|
|
287
|
-
},
|
|
288
|
-
maximum: {
|
|
289
|
-
description: "Maximum value restriction.",
|
|
290
|
-
type: "number"
|
|
291
|
-
},
|
|
292
|
-
exclusiveMinimum: {
|
|
293
|
-
description: "Exclusive minimum value restriction.",
|
|
294
|
-
type: "number"
|
|
295
|
-
},
|
|
296
|
-
exclusiveMaximum: {
|
|
297
|
-
description: "Exclusive maximum value restriction.",
|
|
298
|
-
type: "number"
|
|
299
|
-
},
|
|
300
|
-
multipleOf: {
|
|
301
|
-
description: "Multiple of value restriction.\n\n\n@exclusiveMinimum 0",
|
|
302
|
-
type: "number"
|
|
303
667
|
},
|
|
304
|
-
|
|
305
|
-
|
|
306
|
-
|
|
307
|
-
"
|
|
308
|
-
|
|
309
|
-
]
|
|
310
|
-
}
|
|
668
|
+
required: [
|
|
669
|
+
"name",
|
|
670
|
+
"description",
|
|
671
|
+
"schema"
|
|
672
|
+
]
|
|
311
673
|
},
|
|
312
|
-
|
|
313
|
-
"type"
|
|
314
|
-
|
|
315
|
-
|
|
316
|
-
|
|
317
|
-
|
|
318
|
-
|
|
319
|
-
|
|
320
|
-
|
|
321
|
-
|
|
322
|
-
|
|
323
|
-
|
|
324
|
-
|
|
325
|
-
|
|
326
|
-
|
|
327
|
-
|
|
328
|
-
|
|
329
|
-
|
|
330
|
-
|
|
331
|
-
|
|
332
|
-
|
|
333
|
-
|
|
334
|
-
|
|
335
|
-
|
|
336
|
-
|
|
337
|
-
|
|
338
|
-
|
|
674
|
+
"AutoBeOpenApi.IJsonSchema.INumber": {
|
|
675
|
+
description: "Number (double) type info.",
|
|
676
|
+
type: "object",
|
|
677
|
+
properties: {
|
|
678
|
+
minimum: {
|
|
679
|
+
description: "Minimum value restriction.",
|
|
680
|
+
type: "number"
|
|
681
|
+
},
|
|
682
|
+
maximum: {
|
|
683
|
+
description: "Maximum value restriction.",
|
|
684
|
+
type: "number"
|
|
685
|
+
},
|
|
686
|
+
exclusiveMinimum: {
|
|
687
|
+
description: "Exclusive minimum value restriction.",
|
|
688
|
+
type: "number"
|
|
689
|
+
},
|
|
690
|
+
exclusiveMaximum: {
|
|
691
|
+
description: "Exclusive maximum value restriction.",
|
|
692
|
+
type: "number"
|
|
693
|
+
},
|
|
694
|
+
multipleOf: {
|
|
695
|
+
description: "Multiple of value restriction.\n\n\n@exclusiveMinimum 0",
|
|
696
|
+
type: "number"
|
|
697
|
+
},
|
|
698
|
+
type: {
|
|
699
|
+
description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
|
|
700
|
+
type: "string",
|
|
701
|
+
"enum": [
|
|
702
|
+
"number"
|
|
703
|
+
]
|
|
704
|
+
}
|
|
339
705
|
},
|
|
340
|
-
|
|
341
|
-
|
|
342
|
-
|
|
343
|
-
"enum": [
|
|
344
|
-
"integer"
|
|
345
|
-
]
|
|
346
|
-
}
|
|
706
|
+
required: [
|
|
707
|
+
"type"
|
|
708
|
+
]
|
|
347
709
|
},
|
|
348
|
-
|
|
349
|
-
"type"
|
|
350
|
-
|
|
351
|
-
|
|
352
|
-
|
|
353
|
-
|
|
354
|
-
|
|
355
|
-
|
|
356
|
-
|
|
357
|
-
|
|
358
|
-
|
|
359
|
-
|
|
360
|
-
|
|
361
|
-
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
370
|
-
|
|
371
|
-
|
|
372
|
-
|
|
373
|
-
|
|
374
|
-
|
|
710
|
+
"AutoBeOpenApi.IJsonSchema.IInteger": {
|
|
711
|
+
description: "Integer type info.",
|
|
712
|
+
type: "object",
|
|
713
|
+
properties: {
|
|
714
|
+
minimum: {
|
|
715
|
+
description: "Minimum value restriction.",
|
|
716
|
+
type: "integer"
|
|
717
|
+
},
|
|
718
|
+
maximum: {
|
|
719
|
+
description: "Maximum value restriction.",
|
|
720
|
+
type: "integer"
|
|
721
|
+
},
|
|
722
|
+
exclusiveMinimum: {
|
|
723
|
+
description: "Exclusive minimum value restriction.",
|
|
724
|
+
type: "number"
|
|
725
|
+
},
|
|
726
|
+
exclusiveMaximum: {
|
|
727
|
+
description: "Exclusive maximum value restriction.",
|
|
728
|
+
type: "number"
|
|
729
|
+
},
|
|
730
|
+
multipleOf: {
|
|
731
|
+
description: "Multiple of value restriction.\n\n\n@exclusiveMinimum 0",
|
|
732
|
+
type: "integer"
|
|
733
|
+
},
|
|
734
|
+
type: {
|
|
735
|
+
description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
|
|
736
|
+
type: "string",
|
|
737
|
+
"enum": [
|
|
738
|
+
"integer"
|
|
739
|
+
]
|
|
740
|
+
}
|
|
375
741
|
},
|
|
376
|
-
|
|
377
|
-
|
|
378
|
-
|
|
379
|
-
"enum": [
|
|
380
|
-
"string"
|
|
381
|
-
]
|
|
382
|
-
}
|
|
742
|
+
required: [
|
|
743
|
+
"type"
|
|
744
|
+
]
|
|
383
745
|
},
|
|
384
|
-
|
|
385
|
-
"type"
|
|
386
|
-
|
|
387
|
-
|
|
388
|
-
|
|
389
|
-
|
|
390
|
-
|
|
391
|
-
|
|
392
|
-
|
|
393
|
-
|
|
394
|
-
|
|
746
|
+
"AutoBeOpenApi.IJsonSchema.IString": {
|
|
747
|
+
description: "String type info.",
|
|
748
|
+
type: "object",
|
|
749
|
+
properties: {
|
|
750
|
+
format: {
|
|
751
|
+
description: "Format restriction.",
|
|
752
|
+
type: "string"
|
|
753
|
+
},
|
|
754
|
+
pattern: {
|
|
755
|
+
description: "Pattern restriction.",
|
|
756
|
+
type: "string"
|
|
757
|
+
},
|
|
758
|
+
contentMediaType: {
|
|
759
|
+
description: "Content media type restriction.",
|
|
760
|
+
type: "string"
|
|
761
|
+
},
|
|
762
|
+
minLength: {
|
|
763
|
+
description: "Minimum length restriction.\n\n\n@minimum 0",
|
|
764
|
+
type: "integer"
|
|
765
|
+
},
|
|
766
|
+
maxLength: {
|
|
767
|
+
description: "Maximum length restriction.\n\n\n@minimum 0",
|
|
768
|
+
type: "integer"
|
|
769
|
+
},
|
|
770
|
+
type: {
|
|
771
|
+
description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
|
|
772
|
+
type: "string",
|
|
773
|
+
"enum": [
|
|
774
|
+
"string"
|
|
775
|
+
]
|
|
776
|
+
}
|
|
395
777
|
},
|
|
396
|
-
|
|
397
|
-
|
|
398
|
-
|
|
399
|
-
}
|
|
778
|
+
required: [
|
|
779
|
+
"type"
|
|
780
|
+
]
|
|
400
781
|
},
|
|
401
|
-
|
|
402
|
-
"description",
|
|
403
|
-
"
|
|
404
|
-
|
|
405
|
-
|
|
406
|
-
|
|
407
|
-
|
|
408
|
-
|
|
409
|
-
|
|
410
|
-
|
|
411
|
-
|
|
412
|
-
|
|
782
|
+
"AutoBeOpenApi.IRequestBody": {
|
|
783
|
+
description: "Request body information of OpenAPI operation.\n\nThis interface defines the structure for request bodies in API routes. It\ncorresponds to the requestBody section in OpenAPI specifications, providing\nboth a description and schema reference for the request payload.\n\nThe content-type for all request bodies is always `application/json`. Even\nwhen file uploading is required, don't use `multipart/form-data` or\n`application/x-www-form-urlencoded` content types. Instead, just define an\nURI string property in the request body schema.\n\nNote that, all body schemas must be transformable to a\n{@link AutoBeOpenApi.IJsonSchema.IReference reference} type defined in the\n{@link AutoBeOpenApi.IComponents.schemas components section} as an\n{@link AutoBeOpenApi.IJsonSchema.IObject object} type.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"requestBody\": {\n \"description\": \"Creation info of the order\",\n \"content\": {\n \"application/json\": {\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder.ICreate\"\n }\n }\n }\n }\n}\n```",
|
|
784
|
+
type: "object",
|
|
785
|
+
properties: {
|
|
786
|
+
description: {
|
|
787
|
+
description: "Description about the request body.\n\nMake short, concise and clear description about the request body.\n\n> MUST be written in English. Never use other languages.",
|
|
788
|
+
type: "string"
|
|
789
|
+
},
|
|
790
|
+
typeName: {
|
|
791
|
+
description: "Request body type name.\n\nThis specifies the data structure expected in the request body, that will\nbe transformed to {@link AutoBeOpenApi.IJsonSchema.IReference reference}\ntype in the {@link AutoBeOpenApi.IComponents.schemas components section}\nas an {@link AutoBeOpenApi.IJsonSchema.Object object} type.\n\nHere is the naming convention for the request body type:\n\n- `IEntityName.ICreate`: Request body for creation operations (POST)\n- `IEntityName.IUpdate`: Request body for update operations (PUT)\n- `IEntityName.IRequest`: Request parameters for list operations (often\n with search/pagination)\n\nWhat you write:\n\n```json\n{\n \"typeName\": \"IShoppingOrder.ICreate\"\n}\n```\n\nTransformed to:\n\n```json\n{\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder.ICreate\"\n }\n}\n```",
|
|
792
|
+
type: "string"
|
|
793
|
+
}
|
|
413
794
|
},
|
|
414
|
-
|
|
415
|
-
description
|
|
416
|
-
|
|
417
|
-
|
|
795
|
+
required: [
|
|
796
|
+
"description",
|
|
797
|
+
"typeName"
|
|
798
|
+
]
|
|
418
799
|
},
|
|
419
|
-
|
|
420
|
-
"description",
|
|
421
|
-
"
|
|
422
|
-
|
|
800
|
+
"AutoBeOpenApi.IResponseBody": {
|
|
801
|
+
description: "Response body information for OpenAPI operation.\n\nThis interface defines the structure of a successful response from an API\noperation. It provides a description of the response and a schema reference\nto define the returned data structure.\n\nThe content-type for all responses is always `application/json`. Even when\nfile downloading is required, don't use `application/octet-stream` or\n`multipart/form-data` content types. Instead, just define an URI string\nproperty in the response body schema.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"responses\": {\n \"200\": {\n \"description\": \"Order information\",\n \"content\": {\n \"application/json\": {\n \"schema\": { \"$ref\": \"#/components/schemas/IShoppingOrder\" }\n }\n }\n }\n }\n}\n```",
|
|
802
|
+
type: "object",
|
|
803
|
+
properties: {
|
|
804
|
+
description: {
|
|
805
|
+
description: "Description about the response body.\n\nMake short, concise and clear description about the response body.\n\n> MUST be written in English. Never use other languages.",
|
|
806
|
+
type: "string"
|
|
807
|
+
},
|
|
808
|
+
typeName: {
|
|
809
|
+
description: "Response body's data type.\n\nSpecifies the structure of the returned data (response body), that will\nbe transformed to {@link AutoBeOpenApi.IJsonSchema.IReference} type in the\n{@link AutoBeOpenApi.IComponents.schemas components section} as an\n{@link AutoBeOpenApi.IJsonSchema.IObject object} type.\n\nHere is the naming convention for the response body type:\n\n- `IEntityName`: Main entity with detailed information (e.g.,\n `IShoppingSale`)\n- `IEntityName.ISummary`: Simplified response version with essential\n properties\n- `IEntityName.IInvert`: Alternative view of an entity from a different\n perspective\n- `IPageIEntityName`: Paginated results container with `pagination` and\n `data` properties\n\nWhat you write:\n\n```json\n{\n \"typeName\": \"IShoppingOrder\"\n}\n```\n\nTransformed to:\n\n```json\n{\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder\"\n }\n}\n```",
|
|
810
|
+
type: "string"
|
|
811
|
+
}
|
|
812
|
+
},
|
|
813
|
+
required: [
|
|
814
|
+
"description",
|
|
815
|
+
"typeName"
|
|
816
|
+
]
|
|
817
|
+
}
|
|
423
818
|
}
|
|
424
|
-
}
|
|
425
|
-
|
|
426
|
-
|
|
427
|
-
|
|
428
|
-
|
|
429
|
-
|
|
430
|
-
|
|
431
|
-
|
|
432
|
-
|
|
433
|
-
|
|
434
|
-
|
|
435
|
-
|
|
436
|
-
|
|
437
|
-
|
|
438
|
-
|
|
439
|
-
|
|
440
|
-
|
|
441
|
-
|
|
442
|
-
|
|
443
|
-
|
|
444
|
-
|
|
445
|
-
|
|
446
|
-
|
|
447
|
-
|
|
448
|
-
|
|
449
|
-
|
|
450
|
-
|
|
451
|
-
|
|
452
|
-
|
|
453
|
-
|
|
454
|
-
|
|
455
|
-
|
|
456
|
-
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
|
|
462
|
-
|
|
463
|
-
|
|
464
|
-
|
|
465
|
-
|
|
466
|
-
|
|
467
|
-
|
|
468
|
-
|
|
469
|
-
|
|
470
|
-
|
|
471
|
-
|
|
472
|
-
|
|
473
|
-
|
|
474
|
-
|
|
475
|
-
|
|
476
|
-
|
|
477
|
-
|
|
478
|
-
|
|
479
|
-
|
|
480
|
-
|
|
481
|
-
|
|
482
|
-
|
|
483
|
-
|
|
484
|
-
|
|
485
|
-
|
|
486
|
-
|
|
487
|
-
|
|
488
|
-
|
|
489
|
-
|
|
490
|
-
|
|
491
|
-
|
|
492
|
-
|
|
493
|
-
|
|
494
|
-
|
|
495
|
-
|
|
496
|
-
|
|
497
|
-
|
|
498
|
-
|
|
499
|
-
|
|
500
|
-
|
|
501
|
-
|
|
502
|
-
|
|
503
|
-
|
|
504
|
-
|
|
505
|
-
|
|
506
|
-
|
|
507
|
-
|
|
508
|
-
|
|
509
|
-
|
|
510
|
-
|
|
511
|
-
|
|
512
|
-
|
|
513
|
-
|
|
514
|
-
|
|
515
|
-
|
|
516
|
-
|
|
517
|
-
|
|
518
|
-
|
|
519
|
-
|
|
520
|
-
|
|
521
|
-
|
|
522
|
-
|
|
523
|
-
|
|
524
|
-
|
|
525
|
-
|
|
526
|
-
|
|
527
|
-
|
|
528
|
-
|
|
529
|
-
|
|
530
|
-
|
|
531
|
-
|
|
532
|
-
|
|
533
|
-
|
|
534
|
-
|
|
535
|
-
|
|
536
|
-
|
|
537
|
-
|
|
538
|
-
|
|
539
|
-
|
|
540
|
-
|
|
541
|
-
|
|
542
|
-
|
|
543
|
-
|
|
544
|
-
|
|
545
|
-
|
|
546
|
-
|
|
547
|
-
|
|
548
|
-
|
|
549
|
-
|
|
550
|
-
|
|
551
|
-
|
|
552
|
-
|
|
553
|
-
|
|
554
|
-
|
|
555
|
-
|
|
556
|
-
|
|
557
|
-
|
|
558
|
-
|
|
559
|
-
|
|
560
|
-
|
|
561
|
-
|
|
562
|
-
|
|
563
|
-
|
|
564
|
-
|
|
565
|
-
|
|
566
|
-
|
|
567
|
-
|
|
568
|
-
|
|
569
|
-
|
|
570
|
-
|
|
571
|
-
|
|
572
|
-
|
|
573
|
-
|
|
574
|
-
|
|
575
|
-
|
|
576
|
-
|
|
577
|
-
|
|
578
|
-
|
|
579
|
-
|
|
580
|
-
|
|
581
|
-
|
|
582
|
-
|
|
583
|
-
|
|
584
|
-
|
|
585
|
-
|
|
586
|
-
|
|
587
|
-
|
|
588
|
-
|
|
589
|
-
|
|
590
|
-
|
|
591
|
-
|
|
592
|
-
|
|
593
|
-
|
|
594
|
-
|
|
595
|
-
|
|
596
|
-
|
|
597
|
-
|
|
598
|
-
|
|
599
|
-
|
|
600
|
-
|
|
601
|
-
|
|
602
|
-
|
|
603
|
-
|
|
604
|
-
|
|
605
|
-
|
|
606
|
-
|
|
607
|
-
|
|
608
|
-
|
|
609
|
-
|
|
610
|
-
|
|
611
|
-
|
|
612
|
-
|
|
613
|
-
|
|
614
|
-
|
|
615
|
-
|
|
616
|
-
|
|
617
|
-
|
|
618
|
-
|
|
619
|
-
|
|
620
|
-
|
|
621
|
-
|
|
622
|
-
|
|
623
|
-
|
|
624
|
-
|
|
625
|
-
|
|
626
|
-
|
|
627
|
-
|
|
628
|
-
|
|
629
|
-
|
|
630
|
-
|
|
631
|
-
|
|
632
|
-
|
|
633
|
-
|
|
634
|
-
|
|
635
|
-
|
|
636
|
-
|
|
637
|
-
|
|
638
|
-
|
|
639
|
-
|
|
640
|
-
|
|
641
|
-
|
|
642
|
-
|
|
643
|
-
|
|
644
|
-
|
|
645
|
-
|
|
646
|
-
|
|
647
|
-
|
|
648
|
-
|
|
649
|
-
|
|
650
|
-
|
|
651
|
-
|
|
652
|
-
|
|
653
|
-
|
|
654
|
-
|
|
655
|
-
|
|
656
|
-
|
|
657
|
-
|
|
658
|
-
|
|
659
|
-
|
|
660
|
-
|
|
661
|
-
|
|
662
|
-
|
|
663
|
-
|
|
664
|
-
|
|
665
|
-
|
|
666
|
-
|
|
667
|
-
|
|
668
|
-
|
|
669
|
-
|
|
670
|
-
|
|
671
|
-
|
|
672
|
-
|
|
673
|
-
|
|
674
|
-
|
|
675
|
-
|
|
676
|
-
|
|
677
|
-
|
|
678
|
-
|
|
679
|
-
|
|
680
|
-
|
|
681
|
-
|
|
682
|
-
|
|
683
|
-
|
|
684
|
-
|
|
685
|
-
|
|
686
|
-
|
|
687
|
-
|
|
688
|
-
|
|
689
|
-
|
|
690
|
-
|
|
691
|
-
|
|
692
|
-
|
|
693
|
-
|
|
694
|
-
|
|
695
|
-
|
|
696
|
-
|
|
697
|
-
|
|
698
|
-
|
|
699
|
-
|
|
700
|
-
|
|
701
|
-
|
|
702
|
-
|
|
703
|
-
|
|
704
|
-
|
|
819
|
+
},
|
|
820
|
+
description: "Reviews a batch of API operations for quality and correctness.\n\nValidates each operation's request/response schemas, authentication\nhandling, error responses, and documentation completeness. Operations are\nmarked as passed or failed based on compliance with enterprise standards.",
|
|
821
|
+
validate: (() => { const _io0 = input => "string" === typeof input.review && "string" === typeof input.plan && (Array.isArray(input.content) && input.content.every(elem => "object" === typeof elem && null !== elem && _io1(elem))); const _io1 = input => "string" === typeof input.prisma_schemas && "string" === typeof input.model_name && (null === input.soft_delete_column || "string" === typeof input.soft_delete_column) && "string" === typeof input.description && ("string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name)) && "string" === typeof input.specification && "string" === typeof input.summary && ("string" === typeof input.path && RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path)) && (Array.isArray(input.parameters) && input.parameters.every(elem => "object" === typeof elem && null !== elem && _io2(elem))) && (null === input.requestBody || "object" === typeof input.requestBody && null !== input.requestBody && _io6(input.requestBody)) && (null === input.responseBody || "object" === typeof input.responseBody && null !== input.responseBody && _io7(input.responseBody)) && (null === input.authorizationRole || "string" === typeof input.authorizationRole && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationRole) && 1 <= input.authorizationRole.length)) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) && "string" === typeof input.description && ("object" === typeof input.schema && null !== input.schema && _iu0(input.schema)); const _io3 = input => (undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000)) && (undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000)) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 && 0 < input.multipleOf)) && "integer" === input.type; const _io4 = input => (undefined === input.minimum || "number" === typeof input.minimum) && (undefined === input.maximum || "number" === typeof input.maximum) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && 0 < input.multipleOf) && "number" === input.type; const _io5 = input => (undefined === input.format || "string" === typeof input.format) && (undefined === input.pattern || "string" === typeof input.pattern) && (undefined === input.contentMediaType || "string" === typeof input.contentMediaType) && (undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 18446744073709552000)) && (undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 18446744073709552000)) && "string" === input.type; const _io6 = input => "string" === typeof input.description && "string" === typeof input.typeName; const _io7 = input => "string" === typeof input.description && "string" === typeof input.typeName; const _iu0 = input => (() => {
|
|
822
|
+
if ("number" === input.type)
|
|
823
|
+
return _io4(input);
|
|
824
|
+
else if ("integer" === input.type)
|
|
825
|
+
return _io3(input);
|
|
826
|
+
else if ("string" === input.type)
|
|
827
|
+
return _io5(input);
|
|
828
|
+
else
|
|
829
|
+
return false;
|
|
830
|
+
})(); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.review || _report(_exceptionable, {
|
|
831
|
+
path: _path + ".review",
|
|
832
|
+
expected: "string",
|
|
833
|
+
value: input.review
|
|
834
|
+
}), "string" === typeof input.plan || _report(_exceptionable, {
|
|
835
|
+
path: _path + ".plan",
|
|
836
|
+
expected: "string",
|
|
837
|
+
value: input.plan
|
|
838
|
+
}), (Array.isArray(input.content) || _report(_exceptionable, {
|
|
839
|
+
path: _path + ".content",
|
|
840
|
+
expected: "Array<IAutoBeInterfaceOperationsReviewApplication.IOperation>",
|
|
841
|
+
value: input.content
|
|
842
|
+
})) && input.content.map((elem, _index3) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
843
|
+
path: _path + ".content[" + _index3 + "]",
|
|
844
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IOperation",
|
|
845
|
+
value: elem
|
|
846
|
+
})) && _vo1(elem, _path + ".content[" + _index3 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
847
|
+
path: _path + ".content[" + _index3 + "]",
|
|
848
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IOperation",
|
|
849
|
+
value: elem
|
|
850
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
851
|
+
path: _path + ".content",
|
|
852
|
+
expected: "Array<IAutoBeInterfaceOperationsReviewApplication.IOperation>",
|
|
853
|
+
value: input.content
|
|
854
|
+
})].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.prisma_schemas || _report(_exceptionable, {
|
|
855
|
+
path: _path + ".prisma_schemas",
|
|
856
|
+
expected: "string",
|
|
857
|
+
value: input.prisma_schemas
|
|
858
|
+
}), "string" === typeof input.model_name || _report(_exceptionable, {
|
|
859
|
+
path: _path + ".model_name",
|
|
860
|
+
expected: "string",
|
|
861
|
+
value: input.model_name
|
|
862
|
+
}), null === input.soft_delete_column || "string" === typeof input.soft_delete_column || _report(_exceptionable, {
|
|
863
|
+
path: _path + ".soft_delete_column",
|
|
864
|
+
expected: "(null | string)",
|
|
865
|
+
value: input.soft_delete_column
|
|
866
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
867
|
+
path: _path + ".description",
|
|
868
|
+
expected: "string",
|
|
869
|
+
value: input.description
|
|
870
|
+
}), "string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
871
|
+
path: _path + ".name",
|
|
872
|
+
expected: "string & CamelPattern",
|
|
873
|
+
value: input.name
|
|
874
|
+
})) || _report(_exceptionable, {
|
|
875
|
+
path: _path + ".name",
|
|
876
|
+
expected: "(string & CamelPattern)",
|
|
877
|
+
value: input.name
|
|
878
|
+
}), "string" === typeof input.specification || _report(_exceptionable, {
|
|
879
|
+
path: _path + ".specification",
|
|
880
|
+
expected: "string",
|
|
881
|
+
value: input.specification
|
|
882
|
+
}), "string" === typeof input.summary || _report(_exceptionable, {
|
|
883
|
+
path: _path + ".summary",
|
|
884
|
+
expected: "string",
|
|
885
|
+
value: input.summary
|
|
886
|
+
}), "string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
|
|
887
|
+
path: _path + ".path",
|
|
888
|
+
expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
|
|
889
|
+
value: input.path
|
|
890
|
+
})) || _report(_exceptionable, {
|
|
891
|
+
path: _path + ".path",
|
|
892
|
+
expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
|
|
893
|
+
value: input.path
|
|
894
|
+
}), (Array.isArray(input.parameters) || _report(_exceptionable, {
|
|
895
|
+
path: _path + ".parameters",
|
|
896
|
+
expected: "Array<AutoBeOpenApi.IParameter>",
|
|
897
|
+
value: input.parameters
|
|
898
|
+
})) && input.parameters.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
899
|
+
path: _path + ".parameters[" + _index4 + "]",
|
|
900
|
+
expected: "AutoBeOpenApi.IParameter",
|
|
901
|
+
value: elem
|
|
902
|
+
})) && _vo2(elem, _path + ".parameters[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
903
|
+
path: _path + ".parameters[" + _index4 + "]",
|
|
904
|
+
expected: "AutoBeOpenApi.IParameter",
|
|
905
|
+
value: elem
|
|
906
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
907
|
+
path: _path + ".parameters",
|
|
908
|
+
expected: "Array<AutoBeOpenApi.IParameter>",
|
|
909
|
+
value: input.parameters
|
|
910
|
+
}), null === input.requestBody || ("object" === typeof input.requestBody && null !== input.requestBody || _report(_exceptionable, {
|
|
911
|
+
path: _path + ".requestBody",
|
|
912
|
+
expected: "(AutoBeOpenApi.IRequestBody | null)",
|
|
913
|
+
value: input.requestBody
|
|
914
|
+
})) && _vo6(input.requestBody, _path + ".requestBody", true && _exceptionable) || _report(_exceptionable, {
|
|
915
|
+
path: _path + ".requestBody",
|
|
916
|
+
expected: "(AutoBeOpenApi.IRequestBody | null)",
|
|
917
|
+
value: input.requestBody
|
|
918
|
+
}), null === input.responseBody || ("object" === typeof input.responseBody && null !== input.responseBody || _report(_exceptionable, {
|
|
919
|
+
path: _path + ".responseBody",
|
|
920
|
+
expected: "(AutoBeOpenApi.IResponseBody | null)",
|
|
921
|
+
value: input.responseBody
|
|
922
|
+
})) && _vo7(input.responseBody, _path + ".responseBody", true && _exceptionable) || _report(_exceptionable, {
|
|
923
|
+
path: _path + ".responseBody",
|
|
924
|
+
expected: "(AutoBeOpenApi.IResponseBody | null)",
|
|
925
|
+
value: input.responseBody
|
|
926
|
+
}), null === input.authorizationRole || "string" === typeof input.authorizationRole && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationRole) || _report(_exceptionable, {
|
|
927
|
+
path: _path + ".authorizationRole",
|
|
928
|
+
expected: "string & CamelPattern",
|
|
929
|
+
value: input.authorizationRole
|
|
930
|
+
})) && (1 <= input.authorizationRole.length || _report(_exceptionable, {
|
|
931
|
+
path: _path + ".authorizationRole",
|
|
932
|
+
expected: "string & MinLength<1>",
|
|
933
|
+
value: input.authorizationRole
|
|
934
|
+
})) || _report(_exceptionable, {
|
|
935
|
+
path: _path + ".authorizationRole",
|
|
936
|
+
expected: "((string & CamelPattern & MinLength<1>) | null)",
|
|
937
|
+
value: input.authorizationRole
|
|
938
|
+
}), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
|
|
939
|
+
path: _path + ".method",
|
|
940
|
+
expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
|
|
941
|
+
value: input.method
|
|
942
|
+
})].every(flag => flag); const _vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
943
|
+
path: _path + ".name",
|
|
944
|
+
expected: "string & CamelPattern",
|
|
945
|
+
value: input.name
|
|
946
|
+
})) || _report(_exceptionable, {
|
|
947
|
+
path: _path + ".name",
|
|
948
|
+
expected: "(string & CamelPattern)",
|
|
949
|
+
value: input.name
|
|
950
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
951
|
+
path: _path + ".description",
|
|
952
|
+
expected: "string",
|
|
953
|
+
value: input.description
|
|
954
|
+
}), ("object" === typeof input.schema && null !== input.schema || _report(_exceptionable, {
|
|
955
|
+
path: _path + ".schema",
|
|
956
|
+
expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
|
|
957
|
+
value: input.schema
|
|
958
|
+
})) && _vu0(input.schema, _path + ".schema", true && _exceptionable) || _report(_exceptionable, {
|
|
959
|
+
path: _path + ".schema",
|
|
960
|
+
expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
|
|
961
|
+
value: input.schema
|
|
962
|
+
})].every(flag => flag); const _vo3 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000 || _report(_exceptionable, {
|
|
963
|
+
path: _path + ".minimum",
|
|
964
|
+
expected: "number & Type<\"int64\">",
|
|
965
|
+
value: input.minimum
|
|
966
|
+
})) || _report(_exceptionable, {
|
|
967
|
+
path: _path + ".minimum",
|
|
968
|
+
expected: "((number & Type<\"int64\">) | undefined)",
|
|
969
|
+
value: input.minimum
|
|
970
|
+
}), undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000 || _report(_exceptionable, {
|
|
971
|
+
path: _path + ".maximum",
|
|
972
|
+
expected: "number & Type<\"int64\">",
|
|
973
|
+
value: input.maximum
|
|
974
|
+
})) || _report(_exceptionable, {
|
|
975
|
+
path: _path + ".maximum",
|
|
976
|
+
expected: "((number & Type<\"int64\">) | undefined)",
|
|
977
|
+
value: input.maximum
|
|
978
|
+
}), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
|
|
979
|
+
path: _path + ".exclusiveMinimum",
|
|
980
|
+
expected: "(number | undefined)",
|
|
981
|
+
value: input.exclusiveMinimum
|
|
982
|
+
}), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
|
|
983
|
+
path: _path + ".exclusiveMaximum",
|
|
984
|
+
expected: "(number | undefined)",
|
|
985
|
+
value: input.exclusiveMaximum
|
|
986
|
+
}), undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 || _report(_exceptionable, {
|
|
987
|
+
path: _path + ".multipleOf",
|
|
988
|
+
expected: "number & Type<\"uint64\">",
|
|
989
|
+
value: input.multipleOf
|
|
990
|
+
})) && (0 < input.multipleOf || _report(_exceptionable, {
|
|
991
|
+
path: _path + ".multipleOf",
|
|
992
|
+
expected: "number & ExclusiveMinimum<0>",
|
|
993
|
+
value: input.multipleOf
|
|
994
|
+
})) || _report(_exceptionable, {
|
|
995
|
+
path: _path + ".multipleOf",
|
|
996
|
+
expected: "((number & Type<\"uint64\"> & ExclusiveMinimum<0>) | undefined)",
|
|
997
|
+
value: input.multipleOf
|
|
998
|
+
}), "integer" === input.type || _report(_exceptionable, {
|
|
999
|
+
path: _path + ".type",
|
|
1000
|
+
expected: "\"integer\"",
|
|
1001
|
+
value: input.type
|
|
1002
|
+
})].every(flag => flag); const _vo4 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum || _report(_exceptionable, {
|
|
1003
|
+
path: _path + ".minimum",
|
|
1004
|
+
expected: "(number | undefined)",
|
|
1005
|
+
value: input.minimum
|
|
1006
|
+
}), undefined === input.maximum || "number" === typeof input.maximum || _report(_exceptionable, {
|
|
1007
|
+
path: _path + ".maximum",
|
|
1008
|
+
expected: "(number | undefined)",
|
|
1009
|
+
value: input.maximum
|
|
1010
|
+
}), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
|
|
1011
|
+
path: _path + ".exclusiveMinimum",
|
|
1012
|
+
expected: "(number | undefined)",
|
|
1013
|
+
value: input.exclusiveMinimum
|
|
1014
|
+
}), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
|
|
1015
|
+
path: _path + ".exclusiveMaximum",
|
|
1016
|
+
expected: "(number | undefined)",
|
|
1017
|
+
value: input.exclusiveMaximum
|
|
1018
|
+
}), undefined === input.multipleOf || "number" === typeof input.multipleOf && (0 < input.multipleOf || _report(_exceptionable, {
|
|
1019
|
+
path: _path + ".multipleOf",
|
|
1020
|
+
expected: "number & ExclusiveMinimum<0>",
|
|
1021
|
+
value: input.multipleOf
|
|
1022
|
+
})) || _report(_exceptionable, {
|
|
1023
|
+
path: _path + ".multipleOf",
|
|
1024
|
+
expected: "((number & ExclusiveMinimum<0>) | undefined)",
|
|
1025
|
+
value: input.multipleOf
|
|
1026
|
+
}), "number" === input.type || _report(_exceptionable, {
|
|
1027
|
+
path: _path + ".type",
|
|
1028
|
+
expected: "\"number\"",
|
|
1029
|
+
value: input.type
|
|
1030
|
+
})].every(flag => flag); const _vo5 = (input, _path, _exceptionable = true) => [undefined === input.format || "string" === typeof input.format || _report(_exceptionable, {
|
|
1031
|
+
path: _path + ".format",
|
|
1032
|
+
expected: "(string | undefined)",
|
|
1033
|
+
value: input.format
|
|
1034
|
+
}), undefined === input.pattern || "string" === typeof input.pattern || _report(_exceptionable, {
|
|
1035
|
+
path: _path + ".pattern",
|
|
1036
|
+
expected: "(string | undefined)",
|
|
1037
|
+
value: input.pattern
|
|
1038
|
+
}), undefined === input.contentMediaType || "string" === typeof input.contentMediaType || _report(_exceptionable, {
|
|
1039
|
+
path: _path + ".contentMediaType",
|
|
1040
|
+
expected: "(string | undefined)",
|
|
1041
|
+
value: input.contentMediaType
|
|
1042
|
+
}), undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 18446744073709552000 || _report(_exceptionable, {
|
|
1043
|
+
path: _path + ".minLength",
|
|
1044
|
+
expected: "number & Type<\"uint64\">",
|
|
1045
|
+
value: input.minLength
|
|
1046
|
+
})) || _report(_exceptionable, {
|
|
1047
|
+
path: _path + ".minLength",
|
|
1048
|
+
expected: "((number & Type<\"uint64\">) | undefined)",
|
|
1049
|
+
value: input.minLength
|
|
1050
|
+
}), undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 18446744073709552000 || _report(_exceptionable, {
|
|
1051
|
+
path: _path + ".maxLength",
|
|
1052
|
+
expected: "number & Type<\"uint64\">",
|
|
1053
|
+
value: input.maxLength
|
|
1054
|
+
})) || _report(_exceptionable, {
|
|
1055
|
+
path: _path + ".maxLength",
|
|
1056
|
+
expected: "((number & Type<\"uint64\">) | undefined)",
|
|
1057
|
+
value: input.maxLength
|
|
1058
|
+
}), "string" === input.type || _report(_exceptionable, {
|
|
1059
|
+
path: _path + ".type",
|
|
1060
|
+
expected: "\"string\"",
|
|
1061
|
+
value: input.type
|
|
1062
|
+
})].every(flag => flag); const _vo6 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
|
|
1063
|
+
path: _path + ".description",
|
|
1064
|
+
expected: "string",
|
|
1065
|
+
value: input.description
|
|
1066
|
+
}), "string" === typeof input.typeName || _report(_exceptionable, {
|
|
1067
|
+
path: _path + ".typeName",
|
|
1068
|
+
expected: "string",
|
|
1069
|
+
value: input.typeName
|
|
1070
|
+
})].every(flag => flag); const _vo7 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
|
|
1071
|
+
path: _path + ".description",
|
|
1072
|
+
expected: "string",
|
|
1073
|
+
value: input.description
|
|
1074
|
+
}), "string" === typeof input.typeName || _report(_exceptionable, {
|
|
1075
|
+
path: _path + ".typeName",
|
|
1076
|
+
expected: "string",
|
|
1077
|
+
value: input.typeName
|
|
1078
|
+
})].every(flag => flag); const _vu0 = (input, _path, _exceptionable = true) => (() => {
|
|
1079
|
+
if ("number" === input.type)
|
|
1080
|
+
return _vo4(input, _path, true && _exceptionable);
|
|
1081
|
+
else if ("integer" === input.type)
|
|
1082
|
+
return _vo3(input, _path, true && _exceptionable);
|
|
1083
|
+
else if ("string" === input.type)
|
|
1084
|
+
return _vo5(input, _path, true && _exceptionable);
|
|
1085
|
+
else
|
|
1086
|
+
return _report(_exceptionable, {
|
|
1087
|
+
path: _path,
|
|
1088
|
+
expected: "(AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.IString)",
|
|
1089
|
+
value: input
|
|
1090
|
+
});
|
|
1091
|
+
})(); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
|
|
1092
|
+
if (false === __is(input)) {
|
|
1093
|
+
errors = [];
|
|
1094
|
+
_report = __typia_transform__validateReport._validateReport(errors);
|
|
1095
|
+
((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
|
|
1096
|
+
path: _path + "",
|
|
1097
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IProps",
|
|
1098
|
+
value: input
|
|
1099
|
+
})) && _vo0(input, _path + "", true) || _report(true, {
|
|
1100
|
+
path: _path + "",
|
|
1101
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IProps",
|
|
1102
|
+
value: input
|
|
1103
|
+
}))(input, "$input", true);
|
|
1104
|
+
const success = 0 === errors.length;
|
|
1105
|
+
return success ? {
|
|
1106
|
+
success,
|
|
1107
|
+
data: input
|
|
1108
|
+
} : {
|
|
1109
|
+
success,
|
|
1110
|
+
errors,
|
|
1111
|
+
data: input
|
|
1112
|
+
};
|
|
1113
|
+
}
|
|
1114
|
+
return {
|
|
1115
|
+
success: true,
|
|
705
1116
|
data: input
|
|
706
1117
|
};
|
|
707
|
-
}
|
|
708
|
-
|
|
709
|
-
|
|
710
|
-
|
|
711
|
-
|
|
712
|
-
|
|
713
|
-
|
|
714
|
-
|
|
715
|
-
|
|
716
|
-
|
|
717
|
-
|
|
718
|
-
|
|
719
|
-
|
|
720
|
-
|
|
721
|
-
|
|
722
|
-
|
|
723
|
-
|
|
724
|
-
|
|
725
|
-
|
|
726
|
-
|
|
727
|
-
|
|
728
|
-
|
|
729
|
-
|
|
730
|
-
|
|
731
|
-
|
|
732
|
-
|
|
733
|
-
|
|
734
|
-
|
|
735
|
-
|
|
736
|
-
|
|
737
|
-
|
|
738
|
-
|
|
739
|
-
|
|
740
|
-
|
|
741
|
-
|
|
1118
|
+
}; })()
|
|
1119
|
+
}
|
|
1120
|
+
]
|
|
1121
|
+
};
|
|
1122
|
+
__typia_transform__llmApplicationFinalize._llmApplicationFinalize(application, Object.assign(Object.assign({}, {
|
|
1123
|
+
validate: {
|
|
1124
|
+
reviewOperations: validate,
|
|
1125
|
+
},
|
|
1126
|
+
}), { equals: false }));
|
|
1127
|
+
return application;
|
|
1128
|
+
})(),
|
|
1129
|
+
claude: (validate) => (() => {
|
|
1130
|
+
const application = {
|
|
1131
|
+
model: "claude",
|
|
1132
|
+
options: {
|
|
1133
|
+
reference: true,
|
|
1134
|
+
separate: null
|
|
1135
|
+
},
|
|
1136
|
+
functions: [
|
|
1137
|
+
{
|
|
1138
|
+
name: "reviewOperations",
|
|
1139
|
+
parameters: {
|
|
1140
|
+
description: " Collection of operations to review with their validation\nresults\n\n------------------------------\n\nDescription of the current {@link IAutoBeInterfaceOperationsReviewApplication.IProps} type:\n\n> Properties for API operation review and improvement process.\n> \n> Contains both the input operations to be reviewed and the outputs generated\n> by the Interface Operations Review Agent, which will be published as part\n> of the AutoBeInterfaceOperationsReviewEvent.",
|
|
1141
|
+
type: "object",
|
|
1142
|
+
properties: {
|
|
1143
|
+
review: {
|
|
1144
|
+
description: "Comprehensive review analysis with prioritized findings.\n\nSystematic assessment organized by severity levels (CRITICAL, HIGH,\nMEDIUM, LOW):\n\n- **Security Analysis**: Authentication boundary violations, exposed\n passwords/tokens, unauthorized data access patterns, SQL injection\n risks\n- **Logic Validation**: Return type consistency (list operations returning\n arrays, single retrieval returning single items), HTTP method semantics\n alignment, parameter usage verification\n- **Schema Compliance**: Field existence in Prisma schema, type accuracy,\n relationship validity, required field handling\n- **Quality Assessment**: Documentation completeness, naming conventions,\n error handling patterns, pagination standards\n\nEach finding includes specific examples, current vs expected behavior,\nand concrete fix recommendations. Critical security issues and logical\ncontradictions are highlighted for immediate attention.",
|
|
1145
|
+
type: "string"
|
|
1146
|
+
},
|
|
1147
|
+
plan: {
|
|
1148
|
+
description: "Prioritized action plan for identified issues.\n\nStructured improvement strategy categorized by severity:\n\n- **Immediate Actions (CRITICAL)**: Security vulnerabilities that must be\n fixed before production (password exposure, missing authorization,\n authentication bypass risks)\n- **Required Fixes (HIGH)**: Functional issues affecting API correctness\n (wrong return types, missing required fields, schema mismatches)\n- **Recommended Improvements (MEDIUM)**: Quality enhancements for better\n API design (validation rules, format specifications, consistency)\n- **Optional Enhancements (LOW)**: Documentation and usability improvements\n\nIf all operations pass review without issues, contains: \"No improvements\nrequired. All operations meet AutoBE standards.\"\n\nEach action item includes the specific operation path, the exact change\nneeded, and the rationale for the modification.",
|
|
1149
|
+
type: "string"
|
|
1150
|
+
},
|
|
1151
|
+
content: {
|
|
1152
|
+
description: "Production-ready operations with all critical issues resolved.\n\nFinal API operations after systematic enhancement:\n\n- **Security Fixes Applied**: All authentication boundaries enforced,\n sensitive data removed from responses, proper authorization\n implemented\n- **Logic Corrections Made**: Return types match operation intent, HTTP\n methods align with semantics, parameters properly utilized\n- **Schema Alignment Verified**: All fields exist in Prisma schema, types\n correctly mapped, relationships properly defined\n- **Quality Improvements Added**: Enhanced documentation, format\n specifications, validation rules, consistent naming patterns\n\nIf no issues were found during review, this contains the exact original\noperations unchanged. These operations are validated and ready for schema\ngeneration and subsequent implementation phases.",
|
|
1153
|
+
type: "array",
|
|
1154
|
+
items: {
|
|
1155
|
+
$ref: "#/$defs/IAutoBeInterfaceOperationsReviewApplication.IOperation"
|
|
1156
|
+
}
|
|
742
1157
|
}
|
|
743
|
-
}
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
|
|
747
|
-
|
|
748
|
-
|
|
749
|
-
|
|
750
|
-
|
|
751
|
-
|
|
752
|
-
|
|
753
|
-
|
|
754
|
-
|
|
755
|
-
|
|
756
|
-
|
|
757
|
-
|
|
758
|
-
|
|
759
|
-
|
|
760
|
-
|
|
761
|
-
|
|
762
|
-
|
|
763
|
-
|
|
764
|
-
|
|
765
|
-
|
|
766
|
-
|
|
767
|
-
|
|
768
|
-
|
|
769
|
-
|
|
770
|
-
|
|
771
|
-
|
|
772
|
-
|
|
773
|
-
|
|
774
|
-
description:
|
|
775
|
-
|
|
776
|
-
|
|
777
|
-
|
|
778
|
-
|
|
779
|
-
|
|
780
|
-
|
|
781
|
-
|
|
782
|
-
|
|
783
|
-
|
|
784
|
-
|
|
785
|
-
|
|
786
|
-
|
|
787
|
-
|
|
788
|
-
|
|
789
|
-
|
|
790
|
-
|
|
791
|
-
|
|
792
|
-
|
|
793
|
-
|
|
794
|
-
|
|
795
|
-
|
|
796
|
-
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
{
|
|
800
|
-
|
|
801
|
-
},
|
|
802
|
-
{
|
|
803
|
-
$ref: "#/$defs/AutoBeOpenApi.IResponseBody"
|
|
804
|
-
}
|
|
805
|
-
]
|
|
806
|
-
},
|
|
807
|
-
authorizationRole: {
|
|
808
|
-
description: "Authorization role required to access this API operation.\n\nThis field specifies which user role is allowed to access this endpoint.\nThe role name must correspond exactly to the actual roles defined in your\nsystem's Prisma schema.\n\n## Naming Convention\n\nRole names MUST use camelCase.\n\n## Role-Based Path Convention\n\nWhen authorizationRole is specified, it should align with the path\nstructure:\n\n- If authorizationRole is \"admin\" \u2192 path might be \"/admin/resources/{id}\"\n- If authorizationRole is \"seller\" \u2192 path might be \"/seller/products\"\n- Special case: For user's own resources, use path prefix \"/my/\" regardless\n of role\n\n## Important Guidelines\n\n- Set to `null` for public endpoints that require no authentication\n- Set to specific role string for role-restricted endpoints\n- The role name MUST match exactly with the user type/role defined in the\n database\n- This role will be used by the Realize Agent to generate appropriate\n decorator and authorization logic in the provider functions\n- The controller will apply the corresponding authentication decorator\n based on this role\n\n## Examples\n\n- `null` - Public endpoint, no authentication required\n- `\"user\"` - Any authenticated user can access\n- `\"admin\"` - Only admin users can access\n- `\"seller\"` - Only seller users can access\n- `\"moderator\"` - Only moderator users can access\n\nNote: The actual authentication/authorization implementation will be\nhandled by decorators at the controller level, and the provider function\nwill receive the authenticated user object with the appropriate type.",
|
|
809
|
-
oneOf: [
|
|
810
|
-
{
|
|
811
|
-
type: "null"
|
|
812
|
-
},
|
|
813
|
-
{
|
|
814
|
-
type: "string",
|
|
815
|
-
pattern: "^[a-z][a-zA-Z0-9]*$",
|
|
816
|
-
minLength: 1
|
|
1158
|
+
},
|
|
1159
|
+
required: [
|
|
1160
|
+
"review",
|
|
1161
|
+
"plan",
|
|
1162
|
+
"content"
|
|
1163
|
+
],
|
|
1164
|
+
additionalProperties: false,
|
|
1165
|
+
$defs: {
|
|
1166
|
+
"IAutoBeInterfaceOperationsReviewApplication.IOperation": {
|
|
1167
|
+
description: "Operation of the Restful API.\n\nThis interface defines a single API endpoint with its HTTP {@link method},\n{@link path}, {@link parameters path parameters},\n{@link requestBody request body}, and {@link responseBody} structure. It\ncorresponds to an individual operation in the paths section of an OpenAPI\ndocument.\n\nEach operation requires a detailed explanation of its purpose through the\nreason and description fields, making it clear why the API was designed and\nhow it should be used.\n\nAll request bodies and responses for this operation must be object types\nand must reference named types defined in the components section. The\ncontent-type is always `application/json`. For file upload/download\noperations, use `string & tags.Format<\"uri\">` in the appropriate schema\ninstead of binary data formats.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"/shoppings/customers/orders\": {\n \"post\": {\n \"description\": \"Create a new order application from shopping cart...\",\n \"parameters\": [...],\n \"requestBody\": {...},\n \"responses\": {...}\n }\n }\n}\n```",
|
|
1168
|
+
type: "object",
|
|
1169
|
+
properties: {
|
|
1170
|
+
prisma_schemas: {
|
|
1171
|
+
description: "Prisma schema models relevant to this operation.\n\nContains the complete Prisma schema definitions for all entities involved\nin this operation, including their fields, relations, and database\nconstraints. This enables comprehensive validation and schema-aware\noperation design.\n\nThe schema information serves multiple critical purposes:\n\n- **Field Verification**: Ensures all referenced fields actually exist in\n the database schema and have the correct types\n- **Relationship Validation**: Confirms that entity relationships are\n properly defined and can support the operation's data access patterns\n- **Soft-Delete Detection**: For DELETE operations, identifies whether\n entities have soft-delete fields (deleted_at, is_deleted, etc.) to\n determine if the operation should perform logical deletion instead of\n physical removal\n- **Constraint Awareness**: Understands unique constraints, required\n fields, and default values to generate accurate request/response\n schemas\n\nExample content might include:\n\n```prisma\nmodel User {\n id String",
|
|
1172
|
+
type: "string"
|
|
1173
|
+
},
|
|
1174
|
+
model_name: {
|
|
1175
|
+
description: "Primary Prisma model name for this operation.\n\nIdentifies the main database table/model that this operation targets.\nThis must match exactly with the Prisma model name defined in the schema.\nWhen soft deletion is specified, this model name indicates which table\nshould be soft-deleted.\n\nFor example:\n- In a \"GET /users/:id\" operation, this would be \"User\"\n- In a \"POST /articles\" operation, this would be \"Article\"\n- In a \"DELETE /comments/:id\" with soft delete, this specifies the \"Comment\" model to soft-delete\n\nThis property is essential for:\n- Determining the primary entity for CRUD operations\n- Identifying which table to apply soft deletion to\n- Validating operations against the correct Prisma model\n- Generating appropriate database queries and validations",
|
|
1176
|
+
type: "string"
|
|
1177
|
+
},
|
|
1178
|
+
soft_delete_column: {
|
|
1179
|
+
description: "Soft delete column name for the Prisma models.\n\nSpecifies the column name used for soft deletion in the database tables\nassociated with this operation. When set to a non-null value, it indicates\nthat the related entities support soft deletion through this column\n(typically a timestamp field like `deleted_at` or `deletedAt`).\n\nWhen null, it means the entities involved in this operation use hard\ndeletion or don't support deletion at all. This information is crucial\nfor generating appropriate CRUD operations and ensuring data integrity\npolicies are correctly implemented.\n\nCommon soft delete patterns:\n- `\"deleted_at\"`: Records deletion timestamp\n- `\"deletedAt\"`: Camel-cased deletion timestamp\n- `\"is_deleted\"`: Boolean flag for deletion status\n- `null`: No soft deletion (hard delete only)",
|
|
1180
|
+
oneOf: [
|
|
1181
|
+
{
|
|
1182
|
+
type: "null"
|
|
1183
|
+
},
|
|
1184
|
+
{
|
|
1185
|
+
type: "string"
|
|
1186
|
+
}
|
|
1187
|
+
]
|
|
1188
|
+
},
|
|
1189
|
+
description: {
|
|
1190
|
+
description: "Detailed description about the API operation.\n\nIMPORTANT: This field MUST be extensively detailed and MUST reference the\ndescription comments from the related Prisma DB schema tables and\ncolumns. The description should be organized into MULTIPLE PARAGRAPHS\nseparated by line breaks to improve readability and comprehension.\n\nFor example, include separate paragraphs for:\n\n- The purpose and overview of the API operation\n- Security considerations and user permissions\n- Relationship to underlying database entities\n- Validation rules and business logic\n- Related API operations that might be used together with this one\n- Expected behavior and error handling\n\nWhen writing the description, be sure to incorporate the corresponding DB\nschema's description comments, matching the level of detail and style of\nthose comments. This ensures consistency between the API documentation\nand database structure.\n\nIf there's a dependency to other APIs, please describe the dependency API\noperation in this field with detailed reason. For example, if this API\noperation needs a pre-execution of other API operation, it must be\nexplicitly described.\n\n- `GET /shoppings/customers/sales` must be pre-executed to get entire list\n of summarized sales. Detailed sale information would be obtained by\n specifying the sale ID in the path parameter.\n\n**CRITICAL WARNING about soft delete keywords**:\nDO NOT use terms like \"soft delete\", \"soft-delete\", or similar variations\nin this description UNLESS the operation actually implements soft deletion.\nThese keywords trigger validation logic that expects a corresponding\nsoft_delete_column to be specified. Only use these terms when you intend\nto implement soft deletion (marking records as deleted without removing\nthem from the database).\n\nExample of problematic description:\n\u274C \"This would normally be a soft-delete, but we intentionally perform\npermanent deletion here\" - This triggers soft delete validation despite\nbeing a hard delete operation.\n\n> MUST be written in English. Never use other languages.",
|
|
1191
|
+
type: "string"
|
|
1192
|
+
},
|
|
1193
|
+
name: {
|
|
1194
|
+
description: "Functional name of the API endpoint.\n\nThis is a semantic identifier that represents the primary function or\npurpose of the API endpoint. It serves as a canonical name that can be\nused for code generation, SDK method names, and internal references.\n\n## Reserved Word Restrictions\n\nCRITICAL: The name MUST NOT be a TypeScript/JavaScript reserved word, as\nit will be used as a class method name in generated code. Avoid names\nlike:\n\n- `delete`, `for`, `if`, `else`, `while`, `do`, `switch`, `case`, `break`\n- `continue`, `function`, `return`, `with`, `in`, `of`, `instanceof`\n- `typeof`, `void`, `var`, `let`, `const`, `class`, `extends`, `import`\n- `export`, `default`, `try`, `catch`, `finally`, `throw`, `new`\n- `super`, `this`, `null`, `true`, `false`, `async`, `await`\n- `yield`, `static`, `private`, `protected`, `public`, `implements`\n- `interface`, `package`, `enum`, `debugger`\n\nInstead, use alternative names for these operations:\n\n- Use `erase` instead of `delete`\n- Use `iterate` instead of `for`\n- Use `when` instead of `if`\n- Use `cls` instead of `class`\n\n## Standard Endpoint Names\n\nUse these conventional names based on the endpoint's primary function:\n\n- **`index`**: List/search operations that return multiple entities\n\n - Typically used with PATCH method for complex queries\n - Example: `PATCH /users` \u2192 `name: \"index\"`\n- **`at`**: Retrieve a specific entity by identifier\n\n - Typically used with GET method on single resource\n - Example: `GET /users/{userId}` \u2192 `name: \"at\"`\n- **`create`**: Create a new entity\n\n - Typically used with POST method\n - Example: `POST /users` \u2192 `name: \"create\"`\n- **`update`**: Update an existing entity\n\n - Typically used with PUT method\n - Example: `PUT /users/{userId}` \u2192 `name: \"update\"`\n- **`erase`**: Delete/remove an entity (NOT `delete` - reserved word!)\n\n - Typically used with DELETE method\n - Example: `DELETE /users/{userId}` \u2192 `name: \"erase\"`\n\n## Custom Endpoint Names\n\nFor specialized operations beyond basic CRUD, use descriptive verbs:\n\n- **`activate`**: Enable or turn on a feature/entity\n- **`deactivate`**: Disable or turn off a feature/entity\n- **`approve`**: Approve a request or entity\n- **`reject`**: Reject a request or entity\n- **`publish`**: Make content publicly available\n- **`archive`**: Move to archived state\n- **`restore`**: Restore from archived/deleted state\n- **`duplicate`**: Create a copy of an entity\n- **`transfer`**: Move ownership or change assignment\n- **`validate`**: Validate data or state\n- **`process`**: Execute a business process or workflow\n- **`export`**: Generate downloadable data\n- **`import`**: Process uploaded data\n\n## Naming Guidelines\n\n- MUST use camelCase naming convention\n- Use singular verb forms\n- Be concise but descriptive\n- Avoid abbreviations unless widely understood\n- Ensure the name clearly represents the endpoint's primary action\n- For nested resources, focus on the action rather than hierarchy\n- NEVER use JavaScript/TypeScript reserved words\n\nValid Examples:\n\n- `index`, `create`, `update`, `erase` (single word)\n- `updatePassword`, `cancelOrder`, `publishArticle` (camelCase)\n- `validateEmail`, `generateReport`, `exportData` (camelCase)\n\nInvalid Examples:\n\n- `update_password` (snake_case not allowed)\n- `UpdatePassword` (PascalCase not allowed)\n- `update-password` (kebab-case not allowed)\n\nPath to Name Examples:\n\n- `GET /shopping/orders/{orderId}/items` \u2192 `name: \"index\"` (lists items)\n- `POST /shopping/orders/{orderId}/cancel` \u2192 `name: \"cancel\"`\n- `PUT /users/{userId}/password` \u2192 `name: \"updatePassword\"`\n\n## Uniqueness Rule\n\nThe `name` must be unique within the API's accessor namespace. The\naccessor is formed by combining the path segments (excluding parameters)\nwith the operation name.\n\nAccessor formation:\n\n1. Extract non-parameter segments from the path (remove `{...}` parts)\n2. Join segments with dots\n3. Append the operation name\n\nExamples:\n\n- Path: `/shopping/sale/{saleId}/review/{reviewId}`, Name: `at` \u2192 Accessor:\n `shopping.sale.review.at`\n- Path: `/users/{userId}/posts`, Name: `index` \u2192 Accessor:\n `users.posts.index`\n- Path: `/auth/login`, Name: `signIn` \u2192 Accessor: `auth.login.signIn`\n\nEach accessor must be globally unique across the entire API. This ensures\noperations can be uniquely identified in generated SDKs and prevents\nnaming conflicts.",
|
|
1195
|
+
type: "string",
|
|
1196
|
+
pattern: "^[a-z][a-zA-Z0-9]*$"
|
|
1197
|
+
},
|
|
1198
|
+
specification: {
|
|
1199
|
+
description: "Specification of the API operation.\n\nBefore defining the API operation interface, please describe what you're\nplanning to write in this `specification` field.\n\nThe specification must be fully detailed and clear, so that anyone can\nunderstand the purpose and functionality of the API operation and its\nrelated components (e.g., {@link path}, {@link parameters},\n{@link requestBody}).\n\nIMPORTANT: The specification MUST identify which Prisma DB table this\noperation is associated with, helping ensure complete coverage of all\ndatabase entities.",
|
|
1200
|
+
type: "string"
|
|
1201
|
+
},
|
|
1202
|
+
summary: {
|
|
1203
|
+
description: "Short summary of the API operation.\n\nThis should be a concise description of the API operation, typically one\nsentence long. It should provide a quick overview of what the API does\nwithout going into too much detail.\n\nThis summary will be used in the OpenAPI documentation to give users a\nquick understanding of the API operation's purpose.\n\nIMPORTANT: The summary should clearly indicate which Prisma DB table this\noperation relates to, helping to ensure all tables have API coverage.\n\n**CRITICAL WARNING about soft delete keywords**:\nDO NOT use terms like \"soft delete\", \"soft-delete\", or similar variations\nin this summary UNLESS the operation actually implements soft deletion.\nThese keywords trigger validation logic that expects a corresponding\nsoft_delete_column to be specified. Only use these terms when you intend\nto implement soft deletion (marking records as deleted without removing\nthem from the database).\n\n> MUST be written in English. Never use other languages",
|
|
1204
|
+
type: "string"
|
|
1205
|
+
},
|
|
1206
|
+
path: {
|
|
1207
|
+
description: "HTTP path of the API operation.\n\nThe URL path for accessing this API operation, using path parameters\nenclosed in curly braces (e.g., `/shoppings/customers/sales/{saleId}`).\n\nIt must be corresponded to the {@link parameters path parameters}.\n\nThe path structure should clearly indicate which database entity this\noperation is manipulating, helping to ensure all entities have\nappropriate API coverage.\n\nPath validation rules:\n\n- Must start with a forward slash (/)\n- Can contain only: letters (a-z, A-Z), numbers (0-9), forward slashes (/),\n curly braces for parameters ({paramName}), hyphens (-), and underscores\n (_)\n- Parameters must be enclosed in curly braces: {paramName}\n- Resource names should be in camelCase\n- No quotes, spaces, or invalid special characters allowed\n- No domain or role-based prefixes\n\nValid examples:\n\n- \"/users\"\n- \"/users/{userId}\"\n- \"/articles/{articleId}/comments\"\n- \"/attachmentFiles\"\n- \"/orders/{orderId}/items/{itemId}\"\n\nInvalid examples:\n\n- \"'/users'\" (contains quotes)\n- \"/user profile\" (contains space)\n- \"/users/[userId]\" (wrong bracket format)\n- \"/admin/users\" (role prefix)\n- \"/api/v1/users\" (API prefix)",
|
|
1208
|
+
type: "string",
|
|
1209
|
+
pattern: "^\\/[a-zA-Z0-9\\/_{}.-]*$"
|
|
1210
|
+
},
|
|
1211
|
+
parameters: {
|
|
1212
|
+
description: "List of path parameters.\n\nNote that, the {@link AutoBeOpenApi.IParameter.name identifier name} of\npath parameter must be corresponded to the\n{@link path API operation path}.\n\nFor example, if there's an API operation which has {@link path} of\n`/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}`,\nits list of {@link AutoBeOpenApi.IParameter.name path parameters} must be\nlike:\n\n- `saleId`\n- `questionId`\n- `commentId`",
|
|
1213
|
+
type: "array",
|
|
1214
|
+
items: {
|
|
1215
|
+
$ref: "#/$defs/AutoBeOpenApi.IParameter"
|
|
817
1216
|
}
|
|
818
|
-
|
|
1217
|
+
},
|
|
1218
|
+
requestBody: {
|
|
1219
|
+
description: "Request body of the API operation.\n\nDefines the payload structure for the request. Contains a description and\nschema reference to define the expected input data.\n\nShould be `null` for operations that don't require a request body, such\nas most \"get\" operations.",
|
|
1220
|
+
oneOf: [
|
|
1221
|
+
{
|
|
1222
|
+
type: "null"
|
|
1223
|
+
},
|
|
1224
|
+
{
|
|
1225
|
+
$ref: "#/$defs/AutoBeOpenApi.IRequestBody"
|
|
1226
|
+
}
|
|
1227
|
+
]
|
|
1228
|
+
},
|
|
1229
|
+
responseBody: {
|
|
1230
|
+
description: "Response body of the API operation.\n\nDefines the structure of the successful response data. Contains a\ndescription and schema reference for the returned data.\n\nShould be null for operations that don't return any data.",
|
|
1231
|
+
oneOf: [
|
|
1232
|
+
{
|
|
1233
|
+
type: "null"
|
|
1234
|
+
},
|
|
1235
|
+
{
|
|
1236
|
+
$ref: "#/$defs/AutoBeOpenApi.IResponseBody"
|
|
1237
|
+
}
|
|
1238
|
+
]
|
|
1239
|
+
},
|
|
1240
|
+
authorizationRole: {
|
|
1241
|
+
description: "Authorization role required to access this API operation.\n\nThis field specifies which user role is allowed to access this endpoint.\nThe role name must correspond exactly to the actual roles defined in your\nsystem's Prisma schema.\n\n## Naming Convention\n\nRole names MUST use camelCase.\n\n## Role-Based Path Convention\n\nWhen authorizationRole is specified, it should align with the path\nstructure:\n\n- If authorizationRole is \"admin\" \u2192 path might be \"/admin/resources/{id}\"\n- If authorizationRole is \"seller\" \u2192 path might be \"/seller/products\"\n- Special case: For user's own resources, use path prefix \"/my/\" regardless\n of role\n\n## Important Guidelines\n\n- Set to `null` for public endpoints that require no authentication\n- Set to specific role string for role-restricted endpoints\n- The role name MUST match exactly with the user type/role defined in the\n database\n- This role will be used by the Realize Agent to generate appropriate\n decorator and authorization logic in the provider functions\n- The controller will apply the corresponding authentication decorator\n based on this role\n\n## Examples\n\n- `null` - Public endpoint, no authentication required\n- `\"user\"` - Any authenticated user can access\n- `\"admin\"` - Only admin users can access\n- `\"seller\"` - Only seller users can access\n- `\"moderator\"` - Only moderator users can access\n\nNote: The actual authentication/authorization implementation will be\nhandled by decorators at the controller level, and the provider function\nwill receive the authenticated user object with the appropriate type.",
|
|
1242
|
+
oneOf: [
|
|
1243
|
+
{
|
|
1244
|
+
type: "null"
|
|
1245
|
+
},
|
|
1246
|
+
{
|
|
1247
|
+
type: "string",
|
|
1248
|
+
pattern: "^[a-z][a-zA-Z0-9]*$",
|
|
1249
|
+
minLength: 1
|
|
1250
|
+
}
|
|
1251
|
+
]
|
|
1252
|
+
},
|
|
1253
|
+
method: {
|
|
1254
|
+
description: "HTTP method of the API operation.\n\n**IMPORTANT**: Methods must be written in lowercase only (e.g., \"get\", not \"GET\").\n\nNote that, if the API operation has {@link requestBody}, method must not\nbe `get`.\n\nAlso, even though the API operation has been designed to only get\ninformation, but it needs complicated request information, it must be\ndefined as `patch` method with {@link requestBody} data specification.\n\n- `get`: get information\n- `patch`: get information with complicated request data\n ({@link requestBody})\n- `post`: create new record\n- `put`: update existing record\n- `delete`: remove record",
|
|
1255
|
+
oneOf: [
|
|
1256
|
+
{
|
|
1257
|
+
"const": "get"
|
|
1258
|
+
},
|
|
1259
|
+
{
|
|
1260
|
+
"const": "post"
|
|
1261
|
+
},
|
|
1262
|
+
{
|
|
1263
|
+
"const": "put"
|
|
1264
|
+
},
|
|
1265
|
+
{
|
|
1266
|
+
"const": "delete"
|
|
1267
|
+
},
|
|
1268
|
+
{
|
|
1269
|
+
"const": "patch"
|
|
1270
|
+
}
|
|
1271
|
+
]
|
|
1272
|
+
}
|
|
819
1273
|
},
|
|
820
|
-
|
|
821
|
-
|
|
822
|
-
|
|
823
|
-
|
|
824
|
-
|
|
825
|
-
|
|
826
|
-
|
|
827
|
-
|
|
828
|
-
|
|
829
|
-
|
|
830
|
-
|
|
831
|
-
|
|
832
|
-
|
|
833
|
-
|
|
834
|
-
|
|
835
|
-
{
|
|
836
|
-
"const": "patch"
|
|
837
|
-
}
|
|
838
|
-
]
|
|
839
|
-
}
|
|
1274
|
+
required: [
|
|
1275
|
+
"prisma_schemas",
|
|
1276
|
+
"model_name",
|
|
1277
|
+
"soft_delete_column",
|
|
1278
|
+
"description",
|
|
1279
|
+
"name",
|
|
1280
|
+
"specification",
|
|
1281
|
+
"summary",
|
|
1282
|
+
"path",
|
|
1283
|
+
"parameters",
|
|
1284
|
+
"requestBody",
|
|
1285
|
+
"responseBody",
|
|
1286
|
+
"authorizationRole",
|
|
1287
|
+
"method"
|
|
1288
|
+
]
|
|
840
1289
|
},
|
|
841
|
-
|
|
842
|
-
"description",
|
|
843
|
-
"
|
|
844
|
-
|
|
845
|
-
|
|
846
|
-
|
|
847
|
-
|
|
848
|
-
|
|
849
|
-
|
|
850
|
-
|
|
851
|
-
|
|
852
|
-
|
|
853
|
-
|
|
854
|
-
|
|
855
|
-
|
|
856
|
-
|
|
857
|
-
|
|
858
|
-
|
|
859
|
-
|
|
860
|
-
|
|
861
|
-
|
|
862
|
-
|
|
863
|
-
|
|
864
|
-
|
|
865
|
-
|
|
866
|
-
|
|
867
|
-
|
|
868
|
-
|
|
869
|
-
|
|
870
|
-
|
|
871
|
-
|
|
872
|
-
|
|
873
|
-
|
|
874
|
-
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger"
|
|
875
|
-
},
|
|
876
|
-
{
|
|
877
|
-
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
878
|
-
}
|
|
879
|
-
],
|
|
880
|
-
discriminator: {
|
|
881
|
-
propertyName: "type",
|
|
882
|
-
mapping: {
|
|
883
|
-
number: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber",
|
|
884
|
-
integer: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger",
|
|
885
|
-
string: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
1290
|
+
"AutoBeOpenApi.IParameter": {
|
|
1291
|
+
description: "Path parameter information for API routes.\n\nThis interface defines a path parameter that appears in the URL of an API\nendpoint. Path parameters are enclosed in curly braces in the\n{@link AutoBeOpenApi.IOperation.path operation path} and must be defined\nwith their types and descriptions.\n\nFor example, if API operation path is\n`/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}`,\nthe path parameters should be like below:\n\n```json\n{\n \"path\": \"/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}\",\n \"method\": \"get\",\n \"parameters\": [\n {\n \"name\": \"saleId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target sale's ID\"\n },\n {\n \"name\": \"questionId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target question's ID\"\n },\n {\n \"name\": \"commentId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target comment's ID\"\n }\n ]\n}\n```",
|
|
1292
|
+
type: "object",
|
|
1293
|
+
properties: {
|
|
1294
|
+
name: {
|
|
1295
|
+
description: "Identifier name of the path parameter.\n\nThis name must match exactly with the parameter name in the route path.\nIt must be corresponded to the\n{@link AutoBeOpenApi.IOperation.path API operation path}.\n\nMUST use camelCase naming convention.",
|
|
1296
|
+
type: "string",
|
|
1297
|
+
pattern: "^[a-z][a-zA-Z0-9]*$"
|
|
1298
|
+
},
|
|
1299
|
+
description: {
|
|
1300
|
+
description: "Description about the path parameter.\n\nMake short, concise and clear description about the path parameter.\n\n> MUST be written in English. Never use other languages.",
|
|
1301
|
+
type: "string"
|
|
1302
|
+
},
|
|
1303
|
+
schema: {
|
|
1304
|
+
description: "Type schema of the path parameter.\n\nPath parameters are typically primitive types like\n{@link AutoBeOpenApi.IJsonSchema.IString strings},\n{@link AutoBeOpenApi.IJsonSchema.IInteger integers},\n{@link AutoBeOpenApi.IJsonSchema.INumber numbers}.\n\nIf you need other types, please use request body instead with object type\nencapsulation.",
|
|
1305
|
+
oneOf: [
|
|
1306
|
+
{
|
|
1307
|
+
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber"
|
|
1308
|
+
},
|
|
1309
|
+
{
|
|
1310
|
+
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger"
|
|
1311
|
+
},
|
|
1312
|
+
{
|
|
1313
|
+
$ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
1314
|
+
}
|
|
1315
|
+
],
|
|
1316
|
+
discriminator: {
|
|
1317
|
+
propertyName: "type",
|
|
1318
|
+
mapping: {
|
|
1319
|
+
number: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber",
|
|
1320
|
+
integer: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger",
|
|
1321
|
+
string: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
|
|
1322
|
+
}
|
|
886
1323
|
}
|
|
887
1324
|
}
|
|
888
|
-
}
|
|
889
|
-
},
|
|
890
|
-
required: [
|
|
891
|
-
"name",
|
|
892
|
-
"description",
|
|
893
|
-
"schema"
|
|
894
|
-
]
|
|
895
|
-
},
|
|
896
|
-
"AutoBeOpenApi.IJsonSchema.INumber": {
|
|
897
|
-
description: "Number (double) type info.",
|
|
898
|
-
type: "object",
|
|
899
|
-
properties: {
|
|
900
|
-
minimum: {
|
|
901
|
-
description: "Minimum value restriction.",
|
|
902
|
-
type: "number"
|
|
903
1325
|
},
|
|
904
|
-
|
|
905
|
-
|
|
906
|
-
|
|
907
|
-
|
|
908
|
-
|
|
909
|
-
description: "Exclusive minimum value restriction.",
|
|
910
|
-
type: "number"
|
|
911
|
-
},
|
|
912
|
-
exclusiveMaximum: {
|
|
913
|
-
description: "Exclusive maximum value restriction.",
|
|
914
|
-
type: "number"
|
|
915
|
-
},
|
|
916
|
-
multipleOf: {
|
|
917
|
-
description: "Multiple of value restriction.",
|
|
918
|
-
type: "number",
|
|
919
|
-
exclusiveMinimum: 0
|
|
920
|
-
},
|
|
921
|
-
type: {
|
|
922
|
-
description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
|
|
923
|
-
"const": "number"
|
|
924
|
-
}
|
|
1326
|
+
required: [
|
|
1327
|
+
"name",
|
|
1328
|
+
"description",
|
|
1329
|
+
"schema"
|
|
1330
|
+
]
|
|
925
1331
|
},
|
|
926
|
-
|
|
927
|
-
"type"
|
|
928
|
-
|
|
929
|
-
|
|
930
|
-
|
|
931
|
-
|
|
932
|
-
|
|
933
|
-
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
|
|
937
|
-
|
|
938
|
-
|
|
939
|
-
|
|
940
|
-
|
|
941
|
-
|
|
942
|
-
|
|
943
|
-
|
|
944
|
-
|
|
945
|
-
|
|
946
|
-
|
|
947
|
-
|
|
948
|
-
|
|
949
|
-
|
|
950
|
-
|
|
951
|
-
|
|
952
|
-
|
|
953
|
-
|
|
1332
|
+
"AutoBeOpenApi.IJsonSchema.INumber": {
|
|
1333
|
+
description: "Number (double) type info.",
|
|
1334
|
+
type: "object",
|
|
1335
|
+
properties: {
|
|
1336
|
+
minimum: {
|
|
1337
|
+
description: "Minimum value restriction.",
|
|
1338
|
+
type: "number"
|
|
1339
|
+
},
|
|
1340
|
+
maximum: {
|
|
1341
|
+
description: "Maximum value restriction.",
|
|
1342
|
+
type: "number"
|
|
1343
|
+
},
|
|
1344
|
+
exclusiveMinimum: {
|
|
1345
|
+
description: "Exclusive minimum value restriction.",
|
|
1346
|
+
type: "number"
|
|
1347
|
+
},
|
|
1348
|
+
exclusiveMaximum: {
|
|
1349
|
+
description: "Exclusive maximum value restriction.",
|
|
1350
|
+
type: "number"
|
|
1351
|
+
},
|
|
1352
|
+
multipleOf: {
|
|
1353
|
+
description: "Multiple of value restriction.",
|
|
1354
|
+
type: "number",
|
|
1355
|
+
exclusiveMinimum: 0
|
|
1356
|
+
},
|
|
1357
|
+
type: {
|
|
1358
|
+
description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
|
|
1359
|
+
"const": "number"
|
|
1360
|
+
}
|
|
954
1361
|
},
|
|
955
|
-
|
|
956
|
-
|
|
957
|
-
|
|
958
|
-
}
|
|
1362
|
+
required: [
|
|
1363
|
+
"type"
|
|
1364
|
+
]
|
|
959
1365
|
},
|
|
960
|
-
|
|
961
|
-
"type"
|
|
962
|
-
|
|
963
|
-
|
|
964
|
-
|
|
965
|
-
|
|
966
|
-
|
|
967
|
-
|
|
968
|
-
|
|
969
|
-
|
|
970
|
-
|
|
971
|
-
|
|
972
|
-
|
|
973
|
-
|
|
974
|
-
|
|
975
|
-
|
|
976
|
-
|
|
977
|
-
|
|
978
|
-
|
|
979
|
-
|
|
980
|
-
|
|
981
|
-
|
|
982
|
-
|
|
983
|
-
|
|
984
|
-
|
|
985
|
-
|
|
986
|
-
|
|
987
|
-
|
|
988
|
-
|
|
1366
|
+
"AutoBeOpenApi.IJsonSchema.IInteger": {
|
|
1367
|
+
description: "Integer type info.",
|
|
1368
|
+
type: "object",
|
|
1369
|
+
properties: {
|
|
1370
|
+
minimum: {
|
|
1371
|
+
description: "Minimum value restriction.",
|
|
1372
|
+
type: "integer"
|
|
1373
|
+
},
|
|
1374
|
+
maximum: {
|
|
1375
|
+
description: "Maximum value restriction.",
|
|
1376
|
+
type: "integer"
|
|
1377
|
+
},
|
|
1378
|
+
exclusiveMinimum: {
|
|
1379
|
+
description: "Exclusive minimum value restriction.",
|
|
1380
|
+
type: "number"
|
|
1381
|
+
},
|
|
1382
|
+
exclusiveMaximum: {
|
|
1383
|
+
description: "Exclusive maximum value restriction.",
|
|
1384
|
+
type: "number"
|
|
1385
|
+
},
|
|
1386
|
+
multipleOf: {
|
|
1387
|
+
description: "Multiple of value restriction.",
|
|
1388
|
+
type: "integer",
|
|
1389
|
+
exclusiveMinimum: 0
|
|
1390
|
+
},
|
|
1391
|
+
type: {
|
|
1392
|
+
description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
|
|
1393
|
+
"const": "integer"
|
|
1394
|
+
}
|
|
989
1395
|
},
|
|
990
|
-
|
|
991
|
-
|
|
992
|
-
|
|
993
|
-
}
|
|
1396
|
+
required: [
|
|
1397
|
+
"type"
|
|
1398
|
+
]
|
|
994
1399
|
},
|
|
995
|
-
|
|
996
|
-
"type"
|
|
997
|
-
|
|
998
|
-
|
|
999
|
-
|
|
1000
|
-
|
|
1001
|
-
|
|
1002
|
-
|
|
1003
|
-
|
|
1004
|
-
|
|
1005
|
-
|
|
1400
|
+
"AutoBeOpenApi.IJsonSchema.IString": {
|
|
1401
|
+
description: "String type info.",
|
|
1402
|
+
type: "object",
|
|
1403
|
+
properties: {
|
|
1404
|
+
format: {
|
|
1405
|
+
description: "Format restriction.",
|
|
1406
|
+
type: "string"
|
|
1407
|
+
},
|
|
1408
|
+
pattern: {
|
|
1409
|
+
description: "Pattern restriction.",
|
|
1410
|
+
type: "string"
|
|
1411
|
+
},
|
|
1412
|
+
contentMediaType: {
|
|
1413
|
+
description: "Content media type restriction.",
|
|
1414
|
+
type: "string"
|
|
1415
|
+
},
|
|
1416
|
+
minLength: {
|
|
1417
|
+
description: "Minimum length restriction.",
|
|
1418
|
+
type: "integer",
|
|
1419
|
+
minimum: 0
|
|
1420
|
+
},
|
|
1421
|
+
maxLength: {
|
|
1422
|
+
description: "Maximum length restriction.",
|
|
1423
|
+
type: "integer",
|
|
1424
|
+
minimum: 0
|
|
1425
|
+
},
|
|
1426
|
+
type: {
|
|
1427
|
+
description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
|
|
1428
|
+
"const": "string"
|
|
1429
|
+
}
|
|
1006
1430
|
},
|
|
1007
|
-
|
|
1008
|
-
|
|
1009
|
-
|
|
1010
|
-
}
|
|
1431
|
+
required: [
|
|
1432
|
+
"type"
|
|
1433
|
+
]
|
|
1011
1434
|
},
|
|
1012
|
-
|
|
1013
|
-
"description",
|
|
1014
|
-
"
|
|
1015
|
-
|
|
1016
|
-
|
|
1017
|
-
|
|
1018
|
-
|
|
1019
|
-
|
|
1020
|
-
|
|
1021
|
-
|
|
1022
|
-
|
|
1023
|
-
|
|
1435
|
+
"AutoBeOpenApi.IRequestBody": {
|
|
1436
|
+
description: "Request body information of OpenAPI operation.\n\nThis interface defines the structure for request bodies in API routes. It\ncorresponds to the requestBody section in OpenAPI specifications, providing\nboth a description and schema reference for the request payload.\n\nThe content-type for all request bodies is always `application/json`. Even\nwhen file uploading is required, don't use `multipart/form-data` or\n`application/x-www-form-urlencoded` content types. Instead, just define an\nURI string property in the request body schema.\n\nNote that, all body schemas must be transformable to a\n{@link AutoBeOpenApi.IJsonSchema.IReference reference} type defined in the\n{@link AutoBeOpenApi.IComponents.schemas components section} as an\n{@link AutoBeOpenApi.IJsonSchema.IObject object} type.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"requestBody\": {\n \"description\": \"Creation info of the order\",\n \"content\": {\n \"application/json\": {\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder.ICreate\"\n }\n }\n }\n }\n}\n```",
|
|
1437
|
+
type: "object",
|
|
1438
|
+
properties: {
|
|
1439
|
+
description: {
|
|
1440
|
+
description: "Description about the request body.\n\nMake short, concise and clear description about the request body.\n\n> MUST be written in English. Never use other languages.",
|
|
1441
|
+
type: "string"
|
|
1442
|
+
},
|
|
1443
|
+
typeName: {
|
|
1444
|
+
description: "Request body type name.\n\nThis specifies the data structure expected in the request body, that will\nbe transformed to {@link AutoBeOpenApi.IJsonSchema.IReference reference}\ntype in the {@link AutoBeOpenApi.IComponents.schemas components section}\nas an {@link AutoBeOpenApi.IJsonSchema.Object object} type.\n\nHere is the naming convention for the request body type:\n\n- `IEntityName.ICreate`: Request body for creation operations (POST)\n- `IEntityName.IUpdate`: Request body for update operations (PUT)\n- `IEntityName.IRequest`: Request parameters for list operations (often\n with search/pagination)\n\nWhat you write:\n\n```json\n{\n \"typeName\": \"IShoppingOrder.ICreate\"\n}\n```\n\nTransformed to:\n\n```json\n{\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder.ICreate\"\n }\n}\n```",
|
|
1445
|
+
type: "string"
|
|
1446
|
+
}
|
|
1024
1447
|
},
|
|
1025
|
-
|
|
1026
|
-
description
|
|
1027
|
-
|
|
1028
|
-
|
|
1448
|
+
required: [
|
|
1449
|
+
"description",
|
|
1450
|
+
"typeName"
|
|
1451
|
+
]
|
|
1029
1452
|
},
|
|
1030
|
-
|
|
1031
|
-
"description",
|
|
1032
|
-
"
|
|
1033
|
-
|
|
1453
|
+
"AutoBeOpenApi.IResponseBody": {
|
|
1454
|
+
description: "Response body information for OpenAPI operation.\n\nThis interface defines the structure of a successful response from an API\noperation. It provides a description of the response and a schema reference\nto define the returned data structure.\n\nThe content-type for all responses is always `application/json`. Even when\nfile downloading is required, don't use `application/octet-stream` or\n`multipart/form-data` content types. Instead, just define an URI string\nproperty in the response body schema.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"responses\": {\n \"200\": {\n \"description\": \"Order information\",\n \"content\": {\n \"application/json\": {\n \"schema\": { \"$ref\": \"#/components/schemas/IShoppingOrder\" }\n }\n }\n }\n }\n}\n```",
|
|
1455
|
+
type: "object",
|
|
1456
|
+
properties: {
|
|
1457
|
+
description: {
|
|
1458
|
+
description: "Description about the response body.\n\nMake short, concise and clear description about the response body.\n\n> MUST be written in English. Never use other languages.",
|
|
1459
|
+
type: "string"
|
|
1460
|
+
},
|
|
1461
|
+
typeName: {
|
|
1462
|
+
description: "Response body's data type.\n\nSpecifies the structure of the returned data (response body), that will\nbe transformed to {@link AutoBeOpenApi.IJsonSchema.IReference} type in the\n{@link AutoBeOpenApi.IComponents.schemas components section} as an\n{@link AutoBeOpenApi.IJsonSchema.IObject object} type.\n\nHere is the naming convention for the response body type:\n\n- `IEntityName`: Main entity with detailed information (e.g.,\n `IShoppingSale`)\n- `IEntityName.ISummary`: Simplified response version with essential\n properties\n- `IEntityName.IInvert`: Alternative view of an entity from a different\n perspective\n- `IPageIEntityName`: Paginated results container with `pagination` and\n `data` properties\n\nWhat you write:\n\n```json\n{\n \"typeName\": \"IShoppingOrder\"\n}\n```\n\nTransformed to:\n\n```json\n{\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder\"\n }\n}\n```",
|
|
1463
|
+
type: "string"
|
|
1464
|
+
}
|
|
1465
|
+
},
|
|
1466
|
+
required: [
|
|
1467
|
+
"description",
|
|
1468
|
+
"typeName"
|
|
1469
|
+
]
|
|
1470
|
+
}
|
|
1034
1471
|
}
|
|
1035
|
-
}
|
|
1036
|
-
|
|
1037
|
-
|
|
1038
|
-
|
|
1039
|
-
|
|
1040
|
-
|
|
1041
|
-
|
|
1042
|
-
|
|
1043
|
-
|
|
1044
|
-
|
|
1045
|
-
|
|
1046
|
-
|
|
1047
|
-
|
|
1048
|
-
|
|
1049
|
-
|
|
1050
|
-
|
|
1051
|
-
|
|
1052
|
-
|
|
1053
|
-
|
|
1054
|
-
|
|
1055
|
-
|
|
1056
|
-
|
|
1057
|
-
|
|
1058
|
-
|
|
1059
|
-
|
|
1060
|
-
|
|
1061
|
-
|
|
1062
|
-
|
|
1063
|
-
|
|
1064
|
-
|
|
1065
|
-
|
|
1066
|
-
|
|
1067
|
-
|
|
1068
|
-
|
|
1069
|
-
|
|
1070
|
-
|
|
1071
|
-
|
|
1072
|
-
|
|
1073
|
-
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
|
|
1085
|
-
|
|
1086
|
-
|
|
1087
|
-
|
|
1088
|
-
|
|
1089
|
-
|
|
1090
|
-
|
|
1091
|
-
|
|
1092
|
-
|
|
1093
|
-
|
|
1094
|
-
|
|
1095
|
-
|
|
1096
|
-
|
|
1097
|
-
|
|
1098
|
-
|
|
1099
|
-
|
|
1100
|
-
|
|
1101
|
-
|
|
1102
|
-
|
|
1103
|
-
|
|
1104
|
-
|
|
1105
|
-
|
|
1106
|
-
|
|
1107
|
-
|
|
1108
|
-
|
|
1109
|
-
|
|
1110
|
-
|
|
1111
|
-
|
|
1112
|
-
|
|
1113
|
-
|
|
1114
|
-
|
|
1115
|
-
|
|
1116
|
-
|
|
1117
|
-
|
|
1118
|
-
|
|
1119
|
-
|
|
1120
|
-
|
|
1121
|
-
|
|
1122
|
-
|
|
1123
|
-
|
|
1124
|
-
|
|
1125
|
-
|
|
1126
|
-
|
|
1127
|
-
|
|
1128
|
-
|
|
1129
|
-
|
|
1130
|
-
|
|
1131
|
-
|
|
1132
|
-
|
|
1133
|
-
|
|
1134
|
-
|
|
1135
|
-
|
|
1136
|
-
|
|
1137
|
-
|
|
1138
|
-
|
|
1139
|
-
|
|
1140
|
-
|
|
1141
|
-
|
|
1142
|
-
|
|
1143
|
-
|
|
1144
|
-
|
|
1145
|
-
|
|
1146
|
-
|
|
1147
|
-
|
|
1148
|
-
|
|
1149
|
-
|
|
1150
|
-
|
|
1151
|
-
|
|
1152
|
-
|
|
1153
|
-
|
|
1154
|
-
|
|
1155
|
-
|
|
1156
|
-
|
|
1157
|
-
|
|
1158
|
-
|
|
1159
|
-
|
|
1160
|
-
|
|
1161
|
-
|
|
1162
|
-
|
|
1163
|
-
|
|
1164
|
-
|
|
1165
|
-
|
|
1166
|
-
|
|
1167
|
-
|
|
1168
|
-
|
|
1169
|
-
|
|
1170
|
-
|
|
1171
|
-
|
|
1172
|
-
|
|
1173
|
-
|
|
1174
|
-
|
|
1175
|
-
|
|
1176
|
-
|
|
1177
|
-
|
|
1178
|
-
|
|
1179
|
-
|
|
1180
|
-
|
|
1181
|
-
|
|
1182
|
-
|
|
1183
|
-
|
|
1184
|
-
|
|
1185
|
-
|
|
1186
|
-
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
|
|
1198
|
-
|
|
1199
|
-
|
|
1200
|
-
|
|
1201
|
-
|
|
1202
|
-
|
|
1203
|
-
|
|
1204
|
-
|
|
1205
|
-
|
|
1206
|
-
|
|
1207
|
-
|
|
1208
|
-
|
|
1209
|
-
|
|
1210
|
-
|
|
1211
|
-
|
|
1212
|
-
|
|
1213
|
-
|
|
1214
|
-
|
|
1215
|
-
|
|
1216
|
-
|
|
1217
|
-
|
|
1218
|
-
|
|
1219
|
-
|
|
1220
|
-
|
|
1221
|
-
|
|
1222
|
-
|
|
1223
|
-
|
|
1224
|
-
|
|
1225
|
-
|
|
1226
|
-
|
|
1227
|
-
|
|
1228
|
-
|
|
1229
|
-
|
|
1230
|
-
|
|
1231
|
-
|
|
1232
|
-
|
|
1233
|
-
|
|
1234
|
-
|
|
1235
|
-
|
|
1236
|
-
|
|
1237
|
-
|
|
1238
|
-
|
|
1239
|
-
|
|
1240
|
-
|
|
1241
|
-
|
|
1242
|
-
|
|
1243
|
-
|
|
1244
|
-
|
|
1245
|
-
|
|
1246
|
-
|
|
1247
|
-
|
|
1248
|
-
|
|
1249
|
-
|
|
1250
|
-
|
|
1251
|
-
|
|
1252
|
-
|
|
1253
|
-
|
|
1254
|
-
|
|
1255
|
-
|
|
1256
|
-
|
|
1257
|
-
|
|
1258
|
-
|
|
1259
|
-
|
|
1260
|
-
|
|
1261
|
-
|
|
1262
|
-
|
|
1263
|
-
|
|
1264
|
-
|
|
1265
|
-
|
|
1266
|
-
|
|
1267
|
-
|
|
1268
|
-
|
|
1269
|
-
|
|
1270
|
-
|
|
1271
|
-
|
|
1272
|
-
|
|
1273
|
-
|
|
1274
|
-
|
|
1275
|
-
|
|
1276
|
-
|
|
1277
|
-
|
|
1278
|
-
|
|
1279
|
-
|
|
1280
|
-
|
|
1281
|
-
|
|
1282
|
-
|
|
1283
|
-
|
|
1284
|
-
|
|
1285
|
-
|
|
1286
|
-
|
|
1287
|
-
|
|
1288
|
-
|
|
1289
|
-
|
|
1290
|
-
|
|
1291
|
-
|
|
1292
|
-
|
|
1293
|
-
|
|
1294
|
-
|
|
1295
|
-
|
|
1296
|
-
|
|
1297
|
-
|
|
1298
|
-
|
|
1299
|
-
|
|
1300
|
-
|
|
1301
|
-
|
|
1302
|
-
|
|
1303
|
-
|
|
1304
|
-
|
|
1305
|
-
|
|
1306
|
-
|
|
1307
|
-
|
|
1308
|
-
|
|
1309
|
-
|
|
1310
|
-
|
|
1311
|
-
|
|
1312
|
-
|
|
1313
|
-
|
|
1314
|
-
|
|
1315
|
-
|
|
1472
|
+
},
|
|
1473
|
+
description: "Reviews a batch of API operations for quality and correctness.\n\nValidates each operation's request/response schemas, authentication\nhandling, error responses, and documentation completeness. Operations are\nmarked as passed or failed based on compliance with enterprise standards.",
|
|
1474
|
+
validate: (() => { const _io0 = input => "string" === typeof input.review && "string" === typeof input.plan && (Array.isArray(input.content) && input.content.every(elem => "object" === typeof elem && null !== elem && _io1(elem))); const _io1 = input => "string" === typeof input.prisma_schemas && "string" === typeof input.model_name && (null === input.soft_delete_column || "string" === typeof input.soft_delete_column) && "string" === typeof input.description && ("string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name)) && "string" === typeof input.specification && "string" === typeof input.summary && ("string" === typeof input.path && RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path)) && (Array.isArray(input.parameters) && input.parameters.every(elem => "object" === typeof elem && null !== elem && _io2(elem))) && (null === input.requestBody || "object" === typeof input.requestBody && null !== input.requestBody && _io6(input.requestBody)) && (null === input.responseBody || "object" === typeof input.responseBody && null !== input.responseBody && _io7(input.responseBody)) && (null === input.authorizationRole || "string" === typeof input.authorizationRole && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationRole) && 1 <= input.authorizationRole.length)) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) && "string" === typeof input.description && ("object" === typeof input.schema && null !== input.schema && _iu0(input.schema)); const _io3 = input => (undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000)) && (undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000)) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 && 0 < input.multipleOf)) && "integer" === input.type; const _io4 = input => (undefined === input.minimum || "number" === typeof input.minimum) && (undefined === input.maximum || "number" === typeof input.maximum) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && 0 < input.multipleOf) && "number" === input.type; const _io5 = input => (undefined === input.format || "string" === typeof input.format) && (undefined === input.pattern || "string" === typeof input.pattern) && (undefined === input.contentMediaType || "string" === typeof input.contentMediaType) && (undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 18446744073709552000)) && (undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 18446744073709552000)) && "string" === input.type; const _io6 = input => "string" === typeof input.description && "string" === typeof input.typeName; const _io7 = input => "string" === typeof input.description && "string" === typeof input.typeName; const _iu0 = input => (() => {
|
|
1475
|
+
if ("number" === input.type)
|
|
1476
|
+
return _io4(input);
|
|
1477
|
+
else if ("integer" === input.type)
|
|
1478
|
+
return _io3(input);
|
|
1479
|
+
else if ("string" === input.type)
|
|
1480
|
+
return _io5(input);
|
|
1481
|
+
else
|
|
1482
|
+
return false;
|
|
1483
|
+
})(); const _vo0 = (input, _path, _exceptionable = true) => ["string" === typeof input.review || _report(_exceptionable, {
|
|
1484
|
+
path: _path + ".review",
|
|
1485
|
+
expected: "string",
|
|
1486
|
+
value: input.review
|
|
1487
|
+
}), "string" === typeof input.plan || _report(_exceptionable, {
|
|
1488
|
+
path: _path + ".plan",
|
|
1489
|
+
expected: "string",
|
|
1490
|
+
value: input.plan
|
|
1491
|
+
}), (Array.isArray(input.content) || _report(_exceptionable, {
|
|
1492
|
+
path: _path + ".content",
|
|
1493
|
+
expected: "Array<IAutoBeInterfaceOperationsReviewApplication.IOperation>",
|
|
1494
|
+
value: input.content
|
|
1495
|
+
})) && input.content.map((elem, _index3) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
1496
|
+
path: _path + ".content[" + _index3 + "]",
|
|
1497
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IOperation",
|
|
1498
|
+
value: elem
|
|
1499
|
+
})) && _vo1(elem, _path + ".content[" + _index3 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
1500
|
+
path: _path + ".content[" + _index3 + "]",
|
|
1501
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IOperation",
|
|
1502
|
+
value: elem
|
|
1503
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
1504
|
+
path: _path + ".content",
|
|
1505
|
+
expected: "Array<IAutoBeInterfaceOperationsReviewApplication.IOperation>",
|
|
1506
|
+
value: input.content
|
|
1507
|
+
})].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.prisma_schemas || _report(_exceptionable, {
|
|
1508
|
+
path: _path + ".prisma_schemas",
|
|
1509
|
+
expected: "string",
|
|
1510
|
+
value: input.prisma_schemas
|
|
1511
|
+
}), "string" === typeof input.model_name || _report(_exceptionable, {
|
|
1512
|
+
path: _path + ".model_name",
|
|
1513
|
+
expected: "string",
|
|
1514
|
+
value: input.model_name
|
|
1515
|
+
}), null === input.soft_delete_column || "string" === typeof input.soft_delete_column || _report(_exceptionable, {
|
|
1516
|
+
path: _path + ".soft_delete_column",
|
|
1517
|
+
expected: "(null | string)",
|
|
1518
|
+
value: input.soft_delete_column
|
|
1519
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
1520
|
+
path: _path + ".description",
|
|
1521
|
+
expected: "string",
|
|
1522
|
+
value: input.description
|
|
1523
|
+
}), "string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
1524
|
+
path: _path + ".name",
|
|
1525
|
+
expected: "string & CamelPattern",
|
|
1526
|
+
value: input.name
|
|
1527
|
+
})) || _report(_exceptionable, {
|
|
1528
|
+
path: _path + ".name",
|
|
1529
|
+
expected: "(string & CamelPattern)",
|
|
1530
|
+
value: input.name
|
|
1531
|
+
}), "string" === typeof input.specification || _report(_exceptionable, {
|
|
1532
|
+
path: _path + ".specification",
|
|
1533
|
+
expected: "string",
|
|
1534
|
+
value: input.specification
|
|
1535
|
+
}), "string" === typeof input.summary || _report(_exceptionable, {
|
|
1536
|
+
path: _path + ".summary",
|
|
1537
|
+
expected: "string",
|
|
1538
|
+
value: input.summary
|
|
1539
|
+
}), "string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
|
|
1540
|
+
path: _path + ".path",
|
|
1541
|
+
expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
|
|
1542
|
+
value: input.path
|
|
1543
|
+
})) || _report(_exceptionable, {
|
|
1544
|
+
path: _path + ".path",
|
|
1545
|
+
expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
|
|
1546
|
+
value: input.path
|
|
1547
|
+
}), (Array.isArray(input.parameters) || _report(_exceptionable, {
|
|
1548
|
+
path: _path + ".parameters",
|
|
1549
|
+
expected: "Array<AutoBeOpenApi.IParameter>",
|
|
1550
|
+
value: input.parameters
|
|
1551
|
+
})) && input.parameters.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
|
|
1552
|
+
path: _path + ".parameters[" + _index4 + "]",
|
|
1553
|
+
expected: "AutoBeOpenApi.IParameter",
|
|
1554
|
+
value: elem
|
|
1555
|
+
})) && _vo2(elem, _path + ".parameters[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
|
|
1556
|
+
path: _path + ".parameters[" + _index4 + "]",
|
|
1557
|
+
expected: "AutoBeOpenApi.IParameter",
|
|
1558
|
+
value: elem
|
|
1559
|
+
})).every(flag => flag) || _report(_exceptionable, {
|
|
1560
|
+
path: _path + ".parameters",
|
|
1561
|
+
expected: "Array<AutoBeOpenApi.IParameter>",
|
|
1562
|
+
value: input.parameters
|
|
1563
|
+
}), null === input.requestBody || ("object" === typeof input.requestBody && null !== input.requestBody || _report(_exceptionable, {
|
|
1564
|
+
path: _path + ".requestBody",
|
|
1565
|
+
expected: "(AutoBeOpenApi.IRequestBody | null)",
|
|
1566
|
+
value: input.requestBody
|
|
1567
|
+
})) && _vo6(input.requestBody, _path + ".requestBody", true && _exceptionable) || _report(_exceptionable, {
|
|
1568
|
+
path: _path + ".requestBody",
|
|
1569
|
+
expected: "(AutoBeOpenApi.IRequestBody | null)",
|
|
1570
|
+
value: input.requestBody
|
|
1571
|
+
}), null === input.responseBody || ("object" === typeof input.responseBody && null !== input.responseBody || _report(_exceptionable, {
|
|
1572
|
+
path: _path + ".responseBody",
|
|
1573
|
+
expected: "(AutoBeOpenApi.IResponseBody | null)",
|
|
1574
|
+
value: input.responseBody
|
|
1575
|
+
})) && _vo7(input.responseBody, _path + ".responseBody", true && _exceptionable) || _report(_exceptionable, {
|
|
1576
|
+
path: _path + ".responseBody",
|
|
1577
|
+
expected: "(AutoBeOpenApi.IResponseBody | null)",
|
|
1578
|
+
value: input.responseBody
|
|
1579
|
+
}), null === input.authorizationRole || "string" === typeof input.authorizationRole && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationRole) || _report(_exceptionable, {
|
|
1580
|
+
path: _path + ".authorizationRole",
|
|
1581
|
+
expected: "string & CamelPattern",
|
|
1582
|
+
value: input.authorizationRole
|
|
1583
|
+
})) && (1 <= input.authorizationRole.length || _report(_exceptionable, {
|
|
1584
|
+
path: _path + ".authorizationRole",
|
|
1585
|
+
expected: "string & MinLength<1>",
|
|
1586
|
+
value: input.authorizationRole
|
|
1587
|
+
})) || _report(_exceptionable, {
|
|
1588
|
+
path: _path + ".authorizationRole",
|
|
1589
|
+
expected: "((string & CamelPattern & MinLength<1>) | null)",
|
|
1590
|
+
value: input.authorizationRole
|
|
1591
|
+
}), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
|
|
1592
|
+
path: _path + ".method",
|
|
1593
|
+
expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
|
|
1594
|
+
value: input.method
|
|
1595
|
+
})].every(flag => flag); const _vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
|
|
1596
|
+
path: _path + ".name",
|
|
1597
|
+
expected: "string & CamelPattern",
|
|
1598
|
+
value: input.name
|
|
1599
|
+
})) || _report(_exceptionable, {
|
|
1600
|
+
path: _path + ".name",
|
|
1601
|
+
expected: "(string & CamelPattern)",
|
|
1602
|
+
value: input.name
|
|
1603
|
+
}), "string" === typeof input.description || _report(_exceptionable, {
|
|
1604
|
+
path: _path + ".description",
|
|
1605
|
+
expected: "string",
|
|
1606
|
+
value: input.description
|
|
1607
|
+
}), ("object" === typeof input.schema && null !== input.schema || _report(_exceptionable, {
|
|
1608
|
+
path: _path + ".schema",
|
|
1609
|
+
expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
|
|
1610
|
+
value: input.schema
|
|
1611
|
+
})) && _vu0(input.schema, _path + ".schema", true && _exceptionable) || _report(_exceptionable, {
|
|
1612
|
+
path: _path + ".schema",
|
|
1613
|
+
expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
|
|
1614
|
+
value: input.schema
|
|
1615
|
+
})].every(flag => flag); const _vo3 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000 || _report(_exceptionable, {
|
|
1616
|
+
path: _path + ".minimum",
|
|
1617
|
+
expected: "number & Type<\"int64\">",
|
|
1618
|
+
value: input.minimum
|
|
1619
|
+
})) || _report(_exceptionable, {
|
|
1620
|
+
path: _path + ".minimum",
|
|
1621
|
+
expected: "((number & Type<\"int64\">) | undefined)",
|
|
1622
|
+
value: input.minimum
|
|
1623
|
+
}), undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000 || _report(_exceptionable, {
|
|
1624
|
+
path: _path + ".maximum",
|
|
1625
|
+
expected: "number & Type<\"int64\">",
|
|
1626
|
+
value: input.maximum
|
|
1627
|
+
})) || _report(_exceptionable, {
|
|
1628
|
+
path: _path + ".maximum",
|
|
1629
|
+
expected: "((number & Type<\"int64\">) | undefined)",
|
|
1630
|
+
value: input.maximum
|
|
1631
|
+
}), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
|
|
1632
|
+
path: _path + ".exclusiveMinimum",
|
|
1633
|
+
expected: "(number | undefined)",
|
|
1634
|
+
value: input.exclusiveMinimum
|
|
1635
|
+
}), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
|
|
1636
|
+
path: _path + ".exclusiveMaximum",
|
|
1637
|
+
expected: "(number | undefined)",
|
|
1638
|
+
value: input.exclusiveMaximum
|
|
1639
|
+
}), undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 || _report(_exceptionable, {
|
|
1640
|
+
path: _path + ".multipleOf",
|
|
1641
|
+
expected: "number & Type<\"uint64\">",
|
|
1642
|
+
value: input.multipleOf
|
|
1643
|
+
})) && (0 < input.multipleOf || _report(_exceptionable, {
|
|
1644
|
+
path: _path + ".multipleOf",
|
|
1645
|
+
expected: "number & ExclusiveMinimum<0>",
|
|
1646
|
+
value: input.multipleOf
|
|
1647
|
+
})) || _report(_exceptionable, {
|
|
1648
|
+
path: _path + ".multipleOf",
|
|
1649
|
+
expected: "((number & Type<\"uint64\"> & ExclusiveMinimum<0>) | undefined)",
|
|
1650
|
+
value: input.multipleOf
|
|
1651
|
+
}), "integer" === input.type || _report(_exceptionable, {
|
|
1652
|
+
path: _path + ".type",
|
|
1653
|
+
expected: "\"integer\"",
|
|
1654
|
+
value: input.type
|
|
1655
|
+
})].every(flag => flag); const _vo4 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum || _report(_exceptionable, {
|
|
1656
|
+
path: _path + ".minimum",
|
|
1657
|
+
expected: "(number | undefined)",
|
|
1658
|
+
value: input.minimum
|
|
1659
|
+
}), undefined === input.maximum || "number" === typeof input.maximum || _report(_exceptionable, {
|
|
1660
|
+
path: _path + ".maximum",
|
|
1661
|
+
expected: "(number | undefined)",
|
|
1662
|
+
value: input.maximum
|
|
1663
|
+
}), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
|
|
1664
|
+
path: _path + ".exclusiveMinimum",
|
|
1665
|
+
expected: "(number | undefined)",
|
|
1666
|
+
value: input.exclusiveMinimum
|
|
1667
|
+
}), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
|
|
1668
|
+
path: _path + ".exclusiveMaximum",
|
|
1669
|
+
expected: "(number | undefined)",
|
|
1670
|
+
value: input.exclusiveMaximum
|
|
1671
|
+
}), undefined === input.multipleOf || "number" === typeof input.multipleOf && (0 < input.multipleOf || _report(_exceptionable, {
|
|
1672
|
+
path: _path + ".multipleOf",
|
|
1673
|
+
expected: "number & ExclusiveMinimum<0>",
|
|
1674
|
+
value: input.multipleOf
|
|
1675
|
+
})) || _report(_exceptionable, {
|
|
1676
|
+
path: _path + ".multipleOf",
|
|
1677
|
+
expected: "((number & ExclusiveMinimum<0>) | undefined)",
|
|
1678
|
+
value: input.multipleOf
|
|
1679
|
+
}), "number" === input.type || _report(_exceptionable, {
|
|
1680
|
+
path: _path + ".type",
|
|
1681
|
+
expected: "\"number\"",
|
|
1682
|
+
value: input.type
|
|
1683
|
+
})].every(flag => flag); const _vo5 = (input, _path, _exceptionable = true) => [undefined === input.format || "string" === typeof input.format || _report(_exceptionable, {
|
|
1684
|
+
path: _path + ".format",
|
|
1685
|
+
expected: "(string | undefined)",
|
|
1686
|
+
value: input.format
|
|
1687
|
+
}), undefined === input.pattern || "string" === typeof input.pattern || _report(_exceptionable, {
|
|
1688
|
+
path: _path + ".pattern",
|
|
1689
|
+
expected: "(string | undefined)",
|
|
1690
|
+
value: input.pattern
|
|
1691
|
+
}), undefined === input.contentMediaType || "string" === typeof input.contentMediaType || _report(_exceptionable, {
|
|
1692
|
+
path: _path + ".contentMediaType",
|
|
1693
|
+
expected: "(string | undefined)",
|
|
1694
|
+
value: input.contentMediaType
|
|
1695
|
+
}), undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 18446744073709552000 || _report(_exceptionable, {
|
|
1696
|
+
path: _path + ".minLength",
|
|
1697
|
+
expected: "number & Type<\"uint64\">",
|
|
1698
|
+
value: input.minLength
|
|
1699
|
+
})) || _report(_exceptionable, {
|
|
1700
|
+
path: _path + ".minLength",
|
|
1701
|
+
expected: "((number & Type<\"uint64\">) | undefined)",
|
|
1702
|
+
value: input.minLength
|
|
1703
|
+
}), undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 18446744073709552000 || _report(_exceptionable, {
|
|
1704
|
+
path: _path + ".maxLength",
|
|
1705
|
+
expected: "number & Type<\"uint64\">",
|
|
1706
|
+
value: input.maxLength
|
|
1707
|
+
})) || _report(_exceptionable, {
|
|
1708
|
+
path: _path + ".maxLength",
|
|
1709
|
+
expected: "((number & Type<\"uint64\">) | undefined)",
|
|
1710
|
+
value: input.maxLength
|
|
1711
|
+
}), "string" === input.type || _report(_exceptionable, {
|
|
1712
|
+
path: _path + ".type",
|
|
1713
|
+
expected: "\"string\"",
|
|
1714
|
+
value: input.type
|
|
1715
|
+
})].every(flag => flag); const _vo6 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
|
|
1716
|
+
path: _path + ".description",
|
|
1717
|
+
expected: "string",
|
|
1718
|
+
value: input.description
|
|
1719
|
+
}), "string" === typeof input.typeName || _report(_exceptionable, {
|
|
1720
|
+
path: _path + ".typeName",
|
|
1721
|
+
expected: "string",
|
|
1722
|
+
value: input.typeName
|
|
1723
|
+
})].every(flag => flag); const _vo7 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
|
|
1724
|
+
path: _path + ".description",
|
|
1725
|
+
expected: "string",
|
|
1726
|
+
value: input.description
|
|
1727
|
+
}), "string" === typeof input.typeName || _report(_exceptionable, {
|
|
1728
|
+
path: _path + ".typeName",
|
|
1729
|
+
expected: "string",
|
|
1730
|
+
value: input.typeName
|
|
1731
|
+
})].every(flag => flag); const _vu0 = (input, _path, _exceptionable = true) => (() => {
|
|
1732
|
+
if ("number" === input.type)
|
|
1733
|
+
return _vo4(input, _path, true && _exceptionable);
|
|
1734
|
+
else if ("integer" === input.type)
|
|
1735
|
+
return _vo3(input, _path, true && _exceptionable);
|
|
1736
|
+
else if ("string" === input.type)
|
|
1737
|
+
return _vo5(input, _path, true && _exceptionable);
|
|
1738
|
+
else
|
|
1739
|
+
return _report(_exceptionable, {
|
|
1740
|
+
path: _path,
|
|
1741
|
+
expected: "(AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.IString)",
|
|
1742
|
+
value: input
|
|
1743
|
+
});
|
|
1744
|
+
})(); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
|
|
1745
|
+
if (false === __is(input)) {
|
|
1746
|
+
errors = [];
|
|
1747
|
+
_report = __typia_transform__validateReport._validateReport(errors);
|
|
1748
|
+
((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
|
|
1749
|
+
path: _path + "",
|
|
1750
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IProps",
|
|
1751
|
+
value: input
|
|
1752
|
+
})) && _vo0(input, _path + "", true) || _report(true, {
|
|
1753
|
+
path: _path + "",
|
|
1754
|
+
expected: "IAutoBeInterfaceOperationsReviewApplication.IProps",
|
|
1755
|
+
value: input
|
|
1756
|
+
}))(input, "$input", true);
|
|
1757
|
+
const success = 0 === errors.length;
|
|
1758
|
+
return success ? {
|
|
1759
|
+
success,
|
|
1760
|
+
data: input
|
|
1761
|
+
} : {
|
|
1762
|
+
success,
|
|
1763
|
+
errors,
|
|
1764
|
+
data: input
|
|
1765
|
+
};
|
|
1766
|
+
}
|
|
1767
|
+
return {
|
|
1768
|
+
success: true,
|
|
1316
1769
|
data: input
|
|
1317
1770
|
};
|
|
1318
|
-
}
|
|
1319
|
-
|
|
1320
|
-
|
|
1321
|
-
|
|
1322
|
-
|
|
1323
|
-
|
|
1324
|
-
|
|
1325
|
-
|
|
1326
|
-
|
|
1771
|
+
}; })()
|
|
1772
|
+
}
|
|
1773
|
+
]
|
|
1774
|
+
};
|
|
1775
|
+
__typia_transform__llmApplicationFinalize._llmApplicationFinalize(application, Object.assign(Object.assign({}, {
|
|
1776
|
+
validate: {
|
|
1777
|
+
reviewOperations: validate,
|
|
1778
|
+
},
|
|
1779
|
+
}), { equals: false }));
|
|
1780
|
+
return application;
|
|
1781
|
+
})(),
|
|
1327
1782
|
};
|
|
1328
1783
|
//# sourceMappingURL=orchestrateInterfaceOperationsReview.js.map
|