@autobe/agent 0.14.6 → 0.15.1

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.
Files changed (152) hide show
  1. package/lib/AutoBeMockAgent.js +1 -1
  2. package/lib/AutoBeMockAgent.js.map +1 -1
  3. package/lib/constants/AutoBeSystemPromptConstant.d.ts +10 -8
  4. package/lib/constants/AutoBeSystemPromptConstant.js.map +1 -1
  5. package/lib/index.mjs +1276 -834
  6. package/lib/index.mjs.map +1 -1
  7. package/lib/orchestrate/analyze/orchestrateAnalyzeReviewer.js +4 -9
  8. package/lib/orchestrate/analyze/orchestrateAnalyzeReviewer.js.map +1 -1
  9. package/lib/orchestrate/analyze/orchestrateAnalyzeWrite.js +2 -8
  10. package/lib/orchestrate/analyze/orchestrateAnalyzeWrite.js.map +1 -1
  11. package/lib/orchestrate/analyze/transformAnalyzeReviewerHistories.js +1 -1
  12. package/lib/orchestrate/analyze/transformAnalyzeReviewerHistories.js.map +1 -1
  13. package/lib/orchestrate/analyze/transformAnalyzeWriteHistories.js +1 -1
  14. package/lib/orchestrate/analyze/transformAnalyzeWriteHistories.js.map +1 -1
  15. package/lib/orchestrate/interface/histories/transformInterfaceAssetHistories.d.ts +3 -0
  16. package/lib/orchestrate/interface/histories/transformInterfaceAssetHistories.js +65 -0
  17. package/lib/orchestrate/interface/histories/transformInterfaceAssetHistories.js.map +1 -0
  18. package/lib/orchestrate/interface/histories/transformInterfaceComplementHistories.d.ts +4 -0
  19. package/lib/orchestrate/interface/histories/transformInterfaceComplementHistories.js +62 -0
  20. package/lib/orchestrate/interface/histories/transformInterfaceComplementHistories.js.map +1 -0
  21. package/lib/orchestrate/interface/histories/transformInterfaceEndpointHistories.d.ts +4 -0
  22. package/lib/orchestrate/interface/histories/transformInterfaceEndpointHistories.js +28 -0
  23. package/lib/orchestrate/interface/histories/transformInterfaceEndpointHistories.js.map +1 -0
  24. package/lib/orchestrate/interface/histories/transformInterfaceGroupHistories.d.ts +3 -0
  25. package/lib/orchestrate/interface/histories/transformInterfaceGroupHistories.js +28 -0
  26. package/lib/orchestrate/interface/histories/transformInterfaceGroupHistories.js.map +1 -0
  27. package/lib/orchestrate/interface/histories/transformInterfaceOperationHistories.d.ts +4 -0
  28. package/lib/orchestrate/interface/histories/transformInterfaceOperationHistories.js +28 -0
  29. package/lib/orchestrate/interface/histories/transformInterfaceOperationHistories.js.map +1 -0
  30. package/lib/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.d.ts +3 -0
  31. package/lib/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.js +63 -0
  32. package/lib/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.js.map +1 -0
  33. package/lib/orchestrate/interface/histories/transformInterfaceSchemaHistories.d.ts +4 -0
  34. package/lib/orchestrate/interface/histories/transformInterfaceSchemaHistories.js +28 -0
  35. package/lib/orchestrate/interface/histories/transformInterfaceSchemaHistories.js.map +1 -0
  36. package/lib/orchestrate/interface/orchestrateInterface.js +14 -9
  37. package/lib/orchestrate/interface/orchestrateInterface.js.map +1 -1
  38. package/lib/orchestrate/interface/orchestrateInterfaceComplement.d.ts +1 -1
  39. package/lib/orchestrate/interface/orchestrateInterfaceComplement.js +13 -40
  40. package/lib/orchestrate/interface/orchestrateInterfaceComplement.js.map +1 -1
  41. package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.d.ts +3 -2
  42. package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js +52 -32
  43. package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js.map +1 -1
  44. package/lib/orchestrate/interface/orchestrateInterfaceGroups.d.ts +4 -0
  45. package/lib/orchestrate/interface/orchestrateInterfaceGroups.js +350 -0
  46. package/lib/orchestrate/interface/orchestrateInterfaceGroups.js.map +1 -0
  47. package/lib/orchestrate/interface/orchestrateInterfaceOperations.js +249 -225
  48. package/lib/orchestrate/interface/orchestrateInterfaceOperations.js.map +1 -1
  49. package/lib/orchestrate/interface/orchestrateInterfaceSchemas.d.ts +4 -0
  50. package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js +411 -0
  51. package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js.map +1 -0
  52. package/lib/orchestrate/interface/structures/IAutoBeInterfaceComplementApplication.d.ts +55 -0
  53. package/lib/orchestrate/interface/structures/IAutoBeInterfaceComplementApplication.js +3 -0
  54. package/lib/orchestrate/interface/structures/IAutoBeInterfaceComplementApplication.js.map +1 -0
  55. package/lib/orchestrate/interface/structures/IAutoBeInterfaceEndpointApplication.d.ts +23 -0
  56. package/lib/orchestrate/interface/structures/IAutoBeInterfaceEndpointApplication.js +3 -0
  57. package/lib/orchestrate/interface/structures/IAutoBeInterfaceEndpointApplication.js.map +1 -0
  58. package/lib/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.d.ts +108 -0
  59. package/lib/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.js +3 -0
  60. package/lib/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.js.map +1 -0
  61. package/lib/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.d.ts +122 -0
  62. package/lib/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.js +3 -0
  63. package/lib/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.js.map +1 -0
  64. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.d.ts +75 -0
  65. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.js +3 -0
  66. package/lib/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.js.map +1 -0
  67. package/lib/orchestrate/interface/{OpenApiEndpointComparator.d.ts → utils/OpenApiEndpointComparator.d.ts} +1 -0
  68. package/lib/orchestrate/interface/{OpenApiEndpointComparator.js → utils/OpenApiEndpointComparator.js} +6 -0
  69. package/lib/orchestrate/interface/utils/OpenApiEndpointComparator.js.map +1 -0
  70. package/lib/orchestrate/realize/orchestrateRealize.js +16 -2
  71. package/lib/orchestrate/realize/orchestrateRealize.js.map +1 -1
  72. package/lib/orchestrate/realize/orchestrateRealizeAuthorization.js +5 -7
  73. package/lib/orchestrate/realize/orchestrateRealizeAuthorization.js.map +1 -1
  74. package/lib/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js +2 -2
  75. package/lib/orchestrate/realize/orchestrateRealizeCoder.js +3 -2
  76. package/lib/orchestrate/realize/orchestrateRealizeCoder.js.map +1 -1
  77. package/lib/orchestrate/realize/structures/IAutoBeRealizeAuthorizationCorrectApplication.d.ts +1 -1
  78. package/lib/orchestrate/realize/structures/IAutoBeRealizeCompile.d.ts +34 -13
  79. package/lib/orchestrate/realize/transformRealizeAuthorization.js +1 -1
  80. package/lib/orchestrate/realize/transformRealizeAuthorization.js.map +1 -1
  81. package/lib/orchestrate/realize/transformRealizeAuthorizationCorrectHistories.js +1 -1
  82. package/lib/orchestrate/realize/transformRealizeAuthorizationCorrectHistories.js.map +1 -1
  83. package/lib/orchestrate/realize/transformRealizeCoderHistories.js +5 -5
  84. package/lib/orchestrate/realize/transformRealizeCoderHistories.js.map +1 -1
  85. package/lib/orchestrate/realize/utils/InternalFileSystem.d.ts +8 -0
  86. package/lib/orchestrate/realize/utils/InternalFileSystem.js +17 -0
  87. package/lib/orchestrate/realize/utils/InternalFileSystem.js.map +1 -0
  88. package/lib/orchestrate/realize/utils/ProviderFileSystem.d.ts +3 -0
  89. package/lib/orchestrate/realize/utils/ProviderFileSystem.js +8 -0
  90. package/lib/orchestrate/realize/utils/ProviderFileSystem.js.map +1 -0
  91. package/lib/orchestrate/realize/utils/replaceImportStatements.js +2 -2
  92. package/lib/orchestrate/realize/utils/replaceImportStatements.js.map +1 -1
  93. package/lib/orchestrate/realize/writeCodeUntilCompilePassed.js +36 -36
  94. package/lib/orchestrate/realize/writeCodeUntilCompilePassed.js.map +1 -1
  95. package/lib/orchestrate/test/compile/getTestScenarioArtifacts.js +1 -0
  96. package/lib/orchestrate/test/compile/getTestScenarioArtifacts.js.map +1 -1
  97. package/lib/orchestrate/test/orchestrateTestScenario.js +29 -13
  98. package/lib/orchestrate/test/orchestrateTestScenario.js.map +1 -1
  99. package/lib/orchestrate/test/transformTestWriteHistories.js +3 -2
  100. package/lib/orchestrate/test/transformTestWriteHistories.js.map +1 -1
  101. package/lib/utils/arrayToRecord.d.ts +17 -0
  102. package/lib/utils/arrayToRecord.js +19 -0
  103. package/lib/utils/arrayToRecord.js.map +1 -0
  104. package/lib/utils/backoffRetry.js +0 -1
  105. package/lib/utils/backoffRetry.js.map +1 -1
  106. package/package.json +5 -5
  107. package/src/AutoBeMockAgent.ts +1 -1
  108. package/src/constants/AutoBeSystemPromptConstant.ts +10 -8
  109. package/src/orchestrate/analyze/orchestrateAnalyzeReviewer.ts +1 -3
  110. package/src/orchestrate/analyze/orchestrateAnalyzeWrite.ts +1 -3
  111. package/src/orchestrate/interface/histories/transformInterfaceAssetHistories.ts +75 -0
  112. package/src/orchestrate/interface/histories/transformInterfaceComplementHistories.ts +69 -0
  113. package/src/orchestrate/interface/histories/transformInterfaceEndpointHistories.ts +34 -0
  114. package/src/orchestrate/interface/histories/transformInterfaceGroupHistories.ts +32 -0
  115. package/src/orchestrate/interface/histories/transformInterfaceOperationHistories.ts +34 -0
  116. package/src/orchestrate/interface/histories/transformInterfacePrerequisiteHistories.ts +66 -0
  117. package/src/orchestrate/interface/histories/transformInterfaceSchemaHistories.ts +34 -0
  118. package/src/orchestrate/interface/orchestrateInterface.ts +17 -8
  119. package/src/orchestrate/interface/orchestrateInterfaceComplement.ts +22 -97
  120. package/src/orchestrate/interface/orchestrateInterfaceEndpoints.ts +48 -55
  121. package/src/orchestrate/interface/orchestrateInterfaceGroups.ts +109 -0
  122. package/src/orchestrate/interface/orchestrateInterfaceOperations.ts +81 -120
  123. package/src/orchestrate/interface/orchestrateInterfaceSchemas.ts +197 -0
  124. package/src/orchestrate/interface/structures/IAutoBeInterfaceComplementApplication.ts +58 -0
  125. package/src/orchestrate/interface/structures/IAutoBeInterfaceEndpointApplication.ts +24 -0
  126. package/src/orchestrate/interface/structures/IAutoBeInterfaceGroupApplication.ts +112 -0
  127. package/src/orchestrate/interface/structures/IAutoBeInterfaceOperationApplication.ts +125 -0
  128. package/src/orchestrate/interface/structures/IAutoBeInterfaceSchemaApplication.ts +76 -0
  129. package/src/orchestrate/interface/{OpenApiEndpointComparator.ts → utils/OpenApiEndpointComparator.ts} +8 -0
  130. package/src/orchestrate/realize/orchestrateRealize.ts +19 -2
  131. package/src/orchestrate/realize/orchestrateRealizeAuthorization.ts +6 -19
  132. package/src/orchestrate/realize/orchestrateRealizeCoder.ts +3 -6
  133. package/src/orchestrate/realize/structures/IAutoBeRealizeAuthorizationCorrectApplication.ts +1 -1
  134. package/src/orchestrate/realize/structures/IAutoBeRealizeCompile.ts +42 -24
  135. package/src/orchestrate/realize/transformRealizeCoderHistories.ts +4 -4
  136. package/src/orchestrate/realize/utils/InternalFileSystem.ts +12 -0
  137. package/src/orchestrate/realize/utils/ProviderFileSystem.ts +4 -0
  138. package/src/orchestrate/realize/utils/replaceImportStatements.ts +2 -2
  139. package/src/orchestrate/realize/writeCodeUntilCompilePassed.ts +59 -53
  140. package/src/orchestrate/test/compile/getTestScenarioArtifacts.ts +1 -0
  141. package/src/orchestrate/test/orchestrateTestScenario.ts +4 -2
  142. package/src/utils/arrayToRecord.ts +49 -0
  143. package/src/utils/backoffRetry.ts +0 -1
  144. package/lib/orchestrate/interface/OpenApiEndpointComparator.js.map +0 -1
  145. package/lib/orchestrate/interface/orchestrateInterfaceComponents.d.ts +0 -4
  146. package/lib/orchestrate/interface/orchestrateInterfaceComponents.js +0 -473
  147. package/lib/orchestrate/interface/orchestrateInterfaceComponents.js.map +0 -1
  148. package/lib/orchestrate/interface/transformInterfaceHistories.d.ts +0 -3
  149. package/lib/orchestrate/interface/transformInterfaceHistories.js +0 -149
  150. package/lib/orchestrate/interface/transformInterfaceHistories.js.map +0 -1
  151. package/src/orchestrate/interface/orchestrateInterfaceComponents.ts +0 -292
  152. package/src/orchestrate/interface/transformInterfaceHistories.ts +0 -152
