@autobe/agent 0.27.0 → 0.28.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 (109) hide show
  1. package/lib/constants/AutoBeSystemPromptConstant.d.ts +1 -1
  2. package/lib/context/assertSchemaModel.d.ts +1 -1
  3. package/lib/context/assertSchemaModel.js +4 -7
  4. package/lib/context/assertSchemaModel.js.map +1 -1
  5. package/lib/index.mjs +18186 -7689
  6. package/lib/index.mjs.map +1 -1
  7. package/lib/orchestrate/analyze/histories/transformAnalyzeScenarioHistories.js +1 -1
  8. package/lib/orchestrate/analyze/histories/transformAnalyzeScenarioHistories.js.map +1 -1
  9. package/lib/orchestrate/analyze/orchestrateAnalyzeReview.js +164 -86
  10. package/lib/orchestrate/analyze/orchestrateAnalyzeReview.js.map +1 -1
  11. package/lib/orchestrate/analyze/orchestrateAnalyzeScenario.js +656 -335
  12. package/lib/orchestrate/analyze/orchestrateAnalyzeScenario.js.map +1 -1
  13. package/lib/orchestrate/analyze/orchestrateAnalyzeWrite.js +143 -74
  14. package/lib/orchestrate/analyze/orchestrateAnalyzeWrite.js.map +1 -1
  15. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeReviewApplication.d.ts +17 -52
  16. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioApplication.d.ts +25 -22
  17. package/lib/orchestrate/analyze/structures/IAutoBeAnalyzeWriteApplication.d.ts +7 -23
  18. package/lib/orchestrate/common/orchestrateCommonCorrectCasting.js +165 -2
  19. package/lib/orchestrate/common/orchestrateCommonCorrectCasting.js.map +1 -1
  20. package/lib/orchestrate/facade/createAutoBeFacadeController.js +773 -403
  21. package/lib/orchestrate/facade/createAutoBeFacadeController.js.map +1 -1
  22. package/lib/orchestrate/interface/orchestrateInterfaceAuthorizations.js +749 -2
  23. package/lib/orchestrate/interface/orchestrateInterfaceAuthorizations.js.map +1 -1
  24. package/lib/orchestrate/interface/orchestrateInterfaceComplement.js +1637 -9
  25. package/lib/orchestrate/interface/orchestrateInterfaceComplement.js.map +1 -1
  26. package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js +252 -133
  27. package/lib/orchestrate/interface/orchestrateInterfaceEndpoints.js.map +1 -1
  28. package/lib/orchestrate/interface/orchestrateInterfaceEndpointsReview.js +258 -135
  29. package/lib/orchestrate/interface/orchestrateInterfaceEndpointsReview.js.map +1 -1
  30. package/lib/orchestrate/interface/orchestrateInterfaceGroups.js +342 -226
  31. package/lib/orchestrate/interface/orchestrateInterfaceGroups.js.map +1 -1
  32. package/lib/orchestrate/interface/orchestrateInterfaceOperations.js +633 -1
  33. package/lib/orchestrate/interface/orchestrateInterfaceOperations.js.map +1 -1
  34. package/lib/orchestrate/interface/orchestrateInterfaceOperationsReview.js +785 -3
  35. package/lib/orchestrate/interface/orchestrateInterfaceOperationsReview.js.map +1 -1
  36. package/lib/orchestrate/interface/orchestrateInterfacePrerequisites.js +206 -3
  37. package/lib/orchestrate/interface/orchestrateInterfacePrerequisites.js.map +1 -1
  38. package/lib/orchestrate/interface/orchestrateInterfaceSchemaRename.js +107 -1
  39. package/lib/orchestrate/interface/orchestrateInterfaceSchemaRename.js.map +1 -1
  40. package/lib/orchestrate/interface/orchestrateInterfaceSchemaReview.js +1676 -9
  41. package/lib/orchestrate/interface/orchestrateInterfaceSchemaReview.js.map +1 -1
  42. package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js +1637 -9
  43. package/lib/orchestrate/interface/orchestrateInterfaceSchemas.js.map +1 -1
  44. package/lib/orchestrate/prisma/orchestratePrismaComponent.js +397 -201
  45. package/lib/orchestrate/prisma/orchestratePrismaComponent.js.map +1 -1
  46. package/lib/orchestrate/prisma/orchestratePrismaCorrect.js +1184 -599
  47. package/lib/orchestrate/prisma/orchestratePrismaCorrect.js.map +1 -1
  48. package/lib/orchestrate/prisma/orchestratePrismaReview.js +1202 -608
  49. package/lib/orchestrate/prisma/orchestratePrismaReview.js.map +1 -1
  50. package/lib/orchestrate/prisma/orchestratePrismaSchemas.js +4 -2
  51. package/lib/orchestrate/prisma/orchestratePrismaSchemas.js.map +1 -1
  52. package/lib/orchestrate/realize/orchestrateRealizeAuthorization.js +369 -185
  53. package/lib/orchestrate/realize/orchestrateRealizeAuthorization.js.map +1 -1
  54. package/lib/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js +405 -203
  55. package/lib/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.js.map +1 -1
  56. package/lib/orchestrate/realize/orchestrateRealizeCorrect.js +130 -2
  57. package/lib/orchestrate/realize/orchestrateRealizeCorrect.js.map +1 -1
  58. package/lib/orchestrate/realize/orchestrateRealizeCorrectCasting.js +165 -2
  59. package/lib/orchestrate/realize/orchestrateRealizeCorrectCasting.js.map +1 -1
  60. package/lib/orchestrate/realize/orchestrateRealizeWrite.js +130 -2
  61. package/lib/orchestrate/realize/orchestrateRealizeWrite.js.map +1 -1
  62. package/lib/orchestrate/test/histories/transformTestWriteHistories.js.map +1 -1
  63. package/lib/orchestrate/test/orchestrateTestCorrect.js +131 -2
  64. package/lib/orchestrate/test/orchestrateTestCorrect.js.map +1 -1
  65. package/lib/orchestrate/test/orchestrateTestCorrectInvalidRequest.js +166 -2
  66. package/lib/orchestrate/test/orchestrateTestCorrectInvalidRequest.js.map +1 -1
  67. package/lib/orchestrate/test/orchestrateTestScenario.js +257 -3
  68. package/lib/orchestrate/test/orchestrateTestScenario.js.map +1 -1
  69. package/lib/orchestrate/test/orchestrateTestScenarioReview.js +283 -3
  70. package/lib/orchestrate/test/orchestrateTestScenarioReview.js.map +1 -1
  71. package/lib/orchestrate/test/orchestrateTestWrite.js +139 -2
  72. package/lib/orchestrate/test/orchestrateTestWrite.js.map +1 -1
  73. package/package.json +9 -9
  74. package/src/constants/AutoBeSystemPromptConstant.ts +1 -1
  75. package/src/context/assertSchemaModel.ts +5 -8
  76. package/src/orchestrate/analyze/orchestrateAnalyzeReview.ts +7 -9
  77. package/src/orchestrate/analyze/orchestrateAnalyzeScenario.ts +13 -9
  78. package/src/orchestrate/analyze/orchestrateAnalyzeWrite.ts +7 -9
  79. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeReviewApplication.ts +19 -54
  80. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeScenarioApplication.ts +25 -22
  81. package/src/orchestrate/analyze/structures/IAutoBeAnalyzeWriteApplication.ts +8 -24
  82. package/src/orchestrate/common/orchestrateCommonCorrectCasting.ts +15 -1
  83. package/src/orchestrate/facade/createAutoBeFacadeController.ts +7 -6
  84. package/src/orchestrate/interface/orchestrateInterfaceAuthorizations.ts +11 -1
  85. package/src/orchestrate/interface/orchestrateInterfaceComplement.ts +11 -1
  86. package/src/orchestrate/interface/orchestrateInterfaceEndpoints.ts +13 -9
  87. package/src/orchestrate/interface/orchestrateInterfaceEndpointsReview.ts +13 -9
  88. package/src/orchestrate/interface/orchestrateInterfaceGroups.ts +17 -14
  89. package/src/orchestrate/interface/orchestrateInterfaceOperations.ts +11 -1
  90. package/src/orchestrate/interface/orchestrateInterfaceOperationsReview.ts +14 -1
  91. package/src/orchestrate/interface/orchestrateInterfacePrerequisites.ts +11 -1
  92. package/src/orchestrate/interface/orchestrateInterfaceSchemaRename.ts +9 -1
  93. package/src/orchestrate/interface/orchestrateInterfaceSchemaReview.ts +14 -1
  94. package/src/orchestrate/interface/orchestrateInterfaceSchemas.ts +11 -1
  95. package/src/orchestrate/prisma/orchestratePrismaComponent.ts +13 -9
  96. package/src/orchestrate/prisma/orchestratePrismaCorrect.ts +7 -9
  97. package/src/orchestrate/prisma/orchestratePrismaReview.ts +7 -10
  98. package/src/orchestrate/realize/orchestrateRealizeAuthorization.ts +13 -9
  99. package/src/orchestrate/realize/orchestrateRealizeAuthorizationCorrect.ts +13 -9
  100. package/src/orchestrate/realize/orchestrateRealizeCorrect.ts +11 -1
  101. package/src/orchestrate/realize/orchestrateRealizeCorrectCasting.ts +15 -1
  102. package/src/orchestrate/realize/orchestrateRealizeWrite.ts +11 -1
  103. package/src/orchestrate/test/experimental/orchestrateTestWrite.ast +5 -1
  104. package/src/orchestrate/test/histories/transformTestWriteHistories.ts +1 -1
  105. package/src/orchestrate/test/orchestrateTestCorrect.ts +11 -1
  106. package/src/orchestrate/test/orchestrateTestCorrectInvalidRequest.ts +18 -1
  107. package/src/orchestrate/test/orchestrateTestScenario.ts +11 -1
  108. package/src/orchestrate/test/orchestrateTestScenarioReview.ts +11 -1
  109. package/src/orchestrate/test/orchestrateTestWrite.ts +11 -1