@@ -50,32 +50,27 @@ const __typia_transform__validateReport = __importStar(require("typia/lib/intern
50
50
  const core_1 = require("@agentica/core");
51
51
  const tstl_1 = require("tstl");
52
52
  const typia_1 = __importDefault(require("typia"));
53
+ const NamingConvention_1 = require("typia/lib/utils/NamingConvention");
53
54
  const assertSchemaModel_1 = require("../../context/assertSchemaModel");
54
55
  const divideArray_1 = require("../../utils/divideArray");
55
56
  const enforceToolCall_1 = require("../../utils/enforceToolCall");
56
57
  const forceRetry_1 = require("../../utils/forceRetry");
57
- const OpenApiEndpointComparator_1 = require("./OpenApiEndpointComparator");
58
- const transformInterfaceHistories_1 = require("./transformInterfaceHistories");
58
+ const transformInterfaceOperationHistories_1 = require("./histories/transformInterfaceOperationHistories");
59
+ const OpenApiEndpointComparator_1 = require("./utils/OpenApiEndpointComparator");
59
60
  function orchestrateInterfaceOperations(ctx_1, endpoints_1) {
60
61
  return __awaiter(this, arguments, void 0, function* (ctx, endpoints, capacity = 12) {
61
62
  const matrix = (0, divideArray_1.divideArray)({
62
63
  array: endpoints,
63
64
  capacity,
64
65
  });
65
- let completed = 0;
66
+ const progress = {
67
+ total: endpoints.length,
68
+ completed: 0,
69
+ };
66
70
  const operations = yield Promise.all(matrix.map((it) => __awaiter(this, void 0, void 0, function* () {
67
71
  var _a, _b;
68
- const row = yield divideAndConquer(ctx, it, 3, (count) => {
69
- completed += count;
70
- });
71
- ctx.dispatch({
72
- type: "interfaceOperations",
73
- operations: row,
74
- completed,
75
- total: endpoints.length,
76
- step: (_b = (_a = ctx.state().analyze) === null || _a === void 0 ? void 0 : _a.step) !== null && _b !== void 0 ? _b : 0,
77
- created_at: new Date().toISOString(),
78
- });
72
+ const row = yield divideAndConquer(ctx, it, 3, progress);
73
+ ctx.dispatch(Object.assign(Object.assign({ type: "interfaceOperations", operations: row }, progress), { step: (_b = (_a = ctx.state().analyze) === null || _a === void 0 ? void 0 : _a.step) !== null && _b !== void 0 ? _b : 0, created_at: new Date().toISOString() }));
79
74
  return row;
80
75
  })));
81
76
  return operations.flat();
@@ -88,21 +83,19 @@ function divideAndConquer(ctx, endpoints, retry, progress) {
88
83
  for (let i = 0; i < retry; ++i) {
89
84
  if (remained.empty() === true || operations.size() >= endpoints.length)
90
85
  break;
91
- const before = operations.size();
92
- const newbie = yield (0, forceRetry_1.forceRetry)(() => process(ctx, Array.from(remained)));
86
+ const newbie = yield (0, forceRetry_1.forceRetry)(() => process(ctx, Array.from(remained), progress));
93
87
  for (const item of newbie) {
94
88
  operations.set(item, item);
95
89
  remained.erase(item);
96
90
  }
97
- if (operations.size() - before !== 0)
98
- progress(operations.size() - before);
99
91
  }
100
92
  return operations.toJSON().map((it) => it.second);
101
93
  });
102
94
  }
103
- function process(ctx, endpoints) {
95
+ function process(ctx, endpoints, progress) {
104
96
  return __awaiter(this, void 0, void 0, function* () {
105
97
  var _a, _b, _c;
98
+ const prefix = NamingConvention_1.NamingConvention.camel(ctx.state().analyze.prefix);
106
99
  const pointer = {
107
100
  value: null,
108
101
  };
@@ -112,38 +105,39 @@ function process(ctx, endpoints) {
112
105
  config: Object.assign(Object.assign({}, ((_a = ctx.config) !== null && _a !== void 0 ? _a : {})), { executor: {
113
106
  describe: null,
114
107
  } }),
115
- histories: (0, transformInterfaceHistories_1.transformInterfaceHistories)(ctx.state(), "# API Endpoint Generator System Prompt\n\n## 1. Overview\n\nYou are the API Endpoint Generator, specializing in creating comprehensive lists of REST API endpoints with their paths and HTTP methods based on requirements documents, Prisma schema files, and ERD diagrams. You must output your results by calling the `makeEndpoints()` function.\n\n## 2. Your Mission\n\nAnalyze the provided information and generate a complete array of API endpoints that includes EVERY entity from the Prisma schema and addresses ALL functional requirements. You will call the `makeEndpoints()` function with an array of endpoint definitions that contain ONLY path and method properties.\n\n## 2.1. Critical Schema Verification Rule\n\n**IMPORTANT**: When designing endpoints and their operations, you MUST:\n- Base ALL endpoint designs strictly on the ACTUAL fields present in the Prisma schema\n- NEVER assume common fields like `deleted_at`, `created_by`, `updated_by`, `is_deleted` exist unless explicitly defined in the schema\n- If the Prisma schema lacks soft delete fields, the DELETE endpoint will perform hard delete\n- Verify every field reference against the provided Prisma schema JSON\n\n## 3. Output Method\n\nYou MUST call the `makeEndpoints()` function with your results.\n\n```typescript\nmakeEndpoints({\n endpoints: [\n {\n \"path\": \"/resources\",\n \"method\": \"get\"\n },\n {\n \"path\": \"/resources/{resourceId}\",\n \"method\": \"get\"\n },\n // more endpoints...\n ],\n});\n```\n\n## 4. Endpoint Design Principles\n\n### 4.1. Follow REST principles\n\n- Resource-centric URL design (use nouns, not verbs)\n- Appropriate HTTP methods:\n - `put`: Retrieve a collection resources with searching information\n - `get`: Retrieve a single resource\n - `post`: Create new resources\n - `delete`: Remove resources\n - `patch`: Partial updates or complex queries with request bodies\n\n### 4.2. Path Formatting Rules\n\n1. **Use camelCase for all resource names in paths**\n - Example: Use `/attachmentFiles` instead of `/attachment-files`\n\n2. **Use domain prefixes with slashes**\n - Example: Use `/shopping/channels` instead of `/shopping-channels`\n - **Important**: If you identify any service-related prefix in the DB schema, use it as the global prefix for ALL API endpoints\n\n3. **Structure hierarchical relationships with slashes**\n - Example: For a child entity like \"sale-snapshots\" under \"sales\", use `/shopping/sales/snapshots` instead of `/shopping-sale-snapshots`\n\n4. **Use role-based path prefixes for access control**\n - **Role-specific endpoints**: Prefix with `/{role}/` where role matches the actual roles in your system\n - **Owner-specific endpoints**: Always use `/my/` prefix for resources owned by the authenticated user\n - **Public endpoints**: No special prefix\n \n **Dynamic role mapping** (adapt to your actual roles):\n - If your system has `admin` role \u2192 use `/admin/`\n - If your system has `administrator` role \u2192 use `/administrator/`\n - If your system has `moderator` role \u2192 use `/moderator/`\n - If your system has `seller` role \u2192 use `/seller/`\n - If your system has `buyer` role \u2192 use `/buyer/`\n - If your system has custom roles \u2192 use `/{customRole}/`\n \n **Standard patterns**:\n - `/my/` - ALWAYS means \"resources owned by the authenticated user\"\n - `/{role}/` - Role-specific access (e.g., `/admin/`, `/seller/`, `/moderator/`)\n - No prefix - Public or general authenticated access\n \n Examples:\n - `DELETE /admin/users/{userId}` - If system has 'admin' role\n - `DELETE /administrator/users/{userId}` - If system has 'administrator' role\n - `GET /my/posts` - Any authenticated user gets their own posts\n - `GET /seller/products` - Seller-specific product management\n - `PUT /moderator/posts/{postId}` - Moderator can edit posts\n - `GET /buyer/orders` - Buyer sees their purchase history\n\n### 4.3. Path patterns\n\n- Collection endpoints: `/domain/resources`\n- Single resource endpoints: `/domain/resources/{resourceId}`\n- Nested resources: `/domain/resources/{resourceId}/subsidiaries/{subsidiaryId}`\n- Role-based collection endpoints: `/role/domain/resources`\n- Role-based single resource endpoints: `/role/domain/resources/{resourceId}`\n\nCombined examples (adapt role names to your system):\n- `/{adminRole}/bbs/articles` - Admin/Administrator access to all articles\n- `/my/bbs/articles` - User's own articles\n- `/bbs/articles` - Public articles list\n- `/{adminRole}/shopping/orders/{orderId}` - Admin access to any order\n- `/my/shopping/orders/{orderId}` - User access to their own order\n- `/seller/shopping/products` - Seller's product management\n- `/buyer/shopping/wishlists` - Buyer's wishlist management\n\n### 4.4. Standard API operations per entity\n\nFor EACH independent entity identified in the requirements document, Prisma DB Schema, and ERD diagram, you MUST include these standard endpoints:\n\n#### Public endpoints (RARE - only for truly public data):\n1. `PATCH /entity-plural` - List entities with searching (consider if this should really be public)\n2. `GET /entity-plural/{id}` - Get specific entity (often needs authentication for private data)\n\n#### Authenticated user endpoints (MOST COMMON):\n3. `POST /entity-plural` - Create entity (requires user authentication to track creator)\n4. `PUT /my/entity-plural/{id}` - Update user's own entity (MUST verify ownership)\n5. `DELETE /my/entity-plural/{id}` - Delete user's own entity (MUST verify ownership)\n\n#### Role-specific endpoints (adapt to your system's roles):\n6. `PUT /{role}/entity-plural/{id}` - Role-specific update (e.g., /admin/, /moderator/, /seller/)\n7. `DELETE /{role}/entity-plural/{id}` - Role-specific delete\n8. `PATCH /{role}/entity-plural` - Role-specific list with special permissions\n\n**\uD83D\uDD34 AUTHORIZATION IS ALMOST ALWAYS REQUIRED**:\n- Even \"reading my own data\" requires authentication to know who \"my\" refers to\n- Creating any resource requires authentication to set the creator/owner\n- Updating/deleting requires authentication to verify ownership or permissions\n- Public endpoints should be the exception, not the rule\n\n**Role-based endpoint strategy**:\n- Use `/my/` prefix when users can only access their own resources\n- Use `/{role}/` prefix based on actual roles in your system (admin, administrator, moderator, seller, buyer, etc.)\n- Use no prefix for public or general authenticated operations\n- The same resource can have multiple endpoints with different prefixes for different access levels\n- **IMPORTANT**: The actual role names come from your requirements and Prisma schema - use whatever roles are defined there\n\n**CRITICAL**: The DELETE operation behavior depends on the Prisma schema:\n- If the entity has soft delete fields (e.g., `deleted_at`, `is_deleted`), the DELETE endpoint will perform soft delete\n- If NO soft delete fields exist in the schema, the DELETE endpoint MUST perform hard delete\n- NEVER assume soft delete fields exist without verifying in the actual Prisma schema\n\n**CRITICAL**: The DELETE operation behavior depends on the Prisma schema:\n- If the entity has soft delete fields (e.g., `deleted_at`, `is_deleted`), the DELETE endpoint will perform soft delete\n- If NO soft delete fields exist in the schema, the DELETE endpoint MUST perform hard delete\n- NEVER assume soft delete fields exist without verifying in the actual Prisma schema\n\n## 5. Critical Requirements\n\n- **Function Call Required**: You MUST use the `makeEndpoints()` function to submit your results\n- **Complete Coverage**: EVERY independent entity in the Prisma schema MUST have corresponding endpoints\n- **No Omissions**: Process ALL independent entities regardless of quantity\n- **Strict Output Format**: ONLY include objects with `path` and `method` properties in your function call\n- **No Additional Properties**: Do NOT include any properties beyond `path` and `method`\n- **Role-Based Endpoints**: When an entity requires authentication, create appropriate role-prefixed endpoints\n- **Clear Access Intent**: The path itself should indicate who can access the endpoint (admin, user, public)\n\n### \uD83D\uDD34 CRITICAL: Authorization Role Assignment\n\n**IMPORTANT**: Endpoints without authorization roles are RARE. Most endpoints require authentication to:\n- Verify resource ownership (e.g., users can only delete their own posts)\n- Enforce role-based permissions (e.g., only admins can manage users)\n- Track who performed actions (audit logging)\n- Protect sensitive data\n\n**Even \"simple\" operations require authorization**:\n- DELETE `/my/posts/{id}` - Requires \"user\" role to verify the post author matches the authenticated user\n- PUT `/my/profile` - Requires \"user\" role to ensure users only update their own profile\n- GET `/my/orders` - Requires \"user\" role to filter orders by the authenticated user\n\n**Only truly public endpoints should have no role**:\n- GET `/products` - Public product catalog\n- GET `/categories` - Public category list\n- GET `/posts` - Public post list (but `/my/posts` would require authentication)\n\nRemember: \n- The path structure (`/my/`, `/admin/`, etc.) implies the authorization requirement\n- In Phase 2 (Operations), each endpoint will be assigned an explicit `authorizationRole`\n- The authorization role will be used by the Realize Agent to:\n 1. Generate appropriate authentication decorators\n 2. Create authorization checks (ownership verification, role validation)\n 3. Ensure proper access control implementation\n\n**Path Convention as Authorization Hint**:\n- `/my/*` paths \u2192 Will need user authentication in Phase 2\n- `/{role}/*` paths \u2192 Will need specific role authentication in Phase 2\n- Plain paths without prefix \u2192 Might be public, but consider carefully\n\n## 6. Implementation Strategy\n\n1. Identify ALL independent entities from the Prisma schema, requirements document, and ERD\n2. Identify service-related prefixes in the DB schema to use as the global prefix for ALL API endpoints\n3. Identify domain prefixes and hierarchical relationships between entities\n4. For each independent entity:\n - Convert kebab-case names to camelCase (e.g., `attachment-files` \u2192 `attachmentFiles`)\n - Structure paths to reflect domain and hierarchical relationships\n - Generate the standard endpoints\n5. Add endpoints for relationships and complex operations\n6. Verify ALL independent entities and requirements are covered\n7. Call the `makeEndpoints()` function with your complete array\n\nYour implementation MUST be COMPLETE and EXHAUSTIVE, ensuring NO independent entity or requirement is missed, while strictly adhering to the `AutoBeOpenApi.IEndpoint` interface format. Calling the `makeEndpoints()` function is MANDATORY.\n\n## 7. Path Transformation Examples\n\n| Original Format | Improved Format | Explanation |\n|-----------------|-----------------|-------------|\n| `/attachment-files` | `/attachmentFiles` | Convert kebab-case to camelCase |\n| `/bbs-articles` | `/bbs/articles` | Separate domain prefix with slash |\n| `/bbs-article-snapshots` | `/bbs/articles/snapshots` | Reflect hierarchy in URL structure |\n| `/shopping-sale-snapshots` | `/shopping/sales/snapshots` | Both domain prefix and hierarchy properly formatted |\n| `/users` (DELETE) | `/{adminRole}/users/{id}` | Only admin/administrator can delete users |\n| `/posts` (DELETE by owner) | `/my/posts/{id}` | Users can only delete their own posts |\n| `/posts` (UPDATE by moderator) | `/moderator/posts/{id}` | Moderator can update any post |\n| `/products` (MANAGE by seller) | `/seller/products` | Seller manages their products |\n| `/orders` (GET by buyer) | `/buyer/orders` | Buyer sees their purchase orders |\n| `/orders` (GET by seller) | `/seller/orders` | Seller sees orders for their products |\n| Note: | Use actual role names from your system | admin, administrator, moderator, seller, buyer, etc. |\n\nYour implementation MUST be COMPLETE and EXHAUSTIVE, ensuring NO independent entity or requirement is missed, while strictly adhering to the `AutoBeOpenApi.IEndpoint` interface format. Calling the `makeEndpoints()` function is MANDATORY.\n\nYou're right - I removed too much of the original structure. Here's a better version that maintains the section structure while adding explanations:\n\n## 8. Example Cases\n\nBelow are example projects that demonstrate the proper endpoint formatting.\n\n### 8.1. BBS (Bulletin Board System)\n\n```json\n{\"endpoints\":[{\"path\":\"/bbs/articles\",\"method\":\"post\"},{\"path\":\"/bbs/articles\",\"method\":\"patch\"},{\"path\":\"/bbs/articles/abridges\",\"method\":\"patch\"},{\"path\":\"/bbs/articles/{id}\",\"method\":\"get\"},{\"path\":\"/bbs/articles/{id}\",\"method\":\"put\"},{\"path\":\"/bbs/articles/{id}\",\"method\":\"delete\"},{\"path\":\"/bbs/articles/{articleId}/comments\",\"method\":\"post\"},{\"path\":\"/bbs/articles/{articleId}/comments\",\"method\":\"patch\"},{\"path\":\"/bbs/articles/{articleId}/comments/{id}\",\"method\":\"get\"},{\"path\":\"/bbs/articles/{articleId}/comments/{id}\",\"method\":\"put\"},{\"path\":\"/bbs/articles/{articleId}/comments/{id}\",\"method\":\"delete\"},{\"path\":\"/monitors/health\",\"method\":\"get\"},{\"path\":\"/monitors/performance\",\"method\":\"get\"},{\"path\":\"/monitors/system\",\"method\":\"get\"}]}\n```\n\n**Key points**: \n- Domain prefix \"bbs\" is separated with a slash\n- Entities use camelCase\n- Hierarchical relationships are expressed (e.g., `/bbs/articles/{articleId}/comments`)\n- Role-based access: `/my/bbs/articles` for user's own articles, `/{actualAdminRole}/bbs/articles` for admin operations (use the actual role name from your system)\n\n### 8.2. Shopping Mall\n\n```json\n{\"endpoints\":[{\"path\":\"/monitors/health\",\"method\":\"get\"},{\"path\":\"/monitors/performance\",\"method\":\"get\"},{\"path\":\"/monitors/system\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/authenticate\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/authenticate\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/authenticate/login\",\"method\":\"put\"},{\"path\":\"/shoppings/admins/coupons\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/coupons\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/coupons/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/coupons/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/admins/deposits\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/deposits\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/deposits/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/deposits/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/admins/deposits/{code}/get\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/mileages\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/mileages\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/mileages/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/mileages/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/admins/mileages/{code}/get\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/mileages/donations\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/mileages/donations\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/mileages/donations/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/orders\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/orders/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/sales/details\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/sales/{saleId}/questions/{inquiryId}/comments\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/sales/{saleId}/questions/{inquiryId}/comments\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{saleId}/questions/{inquiryId}/comments/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/sales/{saleId}/questions/{inquiryId}/comments/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/admins/sales/{saleId}/questions\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{saleId}/questions/abridges\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{saleId}/questions/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/sales/{saleId}/reviews/{inquiryId}/comments\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/sales/{saleId}/reviews/{inquiryId}/comments\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{saleId}/reviews/{inquiryId}/comments/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/sales/{saleId}/reviews/{inquiryId}/comments/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/admins/sales/{saleId}/reviews\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{saleId}/reviews/abridges\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{saleId}/reviews/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/sales/{saleId}/snapshots\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/sales/{saleId}/snapshots/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/sales/{saleId}/snapshots/{id}/flip\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/systematic/channels/{channelCode}/categories\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/systematic/channels/{channelCode}/categories\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/systematic/channels/{channelCode}/categories/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/systematic/channels/{channelCode}/categories/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/admins/systematic/channels/{channelCode}/categories/merge\",\"method\":\"delete\"},{\"path\":\"/shoppings/admins/systematic/channels/{channelCode}/categories/{id}/invert\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/systematic/channels\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/systematic/channels\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/systematic/channels/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/systematic/channels/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/admins/systematic/channels/merge\",\"method\":\"delete\"},{\"path\":\"/shoppings/admins/systematic/channels/hierarchical\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/systematic/channels/{code}/get\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/systematic/sections\",\"method\":\"post\"},{\"path\":\"/shoppings/admins/systematic/sections\",\"method\":\"patch\"},{\"path\":\"/shoppings/admins/systematic/sections/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/admins/systematic/sections/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/admins/systematic/sections/merge\",\"method\":\"delete\"},{\"path\":\"/shoppings/admins/systematic/sections/{code}/get\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/authenticate/refresh\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/authenticate\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/authenticate\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/authenticate/join\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/authenticate/login\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/authenticate/activate\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/authenticate/external\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/authenticate/password/change\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/coupons\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/coupons/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/coupons/tickets\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/coupons/tickets\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/coupons/tickets/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/deposits/charges\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/deposits/charges\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/deposits/charges/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/deposits/charges/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/deposits/charges/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/customers/deposits/charges/{chargeId}/publish/able\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/deposits/charges/{chargeId}/publish\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/deposits/histories\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/deposits/histories/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/deposits/histories/balance\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/mileages/histories\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/mileages/histories/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/mileages/histories/balance\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/carts/commodities\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/carts/commodities\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/carts/commodities/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/carts/commodities/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/carts/commodities/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/customers/carts/commodities/{id}/replica\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/carts/commodities/discountable\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/orders\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/orders\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/orders/direct\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/orders/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/orders/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/customers/orders/{id}/price\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/orders/{id}/discountable\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/orders/{id}/discount\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/orders/{orderId}/goods/{id}/confirm\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/orders/{orderId}/publish/able\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/orders/{orderId}/publish\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/orders/{orderId}/publish\",\"method\":\"delete\"},{\"path\":\"/shoppings/customers/sales/details\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions/{inquiryId}/comments\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions/{inquiryId}/comments\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions/{inquiryId}/comments/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions/{inquiryId}/comments/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions/{id}\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/sales/{saleId}/questions/abridges\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews/{inquiryId}/comments\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews/{inquiryId}/comments\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews/{inquiryId}/comments/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews/{inquiryId}/comments/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews/{id}\",\"method\":\"post\"},{\"path\":\"/shoppings/customers/sales/{saleId}/reviews/abridges\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{saleId}/snapshots\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/sales/{saleId}/snapshots/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/sales/{saleId}/snapshots/{id}/flip\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/systematic/channels/{channelCode}/categories\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/systematic/channels/{channelCode}/categories/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/systematic/channels/{channelCode}/categories/{id}/invert\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/systematic/channels\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/systematic/channels/hierarchical\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/systematic/channels/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/systematic/channels/{code}/get\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/systematic/sections\",\"method\":\"patch\"},{\"path\":\"/shoppings/customers/systematic/sections/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/customers/systematic/sections/{code}/get\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/authenticate\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/authenticate\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/authenticate/login\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/deliveries\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/deliveries\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/deliveries/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/deliveries/incompletes\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/deliveries/{deliveryId}/journeys\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/deliveries/{deliveryId}/journeys/{id}/complete\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/deliveries/{deliveryId}/journeys/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/sellers/deliveries/{deliveryId}/shippers\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/coupons\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/coupons\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/coupons/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/coupons/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/sellers/orders\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/orders/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/{id}/open\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/{id}/replica\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales/{id}/pause\",\"method\":\"delete\"},{\"path\":\"/shoppings/sellers/sales/{id}/suspend\",\"method\":\"delete\"},{\"path\":\"/shoppings/sellers/sales/{id}/restore\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/details\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/{questionId}/answer\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/{questionId}/answer\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/{inquiryId}/comments\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/{inquiryId}/comments\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/{inquiryId}/comments/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/{inquiryId}/comments/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/abridges\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/questions/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/{reviewId}/answer\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/{reviewId}/answer\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/{inquiryId}/comments\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/{inquiryId}/comments\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/{inquiryId}/comments/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/{inquiryId}/comments/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/abridges\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/reviews/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/snapshots/{id}/replica\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/snapshots\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/snapshots/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/snapshots/{id}/flip\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/units/{unitId}/stocks/{stockId}/supplements\",\"method\":\"post\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/units/{unitId}/stocks/{stockId}/supplements\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/units/{unitId}/stocks/{stockId}/supplements/{id}\",\"method\":\"put\"},{\"path\":\"/shoppings/sellers/sales/{saleId}/units/{unitId}/stocks/{stockId}/supplements/{id}\",\"method\":\"delete\"},{\"path\":\"/shoppings/sellers/systematic/channels/{channelCode}/categories\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/systematic/channels/{channelCode}/categories/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/systematic/channels/{channelCode}/categories/{id}/invert\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/systematic/channels\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/systematic/channels/hierarchical\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/systematic/channels/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/systematic/channels/{code}/get\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/systematic/sections\",\"method\":\"patch\"},{\"path\":\"/shoppings/sellers/systematic/sections/{id}\",\"method\":\"get\"},{\"path\":\"/shoppings/sellers/systematic/sections/{code}/get\",\"method\":\"get\"}]}\n```\n\n**Key points**: \n- `/shopping` is used as domain prefix\n- Hierarchical relationships are reflected in paths (e.g., `/shopping/sales/{saleId}/reviews/{reviewId}`)\n- Consistent HTTP methods are applied across similar operations\n- Role differentiation: `/my/shopping/orders` for user's own orders, `/buyer/shopping/orders` for buyer-specific views, `/seller/shopping/orders` for seller's order management\n- Role-specific operations: Use actual roles from your system (e.g., `/administrator/shopping/products`, `/seller/shopping/products`)" /* AutoBeSystemPromptConstant.INTERFACE_ENDPOINT */),
108
+ histories: (0, transformInterfaceOperationHistories_1.transformInterfaceOperationHistories)(ctx.state(), endpoints),
116
109
  controllers: [
117
110
  createApplication({
118
111
  model: ctx.model,
119
- roles: (_c = (_b = ctx.state().analyze) === null || _b === void 0 ? void 0 : _b.roles.map((it) => it.name)) !== null && _c !== void 0 ? _c : null,
120
- build: (endpoints) => {
112
+ roles: (_c = (_b = ctx.state().analyze) === null || _b === void 0 ? void 0 : _b.roles.map((it) => it.name)) !== null && _c !== void 0 ? _c : [],
113
+ build: (operations) => {
121
114
  var _a;
122
115
  (_a = pointer.value) !== null && _a !== void 0 ? _a : (pointer.value = []);
123
- pointer.value.push(...endpoints);
116
+ const matrix = operations.map((op) => {
117
+ if (op.authorizationRoles.length === 0)
118
+ return [
119
+ Object.assign(Object.assign({}, op), { path: "/" +
120
+ [prefix, ...op.path.split("/")]
121
+ .filter((it) => it !== "")
122
+ .join("/"), authorizationRole: null }),
123
+ ];
124
+ return op.authorizationRoles.map((role) => (Object.assign(Object.assign({}, op), { path: "/" +
125
+ [prefix, role, ...op.path.split("/")]
126
+ .filter((it) => it !== "")
127
+ .join("/"), authorizationRole: role })));
128
+ });
129
+ progress.completed += matrix.flat().length;
130
+ progress.total += matrix
131
+ .filter((it) => it.length > 1)
132
+ .map((it) => it.length - 1)
133
+ .reduce((a, b) => a + b, 0);
134
+ pointer.value.push(...matrix.flat());
124
135
  },
125
136
  }),
126
137
  ],
127
138
  });
128
139
  (0, enforceToolCall_1.enforceToolCall)(agentica);
129
- yield agentica
130
- .conversate([
131
- "Make API operations for below endpoints:",
132
- "",
133
- "**CRITICAL INSTRUCTIONS**:",
134
- "1. Base ALL operation descriptions on ACTUAL fields in the Prisma schema",
135
- "2. NEVER reference fields that don't exist (e.g., deleted_at, created_by, updated_by)",
136
- "3. For DELETE operations:",
137
- " - Check if the entity has soft delete fields in the schema",
138
- " - If YES: Describe soft delete behavior using those fields",
139
- " - If NO: Describe hard delete behavior (permanent removal)",
140
- "4. Every field mentioned in descriptions MUST exist in the Prisma schema",
141
- "",
142
- "```json",
143
- JSON.stringify(Array.from(endpoints), null, 2),
144
- "```",
145
- ].join("\n"))
146
- .finally(() => {
140
+ yield agentica.conversate("Make API operations").finally(() => {
147
141
  const tokenUsage = agentica.getTokenUsage();
148
142
  ctx.usage().record(tokenUsage, ["interface"]);
149
143
  });
@@ -156,7 +150,7 @@ function createApplication(props) {
156
150
  (0, assertSchemaModel_1.assertSchemaModel)(props.model);
157
151
  const application = collection[props.model];
158
152
  application.functions[0].validate = (next) => {
159
- const result = (() => { const _io0 = input => Array.isArray(input.operations) && input.operations.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => "string" === typeof input.specification && "string" === typeof input.description && "string" === typeof input.summary && (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 && 1 <= input.authorizationRole.length) && "string" === typeof input.name && "string" === typeof input.path && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof 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 => (() => {
153
+ const result = (() => { const _io0 = input => Array.isArray(input.operations) && input.operations.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => Array.isArray(input.authorizationRoles) && input.authorizationRoles.every(elem => "string" === typeof elem && 1 <= elem.length) && "string" === typeof input.description && "string" === typeof 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)) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof 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 => (() => {
160
154
  if ("number" === input.type)
161
155
  return _io4(input);
162
156
  else if ("integer" === input.type)
@@ -167,42 +161,70 @@ function createApplication(props) {
167
161
  return false;
168
162
  })(); const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.operations) || _report(_exceptionable, {
169
163
  path: _path + ".operations",
170
- expected: "Array<AutoBeOpenApi.IOperation>",
164
+ expected: "Array<IAutoBeInterfaceOperationApplication.IOperation>",
171
165
  value: input.operations
172
- })) && input.operations.map((elem, _index3) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
173
- path: _path + ".operations[" + _index3 + "]",
174
- expected: "AutoBeOpenApi.IOperation",
166
+ })) && input.operations.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
167
+ path: _path + ".operations[" + _index4 + "]",
168
+ expected: "IAutoBeInterfaceOperationApplication.IOperation",
175
169
  value: elem
176
- })) && _vo1(elem, _path + ".operations[" + _index3 + "]", true && _exceptionable) || _report(_exceptionable, {
177
- path: _path + ".operations[" + _index3 + "]",
178
- expected: "AutoBeOpenApi.IOperation",
170
+ })) && _vo1(elem, _path + ".operations[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
171
+ path: _path + ".operations[" + _index4 + "]",
172
+ expected: "IAutoBeInterfaceOperationApplication.IOperation",
179
173
  value: elem
180
174
  })).every(flag => flag) || _report(_exceptionable, {
181
175
  path: _path + ".operations",
182
- expected: "Array<AutoBeOpenApi.IOperation>",
176
+ expected: "Array<IAutoBeInterfaceOperationApplication.IOperation>",
183
177
  value: input.operations
184
- })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.specification || _report(_exceptionable, {
185
- path: _path + ".specification",
186
- expected: "string",
187
- value: input.specification
178
+ })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => [(Array.isArray(input.authorizationRoles) || _report(_exceptionable, {
179
+ path: _path + ".authorizationRoles",
180
+ expected: "Array<string & MinLength<1>>",
181
+ value: input.authorizationRoles
182
+ })) && input.authorizationRoles.map((elem, _index5) => "string" === typeof elem && (1 <= elem.length || _report(_exceptionable, {
183
+ path: _path + ".authorizationRoles[" + _index5 + "]",
184
+ expected: "string & MinLength<1>",
185
+ value: elem
186
+ })) || _report(_exceptionable, {
187
+ path: _path + ".authorizationRoles[" + _index5 + "]",
188
+ expected: "(string & MinLength<1>)",
189
+ value: elem
190
+ })).every(flag => flag) || _report(_exceptionable, {
191
+ path: _path + ".authorizationRoles",
192
+ expected: "Array<string & MinLength<1>>",
193
+ value: input.authorizationRoles
188
194
  }), "string" === typeof input.description || _report(_exceptionable, {
189
195
  path: _path + ".description",
190
196
  expected: "string",
191
197
  value: input.description
198
+ }), "string" === typeof input.name || _report(_exceptionable, {
199
+ path: _path + ".name",
200
+ expected: "string",
201
+ value: input.name
202
+ }), "string" === typeof input.specification || _report(_exceptionable, {
203
+ path: _path + ".specification",
204
+ expected: "string",
205
+ value: input.specification
192
206
  }), "string" === typeof input.summary || _report(_exceptionable, {
193
207
  path: _path + ".summary",
194
208
  expected: "string",
195
209
  value: input.summary
210
+ }), "string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
211
+ path: _path + ".path",
212
+ expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
213
+ value: input.path
214
+ })) || _report(_exceptionable, {
215
+ path: _path + ".path",
216
+ expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
217
+ value: input.path
196
218
  }), (Array.isArray(input.parameters) || _report(_exceptionable, {
197
219
  path: _path + ".parameters",
198
220
  expected: "Array<AutoBeOpenApi.IParameter>",
199
221
  value: input.parameters
200
- })) && input.parameters.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
201
- path: _path + ".parameters[" + _index4 + "]",
222
+ })) && input.parameters.map((elem, _index6) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
223
+ path: _path + ".parameters[" + _index6 + "]",
202
224
  expected: "AutoBeOpenApi.IParameter",
203
225
  value: elem
204
- })) && _vo2(elem, _path + ".parameters[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
205
- path: _path + ".parameters[" + _index4 + "]",
226
+ })) && _vo2(elem, _path + ".parameters[" + _index6 + "]", true && _exceptionable) || _report(_exceptionable, {
227
+ path: _path + ".parameters[" + _index6 + "]",
206
228
  expected: "AutoBeOpenApi.IParameter",
207
229
  value: elem
208
230
  })).every(flag => flag) || _report(_exceptionable, {
@@ -225,22 +247,6 @@ function createApplication(props) {
225
247
  path: _path + ".responseBody",
226
248
  expected: "(AutoBeOpenApi.IResponseBody | null)",
227
249
  value: input.responseBody
228
- }), null === input.authorizationRole || "string" === typeof input.authorizationRole && (1 <= input.authorizationRole.length || _report(_exceptionable, {
229
- path: _path + ".authorizationRole",
230
- expected: "string & MinLength<1>",
231
- value: input.authorizationRole
232
- })) || _report(_exceptionable, {
233
- path: _path + ".authorizationRole",
234
- expected: "((string & MinLength<1>) | null)",
235
- value: input.authorizationRole
236
- }), "string" === typeof input.name || _report(_exceptionable, {
237
- path: _path + ".name",
238
- expected: "string",
239
- value: input.name
240
- }), "string" === typeof input.path || _report(_exceptionable, {
241
- path: _path + ".path",
242
- expected: "string",
243
- value: input.path
244
250
  }), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
245
251
  path: _path + ".method",
246
252
  expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
@@ -396,11 +402,11 @@ function createApplication(props) {
396
402
  _report = __typia_transform__validateReport._validateReport(errors);
397
403
  ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
398
404
  path: _path + "",
399
- expected: "IMakeOperationProps",
405
+ expected: "IAutoBeInterfaceOperationApplication.IProps",
400
406
  value: input
401
407
  })) && _vo0(input, _path + "", true) || _report(true, {
402
408
  path: _path + "",
403
- expected: "IMakeOperationProps",
409
+ expected: "IAutoBeInterfaceOperationApplication.IProps",
404
410
  value: input
405
411
  }))(input, "$input", true);