@@ -527,7 +527,11 @@ function createController(props) {
527
527
  }
528
528
  return result;
529
529
  };
530
- const application = collection[props.model === "chatgpt" ? "chatgpt" : "claude"](validate);
530
+ const application = collection[props.model === "chatgpt"
531
+ ? "chatgpt"
532
+ : props.model === "gemini"
533
+ ? "gemini"
534
+ : "claude"](validate);
531
535
  return {
532
536
  protocol: "class",
533
537
  name: "Create Authorization Interface",
@@ -892,10 +896,11 @@ const collection = {
892
896
  ]
893
897
  },
894
898
  "AutoBeOpenApi.IPrerequisite": {
895
- description: "Prerequisite API operation dependency.\n\n`IPrerequisite` defines a dependency relationship between API operations,\nspecifying that certain endpoints must be successfully called before the\ncurrent operation can proceed. This ensures proper resource validation,\nstate checking, and data availability in complex API workflows.\n\n## CRITICAL WARNING: Authentication is NOT a Prerequisite\n\n**NEVER use prerequisites for authentication or authorization checks!**\n\nPrerequisites are ONLY for business logic dependencies such as:\n\n- Checking if a resource exists\n- Verifying resource state\n- Loading required data\n\nDo NOT create prerequisites for:\n\n- Login/authentication endpoints\n- Token validation\n- Permission checks\n- User authorization verification\n\nAuthentication is handled separately via the `authorizationActor` field on\nthe operation itself. Mixing authentication with business prerequisites\ncreates confusion and incorrect test scenarios.\n\n## Core Concept\n\nPrerequisites create an execution dependency graph for API operations. They\nexplicitly declare which APIs must succeed before attempting the current\noperation, preventing invalid states and ensuring data consistency.\n\n## Structure\n\nEach prerequisite consists of:\n\n1. **endpoint**: The API endpoint that must be called first\n2. **description**: Clear explanation of why this prerequisite is required\n\n## Common Use Cases\n\n### 1. Resource Existence Validation\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/users/{userId}\", \"method\": \"get\" },\n \"description\": \"User must exist before updating their profile\"\n}\n```\n\n### 2. Parent-Child Relationships\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/posts/{postId}\", \"method\": \"get\" },\n \"description\": \"Post must exist before adding comments\"\n}\n```\n\n### 3. State Prerequisites\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/orders/{orderId}/status\", \"method\": \"get\" },\n \"description\": \"Order must be in 'confirmed' state before shipping\"\n}\n```\n\n### 4. Business Logic Dependencies\n\n```typescript\n{\n \"endpoint\": {\n \"path\": \"/inventory/{productId}/stock\",\n \"method\": \"get\"\n },\n \"description\": \"Product must have sufficient stock before creating order\"\n}\n```\n\n## Implementation Guidelines\n\n1. **Clear Descriptions**: Always explain WHY the prerequisite is needed\n2. **Minimal Dependencies**: Only include truly necessary prerequisites\n3. **Logical Order**: If multiple prerequisites exist, order them logically\n4. **Error Context**: Description should help understand failure scenarios\n5. **No Authentication**: Prerequisites must NEVER be authentication checks\n\n## Test Generation Usage\n\nThe Test Agent utilizes prerequisites to:\n\n- Set up test data in the correct sequence\n- Generate realistic test scenarios\n- Create both positive and negative test cases\n- Ensure proper cleanup in reverse dependency order\n\n## Best Practices\n\n- Keep prerequisite chains as short as possible for performance\n- Consider caching prerequisite results when safe to do so\n- Ensure prerequisite descriptions are specific, not generic\n- Validate that circular dependencies don't exist\n- Document any side effects of prerequisite calls\n- NEVER use for authentication/authorization validation\n\n### Description of {@link endpoint} property:\n\n> The API endpoint that must be called before the main operation.\n> \n> This specifies the exact HTTP method and path of the prerequisite API.\n> The endpoint must be a valid operation defined elsewhere in the API\n> specification. Path parameters in the prerequisite endpoint can reference\n> the same parameters available in the main operation.",
899
+ description: "Prerequisite API operation dependency.\n\n`IPrerequisite` defines a dependency relationship between API operations,\nspecifying that certain endpoints must be successfully called before the\ncurrent operation can proceed. This ensures proper resource validation,\nstate checking, and data availability in complex API workflows.\n\n## CRITICAL WARNING: Authentication is NOT a Prerequisite\n\n**NEVER use prerequisites for authentication or authorization checks!**\n\nPrerequisites are ONLY for business logic dependencies such as:\n\n- Checking if a resource exists\n- Verifying resource state\n- Loading required data\n\nDo NOT create prerequisites for:\n\n- Login/authentication endpoints\n- Token validation\n- Permission checks\n- User authorization verification\n\nAuthentication is handled separately via the `authorizationActor` field on\nthe operation itself. Mixing authentication with business prerequisites\ncreates confusion and incorrect test scenarios.\n\n## Core Concept\n\nPrerequisites create an execution dependency graph for API operations. They\nexplicitly declare which APIs must succeed before attempting the current\noperation, preventing invalid states and ensuring data consistency.\n\n## Structure\n\nEach prerequisite consists of:\n\n1. **endpoint**: The API endpoint that must be called first\n2. **description**: Clear explanation of why this prerequisite is required\n\n## Common Use Cases\n\n### 1. Resource Existence Validation\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/users/{userId}\", \"method\": \"get\" },\n \"description\": \"User must exist before updating their profile\"\n}\n```\n\n### 2. Parent-Child Relationships\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/posts/{postId}\", \"method\": \"get\" },\n \"description\": \"Post must exist before adding comments\"\n}\n```\n\n### 3. State Prerequisites\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/orders/{orderId}/status\", \"method\": \"get\" },\n \"description\": \"Order must be in 'confirmed' state before shipping\"\n}\n```\n\n### 4. Business Logic Dependencies\n\n```typescript\n{\n \"endpoint\": {\n \"path\": \"/inventory/{productId}/stock\",\n \"method\": \"get\"\n },\n \"description\": \"Product must have sufficient stock before creating order\"\n}\n```\n\n## Implementation Guidelines\n\n1. **Clear Descriptions**: Always explain WHY the prerequisite is needed\n2. **Minimal Dependencies**: Only include truly necessary prerequisites\n3. **Logical Order**: If multiple prerequisites exist, order them logically\n4. **Error Context**: Description should help understand failure scenarios\n5. **No Authentication**: Prerequisites must NEVER be authentication checks\n\n## Test Generation Usage\n\nThe Test Agent utilizes prerequisites to:\n\n- Set up test data in the correct sequence\n- Generate realistic test scenarios\n- Create both positive and negative test cases\n- Ensure proper cleanup in reverse dependency order\n\n## Best Practices\n\n- Keep prerequisite chains as short as possible for performance\n- Consider caching prerequisite results when safe to do so\n- Ensure prerequisite descriptions are specific, not generic\n- Validate that circular dependencies don't exist\n- Document any side effects of prerequisite calls\n- NEVER use for authentication/authorization validation",
896
900
  type: "object",
897
901
  properties: {
898
902
  endpoint: {
903
+ description: "The API endpoint that must be called before the main operation.\n\nThis specifies the exact HTTP method and path of the prerequisite API.\nThe endpoint must be a valid operation defined elsewhere in the API\nspecification. Path parameters in the prerequisite endpoint can reference\nthe same parameters available in the main operation.",
899
904
  $ref: "#/$defs/AutoBeOpenApi.IEndpoint"
900
905
  },
901
906
  description: {
@@ -2065,5 +2070,747 @@ const collection = {
2065
2070
  }), { equals: false }));
2066
2071
  return application;
2067
2072
  })(),
2073
+ gemini: (validate) => (() => {
2074
+ const application = {
2075
+ model: "gemini",
2076
+ options: {
2077
+ reference: true,
2078
+ separate: null
2079
+ },
2080
+ functions: [
2081
+ {
2082
+ name: "makeOperations",
2083
+ parameters: {
2084
+ description: "Current Type: {@link IAutoBeInterfaceAuthorizationsApplication.IProps}",
2085
+ type: "object",
2086
+ properties: {
2087
+ operations: {
2088
+ description: "Array of API operations to generate authorization operation for.\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.",
2089
+ type: "array",
2090
+ items: {
2091
+ $ref: "#/$defs/AutoBeOpenApi.IOperation"
2092
+ },
2093
+ minItems: 1
2094
+ }
2095
+ },
2096
+ required: [
2097
+ "operations"
2098
+ ],
2099
+ additionalProperties: false,
2100
+ $defs: {
2101
+ "AutoBeOpenApi.IOperation": {
2102
+ 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}\n```",
2103
+ type: "object",
2104
+ properties: {
2105
+ specification: {
2106
+ 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.",
2107
+ type: "string"
2108
+ },
2109
+ authorizationType: {
2110
+ description: "Authorization type of the API operation.\n\n- `\"login\"`: User login operations that validate credentials\n- `\"join\"`: User registration operations that create accounts\n- `\"refresh\"`: Token refresh operations that renew access tokens\n- `null`: All other operations (CRUD, business logic, etc.)\n\nUse authentication values only for credential validation, user\nregistration, or token refresh operations. Use `null` for all other\nbusiness operations.\n\nExamples:\n\n- `/auth/login` \u2192 `\"login\"`\n- `/auth/register` \u2192 `\"join\"`\n- `/auth/refresh` \u2192 `\"refresh\"`\n- `/auth/validate` \u2192 `null`\n- `/users/{id}`, `/shoppings/customers/sales/cancel`, \u2192 `null`",
2111
+ anyOf: [
2112
+ {
2113
+ type: "null"
2114
+ },
2115
+ {
2116
+ type: "string",
2117
+ "enum": [
2118
+ "login",
2119
+ "join",
2120
+ "refresh"
2121
+ ]
2122
+ }
2123
+ ]
2124
+ },
2125
+ description: {
2126
+ description: "Detailed description about the API operation.\n\nIMPORTANT: This field MUST be extensively detailed and MUST reference the\ndescription comments from the related Prisma DB schema tables and\ncolumns. The description should be organized into MULTIPLE PARAGRAPHS\nseparated by line breaks to improve readability and comprehension.\n\nFor example, include separate paragraphs for:\n\n- The purpose and overview of the API operation\n- Security considerations and user permissions\n- Relationship to underlying database entities\n- Validation rules and business logic\n- Related API operations that might be used together with this one\n- Expected behavior and error handling\n\nWhen writing the description, be sure to incorporate the corresponding DB\nschema's description comments, matching the level of detail and style of\nthose comments. This ensures consistency between the API documentation\nand database structure.\n\nIf there's a dependency to other APIs, please describe the dependency API\noperation in this field with detailed reason. For example, if this API\noperation needs a pre-execution of other API operation, it must be\nexplicitly described.\n\n- `GET /shoppings/customers/sales` must be pre-executed to get entire list\n of summarized sales. Detailed sale information would be obtained by\n specifying the sale ID in the path parameter.\n\n**CRITICAL WARNING about soft delete keywords**: DO NOT use terms like\n\"soft delete\", \"soft-delete\", or similar variations in this description\nUNLESS the operation actually implements soft deletion. These keywords\ntrigger validation logic that expects a corresponding soft_delete_column\nto be specified. Only use these terms when you intend to implement soft\ndeletion (marking records as deleted without removing them from the\ndatabase).\n\nExample of problematic description: \u274C \"This would normally be a\nsoft-delete, but we intentionally perform permanent deletion here\" - This\ntriggers soft delete validation despite being a hard delete operation.\n\n> MUST be written in English. Never use other languages.",
2127
+ type: "string"
2128
+ },
2129
+ summary: {
2130
+ description: "Short summary of the API operation.\n\nThis should be a concise description of the API operation, typically one\nsentence long. It should provide a quick overview of what the API does\nwithout going into too much detail.\n\nThis summary will be used in the OpenAPI documentation to give users a\nquick understanding of the API operation's purpose.\n\nIMPORTANT: The summary should clearly indicate which Prisma DB table this\noperation relates to, helping to ensure all tables have API coverage.\n\n**CRITICAL WARNING about soft delete keywords**: DO NOT use terms like\n\"soft delete\", \"soft-delete\", or similar variations in this summary\nUNLESS the operation actually implements soft deletion. These keywords\ntrigger validation logic that expects a corresponding soft_delete_column\nto be specified. Only use these terms when you intend to implement soft\ndeletion (marking records as deleted without removing them from the\ndatabase).\n\n> MUST be written in English. Never use other languages",
2131
+ type: "string"
2132
+ },
2133
+ parameters: {
2134
+ 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`",
2135
+ type: "array",
2136
+ items: {
2137
+ $ref: "#/$defs/AutoBeOpenApi.IParameter"
2138
+ }
2139
+ },
2140
+ requestBody: {
2141
+ description: "Request body of the API operation.\n\nDefines the payload structure for the request. Contains a description and\nschema reference to define the expected input data.\n\nShould be `null` for operations that don't require a request body, such\nas most \"get\" operations.",
2142
+ anyOf: [
2143
+ {
2144
+ type: "null"
2145
+ },
2146
+ {
2147
+ $ref: "#/$defs/AutoBeOpenApi.IRequestBody"
2148
+ }
2149
+ ]
2150
+ },
2151
+ responseBody: {
2152
+ description: "Response body of the API operation.\n\nDefines the structure of the successful response data. Contains a\ndescription and schema reference for the returned data.\n\nShould be null for operations that don't return any data.",
2153
+ anyOf: [
2154
+ {
2155
+ type: "null"
2156
+ },
2157
+ {
2158
+ $ref: "#/$defs/AutoBeOpenApi.IResponseBody"
2159
+ }
2160
+ ]
2161
+ },
2162
+ authorizationActor: {
2163
+ description: "Authorization actor required to access this API operation.\n\nThis field specifies which user actor is allowed to access this endpoint.\nThe actor name must correspond exactly to the actual actors defined in\nyour system's Prisma schema.\n\n## Naming Convention\n\nActor names MUST use camelCase.\n\n## Actor-Based Path Convention\n\nWhen authorizationActor is specified, it should align with the path\nstructure:\n\n- If authorizationActor is \"admin\" \u2192 path might be \"/admin/resources/{id}\"\n- If authorizationActor is \"seller\" \u2192 path might be \"/seller/products\"\n- Special case: For user's own resources, use path prefix \"/my/\" regardless\n of actor\n\n## Important Guidelines\n\n- Set to `null` for public endpoints that require no authentication\n- Set to specific actor string for actor-restricted endpoints\n- The actor name MUST match exactly with the user type/actor defined in the\n database\n- This actor 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 actor\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.",
2164
+ anyOf: [
2165
+ {
2166
+ type: "null"
2167
+ },
2168
+ {
2169
+ type: "string",
2170
+ pattern: "^[a-z][a-zA-Z0-9]*$",
2171
+ minLength: 1
2172
+ }
2173
+ ]
2174
+ },
2175
+ name: {
2176
+ description: "Functional name of the API endpoint.\n\nThis is a semantic identifier that represents the primary function or\npurpose of the API endpoint. It serves as a canonical name that can be\nused for code generation, SDK method names, and internal references.\n\n## Reserved Word Restrictions\n\nCRITICAL: The name MUST NOT be a TypeScript/JavaScript reserved word, as\nit will be used as a class method name in generated code. Avoid names\nlike:\n\n- `delete`, `for`, `if`, `else`, `while`, `do`, `switch`, `case`, `break`\n- `continue`, `function`, `return`, `with`, `in`, `of`, `instanceof`\n- `typeof`, `void`, `var`, `let`, `const`, `class`, `extends`, `import`\n- `export`, `default`, `try`, `catch`, `finally`, `throw`, `new`\n- `super`, `this`, `null`, `true`, `false`, `async`, `await`\n- `yield`, `static`, `private`, `protected`, `public`, `implements`\n- `interface`, `package`, `enum`, `debugger`\n\nInstead, use alternative names for these operations:\n\n- Use `erase` instead of `delete`\n- Use `iterate` instead of `for`\n- Use `when` instead of `if`\n- Use `cls` instead of `class`\n\n## Standard Endpoint Names\n\nUse these conventional names based on the endpoint's primary function:\n\n- **`index`**: List/search operations that return multiple entities\n\n - Typically used with PATCH method for complex queries\n - Example: `PATCH /users` \u2192 `name: \"index\"`\n- **`at`**: Retrieve a specific entity by identifier\n\n - Typically used with GET method on single resource\n - Example: `GET /users/{userId}` \u2192 `name: \"at\"`\n- **`create`**: Create a new entity\n\n - Typically used with POST method\n - Example: `POST /users` \u2192 `name: \"create\"`\n- **`update`**: Update an existing entity\n\n - Typically used with PUT method\n - Example: `PUT /users/{userId}` \u2192 `name: \"update\"`\n- **`erase`**: Delete/remove an entity (NOT `delete` - reserved word!)\n\n - Typically used with DELETE method\n - Example: `DELETE /users/{userId}` \u2192 `name: \"erase\"`\n\n## Custom Endpoint Names\n\nFor specialized operations beyond basic CRUD, use descriptive verbs:\n\n- **`activate`**: Enable or turn on a feature/entity\n- **`deactivate`**: Disable or turn off a feature/entity\n- **`approve`**: Approve a request or entity\n- **`reject`**: Reject a request or entity\n- **`publish`**: Make content publicly available\n- **`archive`**: Move to archived state\n- **`restore`**: Restore from archived/deleted state\n- **`duplicate`**: Create a copy of an entity\n- **`transfer`**: Move ownership or change assignment\n- **`validate`**: Validate data or state\n- **`process`**: Execute a business process or workflow\n- **`export`**: Generate downloadable data\n- **`import`**: Process uploaded data\n\n## Naming Guidelines\n\n- MUST use camelCase naming convention\n- Use singular verb forms\n- Be concise but descriptive\n- Avoid abbreviations unless widely understood\n- Ensure the name clearly represents the endpoint's primary action\n- For nested resources, focus on the action rather than hierarchy\n- NEVER use JavaScript/TypeScript reserved words\n\nValid Examples:\n\n- `index`, `create`, `update`, `erase` (single word)\n- `updatePassword`, `cancelOrder`, `publishArticle` (camelCase)\n- `validateEmail`, `generateReport`, `exportData` (camelCase)\n\nInvalid Examples:\n\n- `update_password` (snake_case not allowed)\n- `UpdatePassword` (PascalCase not allowed)\n- `update-password` (kebab-case not allowed)\n\nPath to Name Examples:\n\n- `GET /shopping/orders/{orderId}/items` \u2192 `name: \"index\"` (lists items)\n- `POST /shopping/orders/{orderId}/cancel` \u2192 `name: \"cancel\"`\n- `PUT /users/{userId}/password` \u2192 `name: \"updatePassword\"`\n\n## Uniqueness Rule\n\nThe `name` must be unique within the API's accessor namespace. The\naccessor is formed by combining the path segments (excluding parameters)\nwith the operation name.\n\nAccessor formation:\n\n1. Extract non-parameter segments from the path (remove `{...}` parts)\n2. Join segments with dots\n3. Append the operation name\n\nExamples:\n\n- Path: `/shopping/sale/{saleId}/review/{reviewId}`, Name: `at` \u2192 Accessor:\n `shopping.sale.review.at`\n- Path: `/users/{userId}/posts`, Name: `index` \u2192 Accessor:\n `users.posts.index`\n- Path: `/auth/login`, Name: `signIn` \u2192 Accessor: `auth.login.signIn`\n\nEach accessor must be globally unique across the entire API. This ensures\noperations can be uniquely identified in generated SDKs and prevents\nnaming conflicts.",
2177
+ type: "string",
2178
+ pattern: "^[a-z][a-zA-Z0-9]*$"
2179
+ },
2180
+ prerequisites: {
2181
+ description: "Prerequisites for this API operation.\n\nThe `prerequisites` field defines API operations that must be\nsuccessfully executed before this operation can be performed. This\ncreates an explicit dependency chain between API endpoints, ensuring\nproper execution order and data availability.\n\n## CRITICAL WARNING: Authentication Prerequisites\n\n**NEVER include authentication-related operations as prerequisites!**\nAuthentication is handled separately through the `authorizationActor`\nfield and should NOT be part of the prerequisite chain. Do NOT add\nprerequisites for:\n\n- Login endpoints\n- Token validation endpoints\n- User authentication checks\n- Permission verification endpoints\n\nPrerequisites are ONLY for business logic dependencies, NOT for\nauthentication/authorization.\n\n## Purpose and Use Cases\n\nPrerequisites are essential for operations that depend on:\n\n1. **Existence Validation**: Ensuring resources exist before manipulation\n2. **State Requirements**: Verifying resources are in the correct state\n3. **Data Dependencies**: Loading necessary data for the current operation\n4. **Business Logic Constraints**: Enforcing domain-specific rules\n\n## Execution Flow\n\nWhen an operation has prerequisites:\n\n1. Each prerequisite API must be called first in the specified order\n2. Prerequisites must return successful responses (2xx status codes)\n3. Only after all prerequisites succeed can the main operation proceed\n4. If any prerequisite fails, the operation should not be attempted\n\n## Common Patterns\n\n### Resource Existence Check\n\n```typescript\n// Before updating an order item, ensure the order exists\nprerequisites: [\n {\n endpoint: { path: \"/orders/{orderId}\", method: \"get\" },\n description: \"Order must exist in the system\",\n },\n];\n```\n\n### State Validation\n\n```typescript\n// Before processing payment, ensure order is in correct state\nprerequisites: [\n {\n endpoint: { path: \"/orders/{orderId}/status\", method: \"get\" },\n description: \"Order must be in 'pending_payment' status\",\n },\n];\n```\n\n### Hierarchical Dependencies\n\n```typescript\n// Before accessing a deeply nested resource\nprerequisites: [\n {\n endpoint: { path: \"/projects/{projectId}\", method: \"get\" },\n description: \"Project must exist\",\n },\n {\n endpoint: {\n path: \"/projects/{projectId}/tasks/{taskId}\",\n method: \"get\",\n },\n description: \"Task must exist within the project\",\n },\n];\n```\n\n## Important Guidelines\n\n1. **Order Matters**: Prerequisites are executed in array order\n2. **Parameter Inheritance**: Path parameters from prerequisites can be used\n in the main operation\n3. **Error Handling**: Failed prerequisites should prevent main operation\n4. **Performance**: Consider caching prerequisite results when appropriate\n5. **Documentation**: Each prerequisite must have a clear description\n explaining why it's required\n6. **No Authentication**: NEVER use prerequisites for authentication checks\n\n## Test Generation Impact\n\nThe Test Agent uses prerequisites to:\n\n- Generate proper test setup sequences\n- Create valid test data in the correct order\n- Ensure test scenarios follow realistic workflows\n- Validate error handling when prerequisites fail",
2182
+ type: "array",
2183
+ items: {
2184
+ $ref: "#/$defs/AutoBeOpenApi.IPrerequisite"
2185
+ }
2186
+ },
2187
+ path: {
2188
+ 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)",
2189
+ type: "string",
2190
+ pattern: "^\\/[a-zA-Z0-9\\/_{}.-]*$"
2191
+ },
2192
+ method: {
2193
+ description: "HTTP method of the API operation.\n\n**IMPORTANT**: Methods must be written in lowercase only (e.g., \"get\",\nnot \"GET\").\n\nNote that, if the API operation has {@link requestBody}, method must not\nbe `get`.\n\nAlso, even though the API operation has been designed to only get\ninformation, but it needs complicated request information, it must be\ndefined as `patch` method with {@link requestBody} data specification.\n\n- `get`: get information\n- `patch`: get information with complicated request data\n ({@link requestBody})\n- `post`: create new record\n- `put`: update existing record\n- `delete`: remove record",
2194
+ type: "string",
2195
+ "enum": [
2196
+ "get",
2197
+ "post",
2198
+ "put",
2199
+ "delete",
2200
+ "patch"
2201
+ ]
2202
+ }
2203
+ },
2204
+ required: [
2205
+ "specification",
2206
+ "authorizationType",
2207
+ "description",
2208
+ "summary",
2209
+ "parameters",
2210
+ "requestBody",
2211
+ "responseBody",
2212
+ "authorizationActor",
2213
+ "name",
2214
+ "prerequisites",
2215
+ "path",
2216
+ "method"
2217
+ ]
2218
+ },
2219
+ "AutoBeOpenApi.IParameter": {
2220
+ description: "Path parameter information for API routes.\n\nThis interface defines a path parameter that appears in the URL of an API\nendpoint. Path parameters are enclosed in curly braces in the\n{@link AutoBeOpenApi.IOperation.path operation path} and must be defined\nwith their types and descriptions.\n\nFor example, if API operation path is\n`/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}`,\nthe path parameters should be like below:\n\n```json\n{\n \"path\": \"/shoppings/customers/sales/{saleId}/questions/${questionId}/comments/${commentId}\",\n \"method\": \"get\",\n \"parameters\": [\n {\n \"name\": \"saleId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target sale's ID\"\n },\n {\n \"name\": \"questionId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target question's ID\"\n },\n {\n \"name\": \"commentId\",\n \"in\": \"path\",\n \"schema\": { \"type\": \"string\", \"format\": \"uuid\" },\n \"description\": \"Target comment's ID\"\n }\n ]\n}\n```",
2221
+ type: "object",
2222
+ properties: {
2223
+ name: {
2224
+ description: "Identifier name of the path parameter.\n\nThis name must match exactly with the parameter name in the route path.\nIt must be corresponded to the\n{@link AutoBeOpenApi.IOperation.path API operation path}.\n\nMUST use camelCase naming convention.",
2225
+ type: "string",
2226
+ pattern: "^[a-z][a-zA-Z0-9]*$"
2227
+ },
2228
+ description: {
2229
+ description: "Description about the path parameter.\n\nMake short, concise and clear description about the path parameter.\n\n> MUST be written in English. Never use other languages.",
2230
+ type: "string"
2231
+ },
2232
+ schema: {
2233
+ description: "Type schema of the path parameter.\n\nPath parameters are typically primitive types like\n{@link AutoBeOpenApi.IJsonSchema.IString strings},\n{@link AutoBeOpenApi.IJsonSchema.IInteger integers},\n{@link AutoBeOpenApi.IJsonSchema.INumber numbers}.\n\nIf you need other types, please use request body instead with object type\nencapsulation.",
2234
+ anyOf: [
2235
+ {
2236
+ $ref: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber"
2237
+ },
2238
+ {
2239
+ $ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger"
2240
+ },
2241
+ {
2242
+ $ref: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
2243
+ }
2244
+ ],
2245
+ "x-discriminator": {
2246
+ propertyName: "type",
2247
+ mapping: {
2248
+ number: "#/$defs/AutoBeOpenApi.IJsonSchema.INumber",
2249
+ integer: "#/$defs/AutoBeOpenApi.IJsonSchema.IInteger",
2250
+ string: "#/$defs/AutoBeOpenApi.IJsonSchema.IString"
2251
+ }
2252
+ }
2253
+ }
2254
+ },
2255
+ required: [
2256
+ "name",
2257
+ "description",
2258
+ "schema"
2259
+ ]
2260
+ },
2261
+ "AutoBeOpenApi.IJsonSchema.INumber": {
2262
+ description: "Number (double) type info.",
2263
+ type: "object",
2264
+ properties: {
2265
+ minimum: {
2266
+ description: "Minimum value restriction.",
2267
+ type: "number"
2268
+ },
2269
+ maximum: {
2270
+ description: "Maximum value restriction.",
2271
+ type: "number"
2272
+ },
2273
+ exclusiveMinimum: {
2274
+ description: "Exclusive minimum value restriction.",
2275
+ type: "number"
2276
+ },
2277
+ exclusiveMaximum: {
2278
+ description: "Exclusive maximum value restriction.",
2279
+ type: "number"
2280
+ },
2281
+ multipleOf: {
2282
+ description: "Multiple of value restriction.",
2283
+ type: "number",
2284
+ exclusiveMinimum: 0
2285
+ },
2286
+ type: {
2287
+ description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
2288
+ type: "string",
2289
+ "enum": [
2290
+ "number"
2291
+ ]
2292
+ }
2293
+ },
2294
+ required: [
2295
+ "type"
2296
+ ]
2297
+ },
2298
+ "AutoBeOpenApi.IJsonSchema.IInteger": {
2299
+ description: "Integer type info.",
2300
+ type: "object",
2301
+ properties: {
2302
+ minimum: {
2303
+ description: "Minimum value restriction.",
2304
+ type: "integer"
2305
+ },
2306
+ maximum: {
2307
+ description: "Maximum value restriction.",
2308
+ type: "integer"
2309
+ },
2310
+ exclusiveMinimum: {
2311
+ description: "Exclusive minimum value restriction.",
2312
+ type: "number"
2313
+ },
2314
+ exclusiveMaximum: {
2315
+ description: "Exclusive maximum value restriction.",
2316
+ type: "number"
2317
+ },
2318
+ multipleOf: {
2319
+ description: "Multiple of value restriction.",
2320
+ type: "integer",
2321
+ exclusiveMinimum: 0
2322
+ },
2323
+ type: {
2324
+ description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
2325
+ type: "string",
2326
+ "enum": [
2327
+ "integer"
2328
+ ]
2329
+ }
2330
+ },
2331
+ required: [
2332
+ "type"
2333
+ ]
2334
+ },
2335
+ "AutoBeOpenApi.IJsonSchema.IString": {
2336
+ description: "String type info.",
2337
+ type: "object",
2338
+ properties: {
2339
+ format: {
2340
+ description: "Format restriction.",
2341
+ type: "string",
2342
+ "enum": [
2343
+ "date-time",
2344
+ "password",
2345
+ "regex",
2346
+ "uuid",
2347
+ "email",
2348
+ "hostname",
2349
+ "idn-email",
2350
+ "idn-hostname",
2351
+ "iri",
2352
+ "iri-reference",
2353
+ "ipv4",
2354
+ "ipv6",
2355
+ "uri",
2356
+ "uri-reference",
2357
+ "uri-template",
2358
+ "url",
2359
+ "date",
2360
+ "time",
2361
+ "duration",
2362
+ "json-pointer",
2363
+ "relative-json-pointer"
2364
+ ]
2365
+ },
2366
+ pattern: {
2367
+ description: "Pattern restriction.",
2368
+ type: "string"
2369
+ },
2370
+ contentMediaType: {
2371
+ description: "Content media type restriction.",
2372
+ type: "string"
2373
+ },
2374
+ minLength: {
2375
+ description: "Minimum length restriction.",
2376
+ type: "integer",
2377
+ minimum: 0
2378
+ },
2379
+ maxLength: {
2380
+ description: "Maximum length restriction.",
2381
+ type: "integer",
2382
+ minimum: 0
2383
+ },
2384
+ type: {
2385
+ description: "Discriminator value of the type.\n\nCRITICAL: This MUST be a SINGLE string value, NOT an array. The type\nfield identifies the JSON Schema type and must be exactly one of:\n\"boolean\", \"integer\", \"number\", \"string\", \"array\", \"object\", or\n\"null\".\n\n\u274C INCORRECT: type: [\"string\", \"null\"] // This is WRONG! \u2705 CORRECT:\ntype: \"string\" // For nullable string, use oneOf instead\n\nIf you need to express a nullable type (e.g., string | null), you MUST\nuse the `IOneOf` structure:\n\n```typescript\n{\n \"oneOf\": [{ \"type\": \"string\" }, { \"type\": \"null\" }]\n}\n```\n\nNEVER use array notation in the type field. The type field is a\ndiscriminator that accepts only a single string value.",
2386
+ type: "string",
2387
+ "enum": [
2388
+ "string"
2389
+ ]
2390
+ }
2391
+ },
2392
+ required: [
2393
+ "type"
2394
+ ]
2395
+ },
2396
+ "AutoBeOpenApi.IRequestBody": {
2397
+ description: "Request body information of OpenAPI operation.\n\nThis interface defines the structure for request bodies in API routes. It\ncorresponds to the requestBody section in OpenAPI specifications, providing\nboth a description and schema reference for the request payload.\n\nThe content-type for all request bodies is always `application/json`. Even\nwhen file uploading is required, don't use `multipart/form-data` or\n`application/x-www-form-urlencoded` content types. Instead, just define an\nURI string property in the request body schema.\n\nNote that, all body schemas must be transformable to a\n{@link AutoBeOpenApi.IJsonSchema.IReference reference} type defined in the\n{@link AutoBeOpenApi.IComponents.schemas components section} as an\n{@link AutoBeOpenApi.IJsonSchema.IObject object} type.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"requestBody\": {\n \"description\": \"Creation info of the order\",\n \"content\": {\n \"application/json\": {\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder.ICreate\"\n }\n }\n }\n }\n}\n```",
2398
+ type: "object",
2399
+ properties: {
2400
+ description: {
2401
+ description: "Description about the request body.\n\nMake short, concise and clear description about the request body.\n\n> MUST be written in English. Never use other languages.",
2402
+ type: "string"
2403
+ },
2404
+ typeName: {
2405
+ description: "Request body type name.\n\nThis specifies the data structure expected in the request body, that will\nbe transformed to {@link AutoBeOpenApi.IJsonSchema.IReference reference}\ntype in the {@link AutoBeOpenApi.IComponents.schemas components section}\nas an {@link AutoBeOpenApi.IJsonSchema.Object object} type.\n\nHere is the naming convention for the request body type:\n\n- `IEntityName.ICreate`: Request body for creation operations (POST)\n- `IEntityName.IUpdate`: Request body for update operations (PUT)\n- `IEntityName.IRequest`: Request parameters for list operations (often\n with search/pagination)\n\nWhat you write:\n\n```json\n{\n \"typeName\": \"IShoppingOrder.ICreate\"\n}\n```\n\nTransformed to:\n\n```json\n{\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder.ICreate\"\n }\n}\n```",
2406
+ type: "string"
2407
+ }
2408
+ },
2409
+ required: [
2410
+ "description",
2411
+ "typeName"
2412
+ ]
2413
+ },
2414
+ "AutoBeOpenApi.IResponseBody": {
2415
+ description: "Response body information for OpenAPI operation.\n\nThis interface defines the structure of a successful response from an API\noperation. It provides a description of the response and a schema reference\nto define the returned data structure.\n\nThe content-type for all responses is always `application/json`. Even when\nfile downloading is required, don't use `application/octet-stream` or\n`multipart/form-data` content types. Instead, just define an URI string\nproperty in the response body schema.\n\nIn OpenAPI, this might represent:\n\n```json\n{\n \"responses\": {\n \"200\": {\n \"description\": \"Order information\",\n \"content\": {\n \"application/json\": {\n \"schema\": { \"$ref\": \"#/components/schemas/IShoppingOrder\" }\n }\n }\n }\n }\n}\n```",
2416
+ type: "object",
2417
+ properties: {
2418
+ description: {
2419
+ description: "Description about the response body.\n\nMake short, concise and clear description about the response body.\n\n> MUST be written in English. Never use other languages.",
2420
+ type: "string"
2421
+ },
2422
+ typeName: {
2423
+ description: "Response body's data type.\n\nSpecifies the structure of the returned data (response body), that will\nbe transformed to {@link AutoBeOpenApi.IJsonSchema.IReference} type in the\n{@link AutoBeOpenApi.IComponents.schemas components section} as an\n{@link AutoBeOpenApi.IJsonSchema.IObject object} type.\n\nHere is the naming convention for the response body type:\n\n- `IEntityName`: Main entity with detailed information (e.g.,\n `IShoppingSale`)\n- `IEntityName.ISummary`: Simplified response version with essential\n properties\n- `IEntityName.IInvert`: Alternative view of an entity from a different\n perspective\n- `IPageIEntityName`: Paginated results container with `pagination` and\n `data` properties\n\nWhat you write:\n\n```json\n{\n \"typeName\": \"IShoppingOrder\"\n}\n```\n\nTransformed to:\n\n```json\n{\n \"schema\": {\n \"$ref\": \"#/components/schemas/IShoppingOrder\"\n }\n}\n```",
2424
+ type: "string"
2425
+ }
2426
+ },
2427
+ required: [
2428
+ "description",
2429
+ "typeName"
2430
+ ]
2431
+ },
2432
+ "AutoBeOpenApi.IPrerequisite": {
2433
+ description: "Prerequisite API operation dependency.\n\n`IPrerequisite` defines a dependency relationship between API operations,\nspecifying that certain endpoints must be successfully called before the\ncurrent operation can proceed. This ensures proper resource validation,\nstate checking, and data availability in complex API workflows.\n\n## CRITICAL WARNING: Authentication is NOT a Prerequisite\n\n**NEVER use prerequisites for authentication or authorization checks!**\n\nPrerequisites are ONLY for business logic dependencies such as:\n\n- Checking if a resource exists\n- Verifying resource state\n- Loading required data\n\nDo NOT create prerequisites for:\n\n- Login/authentication endpoints\n- Token validation\n- Permission checks\n- User authorization verification\n\nAuthentication is handled separately via the `authorizationActor` field on\nthe operation itself. Mixing authentication with business prerequisites\ncreates confusion and incorrect test scenarios.\n\n## Core Concept\n\nPrerequisites create an execution dependency graph for API operations. They\nexplicitly declare which APIs must succeed before attempting the current\noperation, preventing invalid states and ensuring data consistency.\n\n## Structure\n\nEach prerequisite consists of:\n\n1. **endpoint**: The API endpoint that must be called first\n2. **description**: Clear explanation of why this prerequisite is required\n\n## Common Use Cases\n\n### 1. Resource Existence Validation\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/users/{userId}\", \"method\": \"get\" },\n \"description\": \"User must exist before updating their profile\"\n}\n```\n\n### 2. Parent-Child Relationships\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/posts/{postId}\", \"method\": \"get\" },\n \"description\": \"Post must exist before adding comments\"\n}\n```\n\n### 3. State Prerequisites\n\n```typescript\n{\n \"endpoint\": { \"path\": \"/orders/{orderId}/status\", \"method\": \"get\" },\n \"description\": \"Order must be in 'confirmed' state before shipping\"\n}\n```\n\n### 4. Business Logic Dependencies\n\n```typescript\n{\n \"endpoint\": {\n \"path\": \"/inventory/{productId}/stock\",\n \"method\": \"get\"\n },\n \"description\": \"Product must have sufficient stock before creating order\"\n}\n```\n\n## Implementation Guidelines\n\n1. **Clear Descriptions**: Always explain WHY the prerequisite is needed\n2. **Minimal Dependencies**: Only include truly necessary prerequisites\n3. **Logical Order**: If multiple prerequisites exist, order them logically\n4. **Error Context**: Description should help understand failure scenarios\n5. **No Authentication**: Prerequisites must NEVER be authentication checks\n\n## Test Generation Usage\n\nThe Test Agent utilizes prerequisites to:\n\n- Set up test data in the correct sequence\n- Generate realistic test scenarios\n- Create both positive and negative test cases\n- Ensure proper cleanup in reverse dependency order\n\n## Best Practices\n\n- Keep prerequisite chains as short as possible for performance\n- Consider caching prerequisite results when safe to do so\n- Ensure prerequisite descriptions are specific, not generic\n- Validate that circular dependencies don't exist\n- Document any side effects of prerequisite calls\n- NEVER use for authentication/authorization validation",
2434
+ type: "object",
2435
+ properties: {
2436
+ endpoint: {
2437
+ description: "The API endpoint that must be called before the main operation.\n\nThis specifies the exact HTTP method and path of the prerequisite API.\nThe endpoint must be a valid operation defined elsewhere in the API\nspecification. Path parameters in the prerequisite endpoint can reference\nthe same parameters available in the main operation.",
2438
+ $ref: "#/$defs/AutoBeOpenApi.IEndpoint"
2439
+ },
2440
+ description: {
2441
+ description: "Clear description of why this prerequisite is required.\n\nThis description should explain:\n\n- What validation or check this prerequisite performs\n- What state or condition must be satisfied\n- What happens if this prerequisite fails\n- Any specific data from the prerequisite used by the main operation\n\nThe description helps developers understand the dependency relationship\nand aids in debugging when prerequisites fail.\n\nGuidelines for good descriptions:\n\n- Be specific about the requirement (e.g., \"must be in 'active' state\")\n- Explain business logic constraints (e.g., \"budget must not be exceeded\")\n- Explain data dependencies (e.g., \"provides pricing information needed\")\n- Keep it concise but complete\n\n> MUST be written in English. Never use other languages.",
2442
+ type: "string"
2443
+ }
2444
+ },
2445
+ required: [
2446
+ "endpoint",
2447
+ "description"
2448
+ ]
2449
+ },
2450
+ "AutoBeOpenApi.IEndpoint": {
2451
+ description: "API endpoint information.",
2452
+ type: "object",
2453
+ properties: {
2454
+ path: {
2455
+ 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)",
2456
+ type: "string",
2457
+ pattern: "^\\/[a-zA-Z0-9\\/_{}.-]*$"
2458
+ },
2459
+ method: {
2460
+ description: "HTTP method of the API operation.\n\n**IMPORTANT**: Methods must be written in lowercase only (e.g., \"get\",\nnot \"GET\").\n\nNote that, if the API operation has {@link requestBody}, method must not\nbe `get`.\n\nAlso, even though the API operation has been designed to only get\ninformation, but it needs complicated request information, it must be\ndefined as `patch` method with {@link requestBody} data specification.\n\n- `get`: get information\n- `patch`: get information with complicated request data\n ({@link requestBody})\n- `post`: create new record\n- `put`: update existing record\n- `delete`: remove record",
2461
+ type: "string",
2462
+ "enum": [
2463
+ "get",
2464
+ "post",
2465
+ "put",
2466
+ "delete",
2467
+ "patch"
2468
+ ]
2469
+ }
2470
+ },
2471
+ required: [
2472
+ "path",
2473
+ "method"
2474
+ ]
2475
+ }
2476
+ }
2477
+ },
2478
+ description: "Creates an authorization Operations for the given roles\n\nThis method generates an OpenAPI interface that defines the authorization\nrequirements for the given roles. It ensures that the interface reflects\nthe correct permissions and access levels for each role.",
2479
+ validate: (() => { const _iv4 = new Set(["date-time", "password", "regex", "uuid", "email", "hostname", "idn-email", "idn-hostname", "iri", "iri-reference", "ipv4", "ipv6", "uri", "uri-reference", "uri-template", "url", "date", "time", "duration", "json-pointer", "relative-json-pointer"]); const _vv8 = new Set(["date-time", "password", "regex", "uuid", "email", "hostname", "idn-email", "idn-hostname", "iri", "iri-reference", "ipv4", "ipv6", "uri", "uri-reference", "uri-template", "url", "date", "time", "duration", "json-pointer", "relative-json-pointer"]); const _io0 = input => Array.isArray(input.operations) && (1 <= input.operations.length && input.operations.every(elem => "object" === typeof elem && null !== elem && _io1(elem))); const _io1 = input => "string" === typeof input.specification && (null === input.authorizationType || "login" === input.authorizationType || "join" === input.authorizationType || "refresh" === input.authorizationType) && "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.authorizationActor || "string" === typeof input.authorizationActor && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationActor) && 1 <= input.authorizationActor.length)) && ("string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name)) && (Array.isArray(input.prerequisites) && input.prerequisites.every(elem => "object" === typeof elem && null !== elem && _io8(elem))) && ("string" === typeof input.path && RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path)) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _io2 = input => "string" === typeof input.name && RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) && "string" === typeof input.description && ("object" === typeof input.schema && null !== input.schema && _iu0(input.schema)); const _io3 = input => (undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000)) && (undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000)) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 && 0 < input.multipleOf)) && "integer" === input.type; const _io4 = input => (undefined === input.minimum || "number" === typeof input.minimum) && (undefined === input.maximum || "number" === typeof input.maximum) && (undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum) && (undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum) && (undefined === input.multipleOf || "number" === typeof input.multipleOf && 0 < input.multipleOf) && "number" === input.type; const _io5 = input => (undefined === input.format || true === _iv4.has(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 _io8 = input => "object" === typeof input.endpoint && null !== input.endpoint && _io9(input.endpoint) && "string" === typeof input.description; const _io9 = input => "string" === typeof input.path && RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) && ("get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method); const _iu0 = input => (() => {
2480
+ if ("number" === input.type)
2481
+ return _io4(input);
2482
+ else if ("integer" === input.type)
2483
+ return _io3(input);
2484
+ else if ("string" === input.type)
2485
+ return _io5(input);
2486
+ else
2487
+ return false;
2488
+ })(); const _vo0 = (input, _path, _exceptionable = true) => [(Array.isArray(input.operations) || _report(_exceptionable, {
2489
+ path: _path + ".operations",
2490
+ expected: "(Array<AutoBeOpenApi.IOperation> & MinItems<1>)",
2491
+ value: input.operations
2492
+ })) && ((1 <= input.operations.length || _report(_exceptionable, {
2493
+ path: _path + ".operations",
2494
+ expected: "Array<> & MinItems<1>",
2495
+ value: input.operations
2496
+ })) && input.operations.map((elem, _index5) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
2497
+ path: _path + ".operations[" + _index5 + "]",
2498
+ expected: "AutoBeOpenApi.IOperation",
2499
+ value: elem
2500
+ })) && _vo1(elem, _path + ".operations[" + _index5 + "]", true && _exceptionable) || _report(_exceptionable, {
2501
+ path: _path + ".operations[" + _index5 + "]",
2502
+ expected: "AutoBeOpenApi.IOperation",
2503
+ value: elem
2504
+ })).every(flag => flag)) || _report(_exceptionable, {
2505
+ path: _path + ".operations",
2506
+ expected: "(Array<AutoBeOpenApi.IOperation> & MinItems<1>)",
2507
+ value: input.operations
2508
+ })].every(flag => flag); const _vo1 = (input, _path, _exceptionable = true) => ["string" === typeof input.specification || _report(_exceptionable, {
2509
+ path: _path + ".specification",
2510
+ expected: "string",
2511
+ value: input.specification
2512
+ }), null === input.authorizationType || "login" === input.authorizationType || "join" === input.authorizationType || "refresh" === input.authorizationType || _report(_exceptionable, {
2513
+ path: _path + ".authorizationType",
2514
+ expected: "(\"join\" | \"login\" | \"refresh\" | null)",
2515
+ value: input.authorizationType
2516
+ }), "string" === typeof input.description || _report(_exceptionable, {
2517
+ path: _path + ".description",
2518
+ expected: "string",
2519
+ value: input.description
2520
+ }), "string" === typeof input.summary || _report(_exceptionable, {
2521
+ path: _path + ".summary",
2522
+ expected: "string",
2523
+ value: input.summary
2524
+ }), (Array.isArray(input.parameters) || _report(_exceptionable, {
2525
+ path: _path + ".parameters",
2526
+ expected: "Array<AutoBeOpenApi.IParameter>",
2527
+ value: input.parameters
2528
+ })) && input.parameters.map((elem, _index6) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
2529
+ path: _path + ".parameters[" + _index6 + "]",
2530
+ expected: "AutoBeOpenApi.IParameter",
2531
+ value: elem
2532
+ })) && _vo2(elem, _path + ".parameters[" + _index6 + "]", true && _exceptionable) || _report(_exceptionable, {
2533
+ path: _path + ".parameters[" + _index6 + "]",
2534
+ expected: "AutoBeOpenApi.IParameter",
2535
+ value: elem
2536
+ })).every(flag => flag) || _report(_exceptionable, {
2537
+ path: _path + ".parameters",
2538
+ expected: "Array<AutoBeOpenApi.IParameter>",
2539
+ value: input.parameters
2540
+ }), null === input.requestBody || ("object" === typeof input.requestBody && null !== input.requestBody || _report(_exceptionable, {
2541
+ path: _path + ".requestBody",
2542
+ expected: "(AutoBeOpenApi.IRequestBody | null)",
2543
+ value: input.requestBody
2544
+ })) && _vo6(input.requestBody, _path + ".requestBody", true && _exceptionable) || _report(_exceptionable, {
2545
+ path: _path + ".requestBody",
2546
+ expected: "(AutoBeOpenApi.IRequestBody | null)",
2547
+ value: input.requestBody
2548
+ }), null === input.responseBody || ("object" === typeof input.responseBody && null !== input.responseBody || _report(_exceptionable, {
2549
+ path: _path + ".responseBody",
2550
+ expected: "(AutoBeOpenApi.IResponseBody | null)",
2551
+ value: input.responseBody
2552
+ })) && _vo7(input.responseBody, _path + ".responseBody", true && _exceptionable) || _report(_exceptionable, {
2553
+ path: _path + ".responseBody",
2554
+ expected: "(AutoBeOpenApi.IResponseBody | null)",
2555
+ value: input.responseBody
2556
+ }), null === input.authorizationActor || "string" === typeof input.authorizationActor && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.authorizationActor) || _report(_exceptionable, {
2557
+ path: _path + ".authorizationActor",
2558
+ expected: "string & CamelCasePattern",
2559
+ value: input.authorizationActor
2560
+ })) && (1 <= input.authorizationActor.length || _report(_exceptionable, {
2561
+ path: _path + ".authorizationActor",
2562
+ expected: "string & MinLength<1>",
2563
+ value: input.authorizationActor
2564
+ })) || _report(_exceptionable, {
2565
+ path: _path + ".authorizationActor",
2566
+ expected: "((string & CamelCasePattern & MinLength<1>) | null)",
2567
+ value: input.authorizationActor
2568
+ }), "string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
2569
+ path: _path + ".name",
2570
+ expected: "string & CamelCasePattern",
2571
+ value: input.name
2572
+ })) || _report(_exceptionable, {
2573
+ path: _path + ".name",
2574
+ expected: "(string & CamelCasePattern)",
2575
+ value: input.name
2576
+ }), (Array.isArray(input.prerequisites) || _report(_exceptionable, {
2577
+ path: _path + ".prerequisites",
2578
+ expected: "Array<AutoBeOpenApi.IPrerequisite>",
2579
+ value: input.prerequisites
2580
+ })) && input.prerequisites.map((elem, _index7) => ("object" === typeof elem && null !== elem || _report(_exceptionable, {
2581
+ path: _path + ".prerequisites[" + _index7 + "]",
2582
+ expected: "AutoBeOpenApi.IPrerequisite",
2583
+ value: elem
2584
+ })) && _vo8(elem, _path + ".prerequisites[" + _index7 + "]", true && _exceptionable) || _report(_exceptionable, {
2585
+ path: _path + ".prerequisites[" + _index7 + "]",
2586
+ expected: "AutoBeOpenApi.IPrerequisite",
2587
+ value: elem
2588
+ })).every(flag => flag) || _report(_exceptionable, {
2589
+ path: _path + ".prerequisites",
2590
+ expected: "Array<AutoBeOpenApi.IPrerequisite>",
2591
+ value: input.prerequisites
2592
+ }), "string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
2593
+ path: _path + ".path",
2594
+ expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
2595
+ value: input.path
2596
+ })) || _report(_exceptionable, {
2597
+ path: _path + ".path",
2598
+ expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
2599
+ value: input.path
2600
+ }), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
2601
+ path: _path + ".method",
2602
+ expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
2603
+ value: input.method
2604
+ })].every(flag => flag); const _vo2 = (input, _path, _exceptionable = true) => ["string" === typeof input.name && (RegExp("^[a-z][a-zA-Z0-9]*$").test(input.name) || _report(_exceptionable, {
2605
+ path: _path + ".name",
2606
+ expected: "string & CamelCasePattern",
2607
+ value: input.name
2608
+ })) || _report(_exceptionable, {
2609
+ path: _path + ".name",
2610
+ expected: "(string & CamelCasePattern)",
2611
+ value: input.name
2612
+ }), "string" === typeof input.description || _report(_exceptionable, {
2613
+ path: _path + ".description",
2614
+ expected: "string",
2615
+ value: input.description
2616
+ }), ("object" === typeof input.schema && null !== input.schema || _report(_exceptionable, {
2617
+ path: _path + ".schema",
2618
+ expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
2619
+ value: input.schema
2620
+ })) && _vu0(input.schema, _path + ".schema", true && _exceptionable) || _report(_exceptionable, {
2621
+ path: _path + ".schema",
2622
+ expected: "(AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IString)",
2623
+ value: input.schema
2624
+ })].every(flag => flag); const _vo3 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum && (Math.floor(input.minimum) === input.minimum && -9223372036854776000 <= input.minimum && input.minimum <= 9223372036854776000 || _report(_exceptionable, {
2625
+ path: _path + ".minimum",
2626
+ expected: "number & Type<\"int64\">",
2627
+ value: input.minimum
2628
+ })) || _report(_exceptionable, {
2629
+ path: _path + ".minimum",
2630
+ expected: "((number & Type<\"int64\">) | undefined)",
2631
+ value: input.minimum
2632
+ }), undefined === input.maximum || "number" === typeof input.maximum && (Math.floor(input.maximum) === input.maximum && -9223372036854776000 <= input.maximum && input.maximum <= 9223372036854776000 || _report(_exceptionable, {
2633
+ path: _path + ".maximum",
2634
+ expected: "number & Type<\"int64\">",
2635
+ value: input.maximum
2636
+ })) || _report(_exceptionable, {
2637
+ path: _path + ".maximum",
2638
+ expected: "((number & Type<\"int64\">) | undefined)",
2639
+ value: input.maximum
2640
+ }), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
2641
+ path: _path + ".exclusiveMinimum",
2642
+ expected: "(number | undefined)",
2643
+ value: input.exclusiveMinimum
2644
+ }), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
2645
+ path: _path + ".exclusiveMaximum",
2646
+ expected: "(number | undefined)",
2647
+ value: input.exclusiveMaximum
2648
+ }), undefined === input.multipleOf || "number" === typeof input.multipleOf && (Math.floor(input.multipleOf) === input.multipleOf && 0 <= input.multipleOf && input.multipleOf <= 18446744073709552000 || _report(_exceptionable, {
2649
+ path: _path + ".multipleOf",
2650
+ expected: "number & Type<\"uint64\">",
2651
+ value: input.multipleOf
2652
+ })) && (0 < input.multipleOf || _report(_exceptionable, {
2653
+ path: _path + ".multipleOf",
2654
+ expected: "number & ExclusiveMinimum<0>",
2655
+ value: input.multipleOf
2656
+ })) || _report(_exceptionable, {
2657
+ path: _path + ".multipleOf",
2658
+ expected: "((number & Type<\"uint64\"> & ExclusiveMinimum<0>) | undefined)",
2659
+ value: input.multipleOf
2660
+ }), "integer" === input.type || _report(_exceptionable, {
2661
+ path: _path + ".type",
2662
+ expected: "\"integer\"",
2663
+ value: input.type
2664
+ })].every(flag => flag); const _vo4 = (input, _path, _exceptionable = true) => [undefined === input.minimum || "number" === typeof input.minimum || _report(_exceptionable, {
2665
+ path: _path + ".minimum",
2666
+ expected: "(number | undefined)",
2667
+ value: input.minimum
2668
+ }), undefined === input.maximum || "number" === typeof input.maximum || _report(_exceptionable, {
2669
+ path: _path + ".maximum",
2670
+ expected: "(number | undefined)",
2671
+ value: input.maximum
2672
+ }), undefined === input.exclusiveMinimum || "number" === typeof input.exclusiveMinimum || _report(_exceptionable, {
2673
+ path: _path + ".exclusiveMinimum",
2674
+ expected: "(number | undefined)",
2675
+ value: input.exclusiveMinimum
2676
+ }), undefined === input.exclusiveMaximum || "number" === typeof input.exclusiveMaximum || _report(_exceptionable, {
2677
+ path: _path + ".exclusiveMaximum",
2678
+ expected: "(number | undefined)",
2679
+ value: input.exclusiveMaximum
2680
+ }), undefined === input.multipleOf || "number" === typeof input.multipleOf && (0 < input.multipleOf || _report(_exceptionable, {
2681
+ path: _path + ".multipleOf",
2682
+ expected: "number & ExclusiveMinimum<0>",
2683
+ value: input.multipleOf
2684
+ })) || _report(_exceptionable, {
2685
+ path: _path + ".multipleOf",
2686
+ expected: "((number & ExclusiveMinimum<0>) | undefined)",
2687
+ value: input.multipleOf
2688
+ }), "number" === input.type || _report(_exceptionable, {
2689
+ path: _path + ".type",
2690
+ expected: "\"number\"",
2691
+ value: input.type
2692
+ })].every(flag => flag); const _vo5 = (input, _path, _exceptionable = true) => [undefined === input.format || true === _vv8.has(input.format) || _report(_exceptionable, {
2693
+ path: _path + ".format",
2694
+ expected: "(\"date\" | \"date-time\" | \"duration\" | \"email\" | \"hostname\" | \"idn-email\" | \"idn-hostname\" | \"ipv4\" | \"ipv6\" | \"iri\" | \"iri-reference\" | \"json-pointer\" | \"password\" | \"regex\" | \"relative-json-pointer\" | \"time\" | \"uri\" | \"uri-reference\" | \"uri-template\" | \"url\" | \"uuid\" | undefined)",
2695
+ value: input.format
2696
+ }), undefined === input.pattern || "string" === typeof input.pattern || _report(_exceptionable, {
2697
+ path: _path + ".pattern",
2698
+ expected: "(string | undefined)",
2699
+ value: input.pattern
2700
+ }), undefined === input.contentMediaType || "string" === typeof input.contentMediaType || _report(_exceptionable, {
2701
+ path: _path + ".contentMediaType",
2702
+ expected: "(string | undefined)",
2703
+ value: input.contentMediaType
2704
+ }), undefined === input.minLength || "number" === typeof input.minLength && (Math.floor(input.minLength) === input.minLength && 0 <= input.minLength && input.minLength <= 18446744073709552000 || _report(_exceptionable, {
2705
+ path: _path + ".minLength",
2706
+ expected: "number & Type<\"uint64\">",
2707
+ value: input.minLength
2708
+ })) || _report(_exceptionable, {
2709
+ path: _path + ".minLength",
2710
+ expected: "((number & Type<\"uint64\">) | undefined)",
2711
+ value: input.minLength
2712
+ }), undefined === input.maxLength || "number" === typeof input.maxLength && (Math.floor(input.maxLength) === input.maxLength && 0 <= input.maxLength && input.maxLength <= 18446744073709552000 || _report(_exceptionable, {
2713
+ path: _path + ".maxLength",
2714
+ expected: "number & Type<\"uint64\">",
2715
+ value: input.maxLength
2716
+ })) || _report(_exceptionable, {
2717
+ path: _path + ".maxLength",
2718
+ expected: "((number & Type<\"uint64\">) | undefined)",
2719
+ value: input.maxLength
2720
+ }), "string" === input.type || _report(_exceptionable, {
2721
+ path: _path + ".type",
2722
+ expected: "\"string\"",
2723
+ value: input.type
2724
+ })].every(flag => flag); const _vo6 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
2725
+ path: _path + ".description",
2726
+ expected: "string",
2727
+ value: input.description
2728
+ }), "string" === typeof input.typeName || _report(_exceptionable, {
2729
+ path: _path + ".typeName",
2730
+ expected: "string",
2731
+ value: input.typeName
2732
+ })].every(flag => flag); const _vo7 = (input, _path, _exceptionable = true) => ["string" === typeof input.description || _report(_exceptionable, {
2733
+ path: _path + ".description",
2734
+ expected: "string",
2735
+ value: input.description
2736
+ }), "string" === typeof input.typeName || _report(_exceptionable, {
2737
+ path: _path + ".typeName",
2738
+ expected: "string",
2739
+ value: input.typeName
2740
+ })].every(flag => flag); const _vo8 = (input, _path, _exceptionable = true) => [("object" === typeof input.endpoint && null !== input.endpoint || _report(_exceptionable, {
2741
+ path: _path + ".endpoint",
2742
+ expected: "AutoBeOpenApi.IEndpoint",
2743
+ value: input.endpoint
2744
+ })) && _vo9(input.endpoint, _path + ".endpoint", true && _exceptionable) || _report(_exceptionable, {
2745
+ path: _path + ".endpoint",
2746
+ expected: "AutoBeOpenApi.IEndpoint",
2747
+ value: input.endpoint
2748
+ }), "string" === typeof input.description || _report(_exceptionable, {
2749
+ path: _path + ".description",
2750
+ expected: "string",
2751
+ value: input.description
2752
+ })].every(flag => flag); const _vo9 = (input, _path, _exceptionable = true) => ["string" === typeof input.path && (RegExp("^\\/[a-zA-Z0-9\\/_{}.-]*$").test(input.path) || _report(_exceptionable, {
2753
+ path: _path + ".path",
2754
+ expected: "string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">",
2755
+ value: input.path
2756
+ })) || _report(_exceptionable, {
2757
+ path: _path + ".path",
2758
+ expected: "(string & Pattern<\"^\\\\/[a-zA-Z0-9\\\\/_{}.-]*$\">)",
2759
+ value: input.path
2760
+ }), "get" === input.method || "post" === input.method || "put" === input.method || "delete" === input.method || "patch" === input.method || _report(_exceptionable, {
2761
+ path: _path + ".method",
2762
+ expected: "(\"delete\" | \"get\" | \"patch\" | \"post\" | \"put\")",
2763
+ value: input.method
2764
+ })].every(flag => flag); const _vu0 = (input, _path, _exceptionable = true) => (() => {
2765
+ if ("number" === input.type)
2766
+ return _vo4(input, _path, true && _exceptionable);
2767
+ else if ("integer" === input.type)
2768
+ return _vo3(input, _path, true && _exceptionable);
2769
+ else if ("string" === input.type)
2770
+ return _vo5(input, _path, true && _exceptionable);
2771
+ else
2772
+ return _report(_exceptionable, {
2773
+ path: _path,
2774
+ expected: "(AutoBeOpenApi.IJsonSchema.INumber | AutoBeOpenApi.IJsonSchema.IInteger | AutoBeOpenApi.IJsonSchema.IString)",
2775
+ value: input
2776
+ });
2777
+ })(); const __is = input => "object" === typeof input && null !== input && _io0(input); let errors; let _report; return input => {
2778
+ if (false === __is(input)) {
2779
+ errors = [];
2780
+ _report = __typia_transform__validateReport._validateReport(errors);
2781
+ ((input, _path, _exceptionable = true) => ("object" === typeof input && null !== input || _report(true, {
2782
+ path: _path + "",
2783
+ expected: "IAutoBeInterfaceAuthorizationsApplication.IProps",
2784
+ value: input
2785
+ })) && _vo0(input, _path + "", true) || _report(true, {
2786
+ path: _path + "",
2787
+ expected: "IAutoBeInterfaceAuthorizationsApplication.IProps",
2788
+ value: input
2789
+ }))(input, "$input", true);
2790
+ const success = 0 === errors.length;
2791
+ return success ? {
2792
+ success,
2793
+ data: input
2794
+ } : {
2795
+ success,
2796
+ errors,
2797
+ data: input
2798
+ };
2799
+ }
2800
+ return {
2801
+ success: true,
2802
+ data: input
2803
+ };
2804
+ }; })()
2805
+ }
2806
+ ]
2807
+ };
2808
+ __typia_transform__llmApplicationFinalize._llmApplicationFinalize(application, Object.assign(Object.assign({}, {
2809
+ validate: {
2810
+ makeOperations: validate,
2811
+ },
2812
+ }), { equals: false }));
2813
+ return application;
2814
+ })(),
2068
2815
  };
2069
2816
  //# sourceMappingURL=orchestrateInterfaceAuthorizations.js.map