406
412
  const success = 0 === errors.length;
@@ -423,29 +429,30 @@ function createApplication(props) {
423
429
  const operations = result.data.operations;
424
430
  const errors = [];
425
431
  operations.forEach((op, i) => {
426
- var _a, _b;
427
432
  if (op.method === "get" && op.requestBody !== null)
428
433
  errors.push({
429
434
  path: `$input.operations[${i}].requestBody`,
430
435
  expected: "GET method should not have request body. Change method, or re-design the operation.",
431
436
  value: op.requestBody,
432
437
  });
433
- if (props.roles === null)
434
- op.authorizationRole = null;
435
- else if (op.authorizationRole !== null &&
436
- !!((_a = props.roles) === null || _a === void 0 ? void 0 : _a.length) &&
437
- props.roles.find((it) => it === op.authorizationRole) === undefined)
438
- errors.push({
439
- path: `$input.operations[${i}].authorizationRole`,
440
- expected: `null | ${props.roles.map((str) => JSON.stringify(str)).join(" | ")}`,
441
- description: [
442
- `Role "${op.authorizationRole}" is not defined in the roles list.`,
443
- "",
444
- "Please select one of them below, or do not define (`null`): ",
445
- "",
446
- ...((_b = props.roles) !== null && _b !== void 0 ? _b : []).map((role) => `- ${role}`),
447
- ].join("\n"),
448
- value: op.authorizationRole,
438
+ if (props.roles.length === 0)
439
+ op.authorizationRoles = [];
440
+ else if (op.authorizationRoles.length !== 0 && props.roles.length !== 0)
441
+ op.authorizationRoles.forEach((role, j) => {
442
+ if (props.roles.includes(role) === true)
443
+ return;
444
+ errors.push({
445
+ path: `$input.operations[${i}].authorizationRoles[${j}]`,
446
+ expected: `null | ${props.roles.map((str) => JSON.stringify(str)).join(" | ")}`,
447
+ description: [
448
+ `Role "${role}" is not defined in the roles list.`,
449
+ "",
450
+ "Please select one of them below, or do not define (`null`): ",
451
+ "",
452
+ ...props.roles.map((role) => `- ${role}`),
453
+ ].join("\n"),
454
+ value: role,
455
+ });
449
456
  });
450
457
  });
451
458
  if (errors.length !== 0)
@@ -477,14 +484,14 @@ const claude = {
477
484
  {
478
485
  name: "makeOperations",
479
486
  parameters: {
480
- description: " Properties containing the operations to generate.\n\n------------------------------\n\nCurrent Type: {@link IMakeOperationProps}",
487
+ description: " Properties containing the operations to generate.\n\n------------------------------\n\nCurrent Type: {@link IAutoBeInterfaceOperationApplication.IProps}",
481
488
  type: "object",
482
489
  properties: {
483
490
  operations: {
484
- description: "Array of API operations to generate.\n\nEach operation in this array must include:\n\n- Specification: Detailed API specification with clear purpose and\n functionality\n- Path: Resource-centric URL path (e.g., \"/resources/{resourceId}\")\n- Method: HTTP method (get, post, put, delete, patch)\n- Description: Extremely detailed multi-paragraph description referencing\n Prisma schema comments\n- Summary: Concise one-sentence summary of the endpoint\n- Parameters: Array of all necessary parameters with descriptions and schema\n definitions\n- RequestBody: For POST/PUT/PATCH methods, with typeName referencing\n components.schemas\n- ResponseBody: With typeName referencing appropriate response type\n\nAll operations must follow strict quality standards:\n\n1. Detailed descriptions referencing Prisma schema comments\n2. Accurate parameter definitions matching path parameters\n3. Appropriate request/response body type references\n4. Consistent patterns for CRUD operations\n\nFor list retrievals (typically PATCH), include pagination, search, and\nsorting. For detail retrieval (GET), return a single resource. For creation\n(POST), use .ICreate request body. For modification (PUT), use .IUpdate\nrequest body.",
491
+ description: "Array of API operations to generate.\n\nEach operation in this array must include:\n\n- Specification: Detailed API specification with clear purpose and\n functionality\n- Path: Resource-centric URL path (e.g., \"/resources/{resourceId}\")\n- Method: HTTP method (get, post, put, delete, patch)\n- Description: Extremely detailed multi-paragraph description referencing\n Prisma schema comments\n- Summary: Concise one-sentence summary of the endpoint\n- Parameters: Array of all necessary parameters with descriptions and\n schema definitions\n- RequestBody: For POST/PUT/PATCH methods, with typeName referencing\n components.schemas\n- ResponseBody: With typeName referencing appropriate response type\n\nAll operations must follow strict quality standards:\n\n1. Detailed descriptions referencing Prisma schema comments\n2. Accurate parameter definitions matching path parameters\n3. Appropriate request/response body type references\n4. Consistent patterns for CRUD operations\n\nFor list retrievals (typically PATCH), include pagination, search, and\nsorting. For detail retrieval (GET), return a single resource. For\ncreation (POST), use .ICreate request body. For modification (PUT), use\n.IUpdate request body.",
485
492
  type: "array",
486
493
  items: {
487
- $ref: "#/$defs/AutoBeOpenApi.IOperation"
494
+ $ref: "#/$defs/IAutoBeInterfaceOperationApplication.IOperation"
488
495
  }
489
496
  }
490
497
  },
@@ -493,22 +500,39 @@ const claude = {
493
500
  ],
494
501
  additionalProperties: false,
495
502
  $defs: {
496
- "AutoBeOpenApi.IOperation": {
503
+ "IAutoBeInterfaceOperationApplication.IOperation": {
497
504
  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```",
498
505
  type: "object",
499
506
  properties: {
500
- specification: {
501
- 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.",
502
- type: "string"
507
+ authorizationRoles: {
508
+ description: "Authorization roles required to access this API operation.\n\nThis field specifies which user roles are allowed to access this\nendpoint. Multiple roles can be specified to allow different types of\nusers to access the same endpoint.\n\n## Important Guidelines\n\n- Set to empty array `[]` for public endpoints that require no\n authentication\n- Set to array with role strings for role-restricted endpoints\n- The role names MUST match exactly with the user type/role defined in the\n database\n- This will be used by the Realize Agent to generate appropriate decorator\n and authorization logic in the provider functions\n- The controller will apply the corresponding authentication decorator\n based on these roles\n\n## Examples\n\n- `[]` - Public endpoint, no authentication required\n- `[\"user\"]` - Any authenticated user can access\n- `[\"admin\"]` - Only admin users can access\n- `[\"admin\", \"moderator\"]` - Both admin and moderator users can access\n- `[\"seller\"]` - Only seller 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.",
509
+ type: "array",
510
+ items: {
511
+ type: "string",
512
+ minLength: 1
513
+ }
503
514
  },
504
515
  description: {
505
516
  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> MUST be written in English. Never use other languages.",
506
517
  type: "string"
507
518
  },
519
+ name: {
520
+ 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## 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\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- Use lowercase, 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\nExamples:\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\"`",
521
+ type: "string"
522
+ },
523
+ specification: {
524
+ 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.",
525
+ type: "string"
526
+ },
508
527
  summary: {
509
528
  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> MUST be written in English. Never use other languages",
510
529
  type: "string"
511
530
  },
531
+ path: {
532
+ 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)",
533
+ type: "string",
534
+ pattern: "^\\/[a-zA-Z0-9\\/_{}.-]*$"
535
+ },
512
536
  parameters: {
513
537
  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`",
514
538
  type: "array",
@@ -538,26 +562,6 @@ const claude = {
538
562
  }
539
563
  ]
540
564
  },
541
- authorizationRole: {
542
- 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 (e.g., \"admin\", \"administrator\", \"moderator\",\n\"seller\", \"buyer\", etc.).\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.",
543
- oneOf: [
544
- {
545
- type: "null"
546
- },
547
- {
548
- type: "string",
549
- minLength: 1
550
- }
551
- ]
552
- },
553
- name: {
554
- 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## 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\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- Use lowercase, 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\nExamples:\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\"`",
555
- type: "string"
556
- },
557
- path: {
558
- 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.",
559
- type: "string"
560
- },
561
565
  method: {
562
566
  description: "HTTP method of the API operation.\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",
563
567
  oneOf: [
@@ -580,15 +584,15 @@ const claude = {
580
584
  }
581
585
  },
582
586
  required: [
583
- "specification",
587
+ "authorizationRoles",
584
588
  "description",
589
+ "name",
590
+ "specification",
585
591
  "summary",
592
+ "path",
586
593
  "parameters",
587
594
  "requestBody",
588
595
  "responseBody",
589
- "authorizationRole",
590
- "name",
591
- "path",
592
596
  "method"
593
597
  ]
594
598
  },
@@ -775,7 +779,7 @@ const claude = {
775
779
  }
776
780
  },
777
781
  description: "Generate detailed API operations from path/method combinations.\n\nThis function creates complete API operations following REST principles and\nquality standards. Each generated operation includes specification, path,\nmethod, detailed multi-paragraph description, concise summary, parameters,\nand appropriate request/response bodies.\n\nThe function processes as many operations as possible in a single call,\nwith progress tracking to ensure iterative completion of all required\nendpoints.",
778
- validate: (() => { const _io0 = input => Array.isArray(input.operations) && input.operations.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => "string" === typeof input.specification && "string" === typeof input.description && "string" === typeof input.summary && (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 && 1 <= input.authorizationRole.length) && "string" === typeof input.name && "string" === typeof input.path && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof 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 => (() => {
782
+ validate: (() => { const _io0 = input => Array.isArray(input.operations) && input.operations.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => Array.isArray(input.authorizationRoles) && input.authorizationRoles.every(elem => "string" === typeof elem && 1 <= elem.length) && "string" === typeof input.description && "string" === typeof 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)) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof 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 => (() => {
779
783
  if ("number" === input.type)
780
784
  return _io4(input);
781
785
  else if ("integer" === input.type)
@@ -786,42 +790,70 @@ const claude = {
786
790
  return false;
787
791
  })(); const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.operations) || _report(_exceptionable, {
788
792
  path: _path + ".operations",
789
- expected: "Array<AutoBeOpenApi.IOperation>",
793
+ expected: "Array<IAutoBeInterfaceOperationApplication.IOperation>",
790
794
  value: input.operations
791
- })) && input.operations.map((elem, _index3) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
792
- path: _path + ".operations[" + _index3 + "]",
793
- expected: "AutoBeOpenApi.IOperation",
795
+ })) && input.operations.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
796
+ path: _path + ".operations[" + _index4 + "]",
797
+ expected: "IAutoBeInterfaceOperationApplication.IOperation",
794
798
  value: elem
795
- })) && _vo1(elem, _path + ".operations[" + _index3 + "]", true && _exceptionable) || _report(_exceptionable, {
796
- path: _path + ".operations[" + _index3 + "]",
797
- expected: "AutoBeOpenApi.IOperation",
799
+ })) && _vo1(elem, _path + ".operations[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
800
+ path: _path + ".operations[" + _index4 + "]",
801
+ expected: "IAutoBeInterfaceOperationApplication.IOperation",
798
802
  value: elem
799
803
  })).every(flag => flag) || _report(_exceptionable, {
800
804
  path: _path + ".operations",
801
- expected: "Array<AutoBeOpenApi.IOperation>",
805
+ expected: "Array<IAutoBeInterfaceOperationApplication.IOperation>",
802
806
  value: input.operations
803
- })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.specification || _report(_exceptionable, {
804
- path: _path + ".specification",
805
- expected: "string",
806
- value: input.specification
807
+ })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => [(Array.isArray(input.authorizationRoles) || _report(_exceptionable, {
808
+ path: _path + ".authorizationRoles",
809
+ expected: "Array<string & MinLength<1>>",
810
+ value: input.authorizationRoles
811
+ })) && input.authorizationRoles.map((elem, _index5) => "string" === typeof elem && (1 <= elem.length || _report(_exceptionable, {
812
+ path: _path + ".authorizationRoles[" + _index5 + "]",
813
+ expected: "string & MinLength<1>",
814
+ value: elem
815
+ })) || _report(_exceptionable, {
816
+ path: _path + ".authorizationRoles[" + _index5 + "]",
817
+ expected: "(string & MinLength<1>)",
818
+ value: elem
819
+ })).every(flag => flag) || _report(_exceptionable, {
820
+ path: _path + ".authorizationRoles",
821
+ expected: "Array<string & MinLength<1>>",
822
+ value: input.authorizationRoles
807
823
  }), "string" === typeof input.description || _report(_exceptionable, {
808
824
  path: _path + ".description",
809
825
  expected: "string",
810
826
  value: input.description
827
+ }), "string" === typeof input.name || _report(_exceptionable, {
828
+ path: _path + ".name",
829
+ expected: "string",
830
+ value: input.name
831
+ }), "string" === typeof input.specification || _report(_exceptionable, {
832
+ path: _path + ".specification",
833
+ expected: "string",
834
+ value: input.specification
811
835
  }), "string" === typeof input.summary || _report(_exceptionable, {
812
836
  path: _path + ".summary",
813
837
  expected: "string",
814
838
  value: input.summary
839
+ }), "string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
840
+ path: _path + ".path",
841
+ expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
842
+ value: input.path
843
+ })) || _report(_exceptionable, {
844
+ path: _path + ".path",
845
+ expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
846
+ value: input.path
815
847
  }), (Array.isArray(input.parameters) || _report(_exceptionable, {
816
848
  path: _path + ".parameters",
817
849
  expected: "Array<AutoBeOpenApi.IParameter>",
818
850
  value: input.parameters
819
- })) && input.parameters.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
820
- path: _path + ".parameters[" + _index4 + "]",
851
+ })) && input.parameters.map((elem, _index6) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
852
+ path: _path + ".parameters[" + _index6 + "]",
821
853
  expected: "AutoBeOpenApi.IParameter",
822
854
  value: elem
823
- })) && _vo2(elem, _path + ".parameters[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
824
- path: _path + ".parameters[" + _index4 + "]",
855
+ })) && _vo2(elem, _path + ".parameters[" + _index6 + "]", true && _exceptionable) || _report(_exceptionable, {
856
+ path: _path + ".parameters[" + _index6 + "]",
825
857
  expected: "AutoBeOpenApi.IParameter",
826
858
  value: elem
827
859
  })).every(flag => flag) || _report(_exceptionable, {
@@ -844,22 +876,6 @@ const claude = {
844
876
  path: _path + ".responseBody",
845
877
  expected: "(AutoBeOpenApi.IResponseBody | null)",
846
878
  value: input.responseBody
847
- }), null === input.authorizationRole || "string" === typeof input.authorizationRole && (1 <= input.authorizationRole.length || _report(_exceptionable, {
848
- path: _path + ".authorizationRole",
849
- expected: "string & MinLength<1>",
850
- value: input.authorizationRole
851
- })) || _report(_exceptionable, {
852
- path: _path + ".authorizationRole",
853
- expected: "((string & MinLength<1>) | null)",
854
- value: input.authorizationRole
855
- }), "string" === typeof input.name || _report(_exceptionable, {
856
- path: _path + ".name",
857
- expected: "string",
858
- value: input.name
859
- }), "string" === typeof input.path || _report(_exceptionable, {
860
- path: _path + ".path",
861
- expected: "string",
862
- value: input.path
863
879
  }), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
864
880
  path: _path + ".method",
865
881
  expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
@@ -1015,11 +1031,11 @@ const claude = {
1015
1031
  _report = __typia_transform__validateReport._validateReport(errors);
1016
1032
  ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
1017
1033
  path: _path + "",
1018
- expected: "IMakeOperationProps",
1034
+ expected: "IAutoBeInterfaceOperationApplication.IProps",
1019
1035
  value: input
1020
1036
  })) && _vo0(input, _path + "", true) || _report(true, {
1021
1037
  path: _path + "",
1022
- expected: "IMakeOperationProps",
1038
+ expected: "IAutoBeInterfaceOperationApplication.IProps",
1023
1039
  value: input
1024
1040
  }))(input, "$input", true);
1025
1041
  const success = 0 === errors.length;
@@ -1052,14 +1068,14 @@ const collection = {
1052
1068
  {
1053
1069
  name: "makeOperations",
1054
1070
  parameters: {
1055
- description: " Properties containing the operations to generate.\n\n------------------------------\n\nCurrent Type: {@link IMakeOperationProps}",
1071
+ description: " Properties containing the operations to generate.\n\n------------------------------\n\nCurrent Type: {@link IAutoBeInterfaceOperationApplication.IProps}",
1056
1072
  type: "object",
1057
1073
  properties: {
1058
1074
  operations: {
1059
- description: "Array of API operations to generate.\n\nEach operation in this array must include:\n\n- Specification: Detailed API specification with clear purpose and\n functionality\n- Path: Resource-centric URL path (e.g., \"/resources/{resourceId}\")\n- Method: HTTP method (get, post, put, delete, patch)\n- Description: Extremely detailed multi-paragraph description referencing\n Prisma schema comments\n- Summary: Concise one-sentence summary of the endpoint\n- Parameters: Array of all necessary parameters with descriptions and schema\n definitions\n- RequestBody: For POST/PUT/PATCH methods, with typeName referencing\n components.schemas\n- ResponseBody: With typeName referencing appropriate response type\n\nAll operations must follow strict quality standards:\n\n1. Detailed descriptions referencing Prisma schema comments\n2. Accurate parameter definitions matching path parameters\n3. Appropriate request/response body type references\n4. Consistent patterns for CRUD operations\n\nFor list retrievals (typically PATCH), include pagination, search, and\nsorting. For detail retrieval (GET), return a single resource. For creation\n(POST), use .ICreate request body. For modification (PUT), use .IUpdate\nrequest body.",
1075
+ description: "Array of API operations to generate.\n\nEach operation in this array must include:\n\n- Specification: Detailed API specification with clear purpose and\n functionality\n- Path: Resource-centric URL path (e.g., \"/resources/{resourceId}\")\n- Method: HTTP method (get, post, put, delete, patch)\n- Description: Extremely detailed multi-paragraph description referencing\n Prisma schema comments\n- Summary: Concise one-sentence summary of the endpoint\n- Parameters: Array of all necessary parameters with descriptions and\n schema definitions\n- RequestBody: For POST/PUT/PATCH methods, with typeName referencing\n components.schemas\n- ResponseBody: With typeName referencing appropriate response type\n\nAll operations must follow strict quality standards:\n\n1. Detailed descriptions referencing Prisma schema comments\n2. Accurate parameter definitions matching path parameters\n3. Appropriate request/response body type references\n4. Consistent patterns for CRUD operations\n\nFor list retrievals (typically PATCH), include pagination, search, and\nsorting. For detail retrieval (GET), return a single resource. For\ncreation (POST), use .ICreate request body. For modification (PUT), use\n.IUpdate request body.",
1060
1076
  type: "array",
1061
1077
  items: {
1062
- $ref: "#/$defs/AutoBeOpenApi.IOperation"
1078
+ $ref: "#/$defs/IAutoBeInterfaceOperationApplication.IOperation"
1063
1079
  }
1064
1080
  }
1065
1081
  },
@@ -1068,22 +1084,38 @@ const collection = {
1068
1084
  ],
1069
1085
  additionalProperties: false,
1070
1086
  $defs: {
1071
- "AutoBeOpenApi.IOperation": {
1087
+ "IAutoBeInterfaceOperationApplication.IOperation": {
1072
1088
  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```",
1073
1089
  type: "object",
1074
1090
  properties: {
1075
- specification: {
1076
- 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.",
1077
- type: "string"
1091
+ authorizationRoles: {
1092
+ description: "Authorization roles required to access this API operation.\n\nThis field specifies which user roles are allowed to access this\nendpoint. Multiple roles can be specified to allow different types of\nusers to access the same endpoint.\n\n## Important Guidelines\n\n- Set to empty array `[]` for public endpoints that require no\n authentication\n- Set to array with role strings for role-restricted endpoints\n- The role names MUST match exactly with the user type/role defined in the\n database\n- This will be used by the Realize Agent to generate appropriate decorator\n and authorization logic in the provider functions\n- The controller will apply the corresponding authentication decorator\n based on these roles\n\n## Examples\n\n- `[]` - Public endpoint, no authentication required\n- `[\"user\"]` - Any authenticated user can access\n- `[\"admin\"]` - Only admin users can access\n- `[\"admin\", \"moderator\"]` - Both admin and moderator users can access\n- `[\"seller\"]` - Only seller 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.",
1093
+ type: "array",
1094
+ items: {
1095
+ description: "@minLength 1",
1096
+ type: "string"
1097
+ }
1078
1098
  },
1079
1099
  description: {
1080
1100
  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> MUST be written in English. Never use other languages.",
1081
1101
  type: "string"
1082
1102
  },
1103
+ name: {
1104
+ 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## 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\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- Use lowercase, 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\nExamples:\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\"`",
1105
+ type: "string"
1106
+ },
1107
+ specification: {
1108
+ 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.",
1109
+ type: "string"
1110
+ },
1083
1111
  summary: {
1084
1112
  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> MUST be written in English. Never use other languages",
1085
1113
  type: "string"
1086
1114
  },
1115
+ path: {
1116
+ 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\\/_{}.-]*$",
1117
+ type: "string"
1118
+ },
1087
1119
  parameters: {
1088
1120
  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`",
1089
1121
  type: "array",
@@ -1113,26 +1145,6 @@ const collection = {
1113
1145
  }
1114
1146
  ]
1115
1147
  },
1116
- authorizationRole: {
1117
- 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 (e.g., \"admin\", \"administrator\", \"moderator\",\n\"seller\", \"buyer\", etc.).\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.",
1118
- anyOf: [
1119
- {
1120
- type: "null"
1121
- },
1122
- {
1123
- type: "string",
1124
- description: "@minLength 1"
1125
- }
1126
- ]
1127
- },
1128
- name: {
1129
- 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## 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\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- Use lowercase, 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\nExamples:\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\"`",
1130
- type: "string"
1131
- },
1132
- path: {
1133
- 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.",
1134
- type: "string"
1135
- },
1136
1148
  method: {
1137
1149
  description: "HTTP method of the API operation.\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",
1138
1150
  type: "string",
@@ -1146,15 +1158,15 @@ const collection = {
1146
1158
  }
1147
1159
  },
1148
1160
  required: [
1149
- "specification",
1161
+ "authorizationRoles",
1150
1162
  "description",
1163
+ "name",
1164
+ "specification",
1151
1165
  "summary",
1166
+ "path",
1152
1167
  "parameters",
1153
1168
  "requestBody",
1154
1169
  "responseBody",
1155
- "authorizationRole",
1156
- "name",
1157
- "path",
1158
1170
  "method"
1159
1171
  ]
1160
1172
  },
@@ -1346,7 +1358,7 @@ const collection = {
1346
1358
  }
1347
1359
  },
1348
1360
  description: "Generate detailed API operations from path/method combinations.\n\nThis function creates complete API operations following REST principles and\nquality standards. Each generated operation includes specification, path,\nmethod, detailed multi-paragraph description, concise summary, parameters,\nand appropriate request/response bodies.\n\nThe function processes as many operations as possible in a single call,\nwith progress tracking to ensure iterative completion of all required\nendpoints.",
1349
- validate: (() => { const _io0 = input => Array.isArray(input.operations) && input.operations.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => "string" === typeof input.specification && "string" === typeof input.description && "string" === typeof input.summary && (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 && 1 <= input.authorizationRole.length) && "string" === typeof input.name && "string" === typeof input.path && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof 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 => (() => {
1361
+ validate: (() => { const _io0 = input => Array.isArray(input.operations) && input.operations.every(elem => "object" === typeof elem && null !== elem && _io1(elem)); const _io1 = input => Array.isArray(input.authorizationRoles) && input.authorizationRoles.every(elem => "string" === typeof elem && 1 <= elem.length) && "string" === typeof input.description && "string" === typeof 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)) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof 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 => (() => {
1350
1362
  if ("number" === input.type)
1351
1363
  return _io4(input);
1352
1364
  else if ("integer" === input.type)
@@ -1357,42 +1369,70 @@ const collection = {
1357
1369
  return false;
1358
1370
  })(); const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.operations) || _report(_exceptionable, {
1359
1371
  path: _path + ".operations",
1360
- expected: "Array<AutoBeOpenApi.IOperation>",
1372
+ expected: "Array<IAutoBeInterfaceOperationApplication.IOperation>",
1361
1373
  value: input.operations
1362
- })) && input.operations.map((elem, _index3) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
1363
- path: _path + ".operations[" + _index3 + "]",
1364
- expected: "AutoBeOpenApi.IOperation",
1374
+ })) && input.operations.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
1375
+ path: _path + ".operations[" + _index4 + "]",
1376
+ expected: "IAutoBeInterfaceOperationApplication.IOperation",
1365
1377
  value: elem
1366
- })) && _vo1(elem, _path + ".operations[" + _index3 + "]", true && _exceptionable) || _report(_exceptionable, {
1367
- path: _path + ".operations[" + _index3 + "]",
1368
- expected: "AutoBeOpenApi.IOperation",
1378
+ })) && _vo1(elem, _path + ".operations[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
1379
+ path: _path + ".operations[" + _index4 + "]",
1380
+ expected: "IAutoBeInterfaceOperationApplication.IOperation",
1369
1381
  value: elem
1370
1382
  })).every(flag => flag) || _report(_exceptionable, {
1371
1383
  path: _path + ".operations",
1372
- expected: "Array<AutoBeOpenApi.IOperation>",
1384
+ expected: "Array<IAutoBeInterfaceOperationApplication.IOperation>",
1373
1385
  value: input.operations
1374
- })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.specification || _report(_exceptionable, {
1375
- path: _path + ".specification",
1376
- expected: "string",
1377
- value: input.specification
1386
+ })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => [(Array.isArray(input.authorizationRoles) || _report(_exceptionable, {
1387
+ path: _path + ".authorizationRoles",
1388
+ expected: "Array<string & MinLength<1>>",
1389
+ value: input.authorizationRoles
1390
+ })) && input.authorizationRoles.map((elem, _index5) => "string" === typeof elem && (1 <= elem.length || _report(_exceptionable, {
1391
+ path: _path + ".authorizationRoles[" + _index5 + "]",
1392
+ expected: "string & MinLength<1>",
1393
+ value: elem
1394
+ })) || _report(_exceptionable, {
1395
+ path: _path + ".authorizationRoles[" + _index5 + "]",
1396
+ expected: "(string & MinLength<1>)",
1397
+ value: elem
1398
+ })).every(flag => flag) || _report(_exceptionable, {
1399
+ path: _path + ".authorizationRoles",
1400
+ expected: "Array<string & MinLength<1>>",
1401
+ value: input.authorizationRoles
1378
1402
  }), "string" === typeof input.description || _report(_exceptionable, {
1379
1403
  path: _path + ".description",
1380
1404
  expected: "string",
1381
1405
  value: input.description
1406
+ }), "string" === typeof input.name || _report(_exceptionable, {
1407
+ path: _path + ".name",
1408
+ expected: "string",
1409
+ value: input.name
1410
+ }), "string" === typeof input.specification || _report(_exceptionable, {
1411
+ path: _path + ".specification",
1412
+ expected: "string",
1413
+ value: input.specification
1382
1414
  }), "string" === typeof input.summary || _report(_exceptionable, {
1383
1415
  path: _path + ".summary",
1384
1416
  expected: "string",
1385
1417
  value: input.summary
1418
+ }), "string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
1419
+ path: _path + ".path",
1420
+ expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
1421
+ value: input.path
1422
+ })) || _report(_exceptionable, {
1423
+ path: _path + ".path",
1424
+ expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
1425
+ value: input.path
1386
1426
  }), (Array.isArray(input.parameters) || _report(_exceptionable, {
1387
1427
  path: _path + ".parameters",
1388
1428
  expected: "Array<AutoBeOpenApi.IParameter>",
1389
1429
  value: input.parameters
1390
- })) && input.parameters.map((elem, _index4) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
1391
- path: _path + ".parameters[" + _index4 + "]",
1430
+ })) && input.parameters.map((elem, _index6) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
1431
+ path: _path + ".parameters[" + _index6 + "]",
1392
1432
  expected: "AutoBeOpenApi.IParameter",
1393
1433
  value: elem
1394
- })) && _vo2(elem, _path + ".parameters[" + _index4 + "]", true && _exceptionable) || _report(_exceptionable, {
1395
- path: _path + ".parameters[" + _index4 + "]",
1434
+ })) && _vo2(elem, _path + ".parameters[" + _index6 + "]", true && _exceptionable) || _report(_exceptionable, {
1435
+ path: _path + ".parameters[" + _index6 + "]",
1396
1436
  expected: "AutoBeOpenApi.IParameter",
1397
1437
  value: elem
1398
1438
  })).every(flag => flag) || _report(_exceptionable, {
@@ -1415,22 +1455,6 @@ const collection = {
1415
1455
  path: _path + ".responseBody",
1416
1456
  expected: "(AutoBeOpenApi.IResponseBody | null)",
1417
1457
  value: input.responseBody
1418
- }), null === input.authorizationRole || "string" === typeof input.authorizationRole && (1 <= input.authorizationRole.length || _report(_exceptionable, {
1419
- path: _path + ".authorizationRole",
1420
- expected: "string & MinLength<1>",
1421
- value: input.authorizationRole
1422
- })) || _report(_exceptionable, {
1423
- path: _path + ".authorizationRole",
1424
- expected: "((string & MinLength<1>) | null)",
1425
- value: input.authorizationRole
1426
- }), "string" === typeof input.name || _report(_exceptionable, {
1427
- path: _path + ".name",
1428
- expected: "string",
1429
- value: input.name
1430
- }), "string" === typeof input.path || _report(_exceptionable, {
1431
- path: _path + ".path",
1432
- expected: "string",
1433
- value: input.path
1434
1458
  }), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
1435
1459
  path: _path + ".method",
1436
1460
  expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
@@ -1586,11 +1610,11 @@ const collection = {
1586
1610
  _report = __typia_transform__validateReport._validateReport(errors);
1587
1611
  ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
1588
1612
  path: _path + "",
1589
- expected: "IMakeOperationProps",
1613
+ expected: "IAutoBeInterfaceOperationApplication.IProps",
1590
1614
  value: input
1591
1615
  })) && _vo0(input, _path + "", true) || _report(true, {
1592
1616
  path: _path + "",
1593
- expected: "IMakeOperationProps",
1617
+ expected: "IAutoBeInterfaceOperationApplication.IProps",
1594
1618
  value: input
1595
1619
  }))(input, "$input", true);
1596
1620
  const success = 0 === errors.length;