@mcp-abap-adt/core 2.5.0 → 2.5.2

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 (400) hide show
  1. package/CHANGELOG.md +49 -0
  2. package/README.md +3 -0
  3. package/dist/handlers/bdef/handleCreateBehaviorDefinition.d.ts +50 -0
  4. package/dist/handlers/bdef/handleCreateBehaviorDefinition.d.ts.map +1 -0
  5. package/dist/handlers/bdef/handleCreateBehaviorDefinition.js +101 -0
  6. package/dist/handlers/bdef/handleGetBdef.d.ts +54 -0
  7. package/dist/handlers/bdef/handleGetBdef.d.ts.map +1 -0
  8. package/dist/handlers/bdef/handleGetBdef.js +89 -0
  9. package/dist/handlers/bdef/handleUpdateBehaviorDefinition.d.ts +37 -0
  10. package/dist/handlers/bdef/handleUpdateBehaviorDefinition.d.ts.map +1 -0
  11. package/dist/handlers/bdef/handleUpdateBehaviorDefinition.js +85 -0
  12. package/dist/handlers/behavior_definition/readonly/handleGetBdef.d.ts +54 -0
  13. package/dist/handlers/behavior_definition/readonly/handleGetBdef.d.ts.map +1 -0
  14. package/dist/handlers/behavior_definition/readonly/handleGetBdef.js +89 -0
  15. package/dist/handlers/class/handleCheckClass.d.ts +59 -0
  16. package/dist/handlers/class/handleCheckClass.d.ts.map +1 -0
  17. package/dist/handlers/class/handleCheckClass.js +138 -0
  18. package/dist/handlers/class/handleCreateClass.d.ts +80 -0
  19. package/dist/handlers/class/handleCreateClass.d.ts.map +1 -0
  20. package/dist/handlers/class/handleCreateClass.js +192 -0
  21. package/dist/handlers/class/handleGetClass.d.ts +16 -0
  22. package/dist/handlers/class/handleGetClass.d.ts.map +1 -0
  23. package/dist/handlers/class/handleGetClass.js +159 -0
  24. package/dist/handlers/class/handleUpdateClassSource.d.ts +44 -0
  25. package/dist/handlers/class/handleUpdateClassSource.d.ts.map +1 -0
  26. package/dist/handlers/class/handleUpdateClassSource.js +131 -0
  27. package/dist/handlers/class/handleValidateClass.d.ts +62 -0
  28. package/dist/handlers/class/handleValidateClass.d.ts.map +1 -0
  29. package/dist/handlers/class/handleValidateClass.js +136 -0
  30. package/dist/handlers/class/readonly/handleGetClass.d.ts +20 -0
  31. package/dist/handlers/class/readonly/handleGetClass.d.ts.map +1 -0
  32. package/dist/handlers/class/readonly/handleGetClass.js +159 -0
  33. package/dist/handlers/common/handleActivateObject.d.ts +62 -0
  34. package/dist/handlers/common/handleActivateObject.d.ts.map +1 -0
  35. package/dist/handlers/common/handleActivateObject.js +137 -0
  36. package/dist/handlers/common/handleCheckObject.d.ts +63 -0
  37. package/dist/handlers/common/handleCheckObject.d.ts.map +1 -0
  38. package/dist/handlers/common/handleCheckObject.js +197 -0
  39. package/dist/handlers/common/handleDeleteObject.d.ts +46 -0
  40. package/dist/handlers/common/handleDeleteObject.d.ts.map +1 -0
  41. package/dist/handlers/common/handleDeleteObject.js +176 -0
  42. package/dist/handlers/common/handleLockObject.d.ts +57 -0
  43. package/dist/handlers/common/handleLockObject.d.ts.map +1 -0
  44. package/dist/handlers/common/handleLockObject.js +195 -0
  45. package/dist/handlers/common/handleUnlockObject.d.ts +61 -0
  46. package/dist/handlers/common/handleUnlockObject.d.ts.map +1 -0
  47. package/dist/handlers/common/handleUnlockObject.js +178 -0
  48. package/dist/handlers/common/handleValidateObject.d.ts +58 -0
  49. package/dist/handlers/common/handleValidateObject.d.ts.map +1 -0
  50. package/dist/handlers/common/handleValidateObject.js +177 -0
  51. package/dist/handlers/compact/high/compactSchemas.d.ts +218 -9
  52. package/dist/handlers/compact/high/compactSchemas.d.ts.map +1 -1
  53. package/dist/handlers/compact/high/compactSchemas.js +410 -134
  54. package/dist/handlers/compact/high/compactSchemas.js.map +1 -1
  55. package/dist/handlers/compact/high/handleHandlerActivate.d.ts +7 -1
  56. package/dist/handlers/compact/high/handleHandlerActivate.d.ts.map +1 -1
  57. package/dist/handlers/compact/high/handleHandlerActivate.js +1 -1
  58. package/dist/handlers/compact/high/handleHandlerActivate.js.map +1 -1
  59. package/dist/handlers/compact/high/handleHandlerCdsUnitTestResult.d.ts +4 -1
  60. package/dist/handlers/compact/high/handleHandlerCdsUnitTestResult.d.ts.map +1 -1
  61. package/dist/handlers/compact/high/handleHandlerCdsUnitTestResult.js +1 -1
  62. package/dist/handlers/compact/high/handleHandlerCdsUnitTestResult.js.map +1 -1
  63. package/dist/handlers/compact/high/handleHandlerCdsUnitTestStatus.d.ts +3 -1
  64. package/dist/handlers/compact/high/handleHandlerCdsUnitTestStatus.d.ts.map +1 -1
  65. package/dist/handlers/compact/high/handleHandlerCdsUnitTestStatus.js +1 -1
  66. package/dist/handlers/compact/high/handleHandlerCdsUnitTestStatus.js.map +1 -1
  67. package/dist/handlers/compact/high/handleHandlerCheckRun.d.ts +7 -1
  68. package/dist/handlers/compact/high/handleHandlerCheckRun.d.ts.map +1 -1
  69. package/dist/handlers/compact/high/handleHandlerCheckRun.js +1 -1
  70. package/dist/handlers/compact/high/handleHandlerCheckRun.js.map +1 -1
  71. package/dist/handlers/compact/high/handleHandlerCreate.d.ts +23 -1
  72. package/dist/handlers/compact/high/handleHandlerCreate.d.ts.map +1 -1
  73. package/dist/handlers/compact/high/handleHandlerCreate.js +1 -1
  74. package/dist/handlers/compact/high/handleHandlerCreate.js.map +1 -1
  75. package/dist/handlers/compact/high/handleHandlerDelete.d.ts +7 -1
  76. package/dist/handlers/compact/high/handleHandlerDelete.d.ts.map +1 -1
  77. package/dist/handlers/compact/high/handleHandlerDelete.js +1 -1
  78. package/dist/handlers/compact/high/handleHandlerDelete.js.map +1 -1
  79. package/dist/handlers/compact/high/handleHandlerDumpList.d.ts +6 -1
  80. package/dist/handlers/compact/high/handleHandlerDumpList.d.ts.map +1 -1
  81. package/dist/handlers/compact/high/handleHandlerDumpList.js +1 -1
  82. package/dist/handlers/compact/high/handleHandlerDumpList.js.map +1 -1
  83. package/dist/handlers/compact/high/handleHandlerDumpView.d.ts +3 -1
  84. package/dist/handlers/compact/high/handleHandlerDumpView.d.ts.map +1 -1
  85. package/dist/handlers/compact/high/handleHandlerDumpView.js +1 -1
  86. package/dist/handlers/compact/high/handleHandlerDumpView.js.map +1 -1
  87. package/dist/handlers/compact/high/handleHandlerGet.d.ts +60 -1
  88. package/dist/handlers/compact/high/handleHandlerGet.d.ts.map +1 -1
  89. package/dist/handlers/compact/high/handleHandlerGet.js +1 -1
  90. package/dist/handlers/compact/high/handleHandlerGet.js.map +1 -1
  91. package/dist/handlers/compact/high/handleHandlerLock.d.ts +7 -1
  92. package/dist/handlers/compact/high/handleHandlerLock.d.ts.map +1 -1
  93. package/dist/handlers/compact/high/handleHandlerLock.js +1 -1
  94. package/dist/handlers/compact/high/handleHandlerLock.js.map +1 -1
  95. package/dist/handlers/compact/high/handleHandlerProfileList.d.ts +1 -1
  96. package/dist/handlers/compact/high/handleHandlerProfileList.js +1 -1
  97. package/dist/handlers/compact/high/handleHandlerProfileList.js.map +1 -1
  98. package/dist/handlers/compact/high/handleHandlerProfileRun.d.ts +17 -1
  99. package/dist/handlers/compact/high/handleHandlerProfileRun.d.ts.map +1 -1
  100. package/dist/handlers/compact/high/handleHandlerProfileRun.js +1 -1
  101. package/dist/handlers/compact/high/handleHandlerProfileRun.js.map +1 -1
  102. package/dist/handlers/compact/high/handleHandlerProfileView.d.ts +7 -1
  103. package/dist/handlers/compact/high/handleHandlerProfileView.d.ts.map +1 -1
  104. package/dist/handlers/compact/high/handleHandlerProfileView.js +1 -1
  105. package/dist/handlers/compact/high/handleHandlerProfileView.js.map +1 -1
  106. package/dist/handlers/compact/high/handleHandlerServiceBindingListTypes.d.ts +2 -1
  107. package/dist/handlers/compact/high/handleHandlerServiceBindingListTypes.d.ts.map +1 -1
  108. package/dist/handlers/compact/high/handleHandlerServiceBindingListTypes.js +1 -1
  109. package/dist/handlers/compact/high/handleHandlerServiceBindingListTypes.js.map +1 -1
  110. package/dist/handlers/compact/high/handleHandlerServiceBindingValidate.d.ts +6 -1
  111. package/dist/handlers/compact/high/handleHandlerServiceBindingValidate.d.ts.map +1 -1
  112. package/dist/handlers/compact/high/handleHandlerServiceBindingValidate.js +1 -1
  113. package/dist/handlers/compact/high/handleHandlerServiceBindingValidate.js.map +1 -1
  114. package/dist/handlers/compact/high/handleHandlerTransportCreate.d.ts +5 -1
  115. package/dist/handlers/compact/high/handleHandlerTransportCreate.d.ts.map +1 -1
  116. package/dist/handlers/compact/high/handleHandlerTransportCreate.js +1 -1
  117. package/dist/handlers/compact/high/handleHandlerTransportCreate.js.map +1 -1
  118. package/dist/handlers/compact/high/handleHandlerUnitTestResult.d.ts +4 -1
  119. package/dist/handlers/compact/high/handleHandlerUnitTestResult.d.ts.map +1 -1
  120. package/dist/handlers/compact/high/handleHandlerUnitTestResult.js +1 -1
  121. package/dist/handlers/compact/high/handleHandlerUnitTestResult.js.map +1 -1
  122. package/dist/handlers/compact/high/handleHandlerUnitTestRun.d.ts +18 -1
  123. package/dist/handlers/compact/high/handleHandlerUnitTestRun.d.ts.map +1 -1
  124. package/dist/handlers/compact/high/handleHandlerUnitTestRun.js +1 -1
  125. package/dist/handlers/compact/high/handleHandlerUnitTestRun.js.map +1 -1
  126. package/dist/handlers/compact/high/handleHandlerUnitTestStatus.d.ts +3 -1
  127. package/dist/handlers/compact/high/handleHandlerUnitTestStatus.d.ts.map +1 -1
  128. package/dist/handlers/compact/high/handleHandlerUnitTestStatus.js +1 -1
  129. package/dist/handlers/compact/high/handleHandlerUnitTestStatus.js.map +1 -1
  130. package/dist/handlers/compact/high/handleHandlerUnlock.d.ts +7 -1
  131. package/dist/handlers/compact/high/handleHandlerUnlock.d.ts.map +1 -1
  132. package/dist/handlers/compact/high/handleHandlerUnlock.js +1 -1
  133. package/dist/handlers/compact/high/handleHandlerUnlock.js.map +1 -1
  134. package/dist/handlers/compact/high/handleHandlerUpdate.d.ts +21 -1
  135. package/dist/handlers/compact/high/handleHandlerUpdate.d.ts.map +1 -1
  136. package/dist/handlers/compact/high/handleHandlerUpdate.js +1 -1
  137. package/dist/handlers/compact/high/handleHandlerUpdate.js.map +1 -1
  138. package/dist/handlers/compact/high/handleHandlerValidate.d.ts +22 -10
  139. package/dist/handlers/compact/high/handleHandlerValidate.d.ts.map +1 -1
  140. package/dist/handlers/compact/high/handleHandlerValidate.js +1 -1
  141. package/dist/handlers/compact/high/handleHandlerValidate.js.map +1 -1
  142. package/dist/handlers/data_element/handleCreateDataElement.d.ts +83 -0
  143. package/dist/handlers/data_element/handleCreateDataElement.d.ts.map +1 -0
  144. package/dist/handlers/data_element/handleCreateDataElement.js +180 -0
  145. package/dist/handlers/data_element/handleGetDataElement.d.ts +29 -0
  146. package/dist/handlers/data_element/handleGetDataElement.d.ts.map +1 -0
  147. package/dist/handlers/data_element/handleGetDataElement.js +173 -0
  148. package/dist/handlers/data_element/handleUpdateDataElement.d.ts +131 -0
  149. package/dist/handlers/data_element/handleUpdateDataElement.d.ts.map +1 -0
  150. package/dist/handlers/data_element/handleUpdateDataElement.js +258 -0
  151. package/dist/handlers/data_element/readonly/handleGetDataElement.d.ts +33 -0
  152. package/dist/handlers/data_element/readonly/handleGetDataElement.d.ts.map +1 -0
  153. package/dist/handlers/data_element/readonly/handleGetDataElement.js +173 -0
  154. package/dist/handlers/ddlx/handleCreateMetadataExtension.d.ts +41 -0
  155. package/dist/handlers/ddlx/handleCreateMetadataExtension.d.ts.map +1 -0
  156. package/dist/handlers/ddlx/handleCreateMetadataExtension.js +92 -0
  157. package/dist/handlers/ddlx/handleUpdateMetadataExtension.d.ts +37 -0
  158. package/dist/handlers/ddlx/handleUpdateMetadataExtension.d.ts.map +1 -0
  159. package/dist/handlers/ddlx/handleUpdateMetadataExtension.js +81 -0
  160. package/dist/handlers/domain/handleCreateDomain.d.ts +104 -0
  161. package/dist/handlers/domain/handleCreateDomain.d.ts.map +1 -0
  162. package/dist/handlers/domain/handleCreateDomain.js +187 -0
  163. package/dist/handlers/domain/handleGetDomain.d.ts +19 -0
  164. package/dist/handlers/domain/handleGetDomain.d.ts.map +1 -0
  165. package/dist/handlers/domain/handleGetDomain.js +138 -0
  166. package/dist/handlers/domain/handleUpdateDomain.d.ts +99 -0
  167. package/dist/handlers/domain/handleUpdateDomain.d.ts.map +1 -0
  168. package/dist/handlers/domain/handleUpdateDomain.js +204 -0
  169. package/dist/handlers/domain/readonly/handleGetDomain.d.ts +23 -0
  170. package/dist/handlers/domain/readonly/handleGetDomain.d.ts.map +1 -0
  171. package/dist/handlers/domain/readonly/handleGetDomain.js +138 -0
  172. package/dist/handlers/enhancement/handleGetEnhancementImpl.d.ts +69 -0
  173. package/dist/handlers/enhancement/handleGetEnhancementImpl.d.ts.map +1 -0
  174. package/dist/handlers/enhancement/handleGetEnhancementImpl.js +171 -0
  175. package/dist/handlers/enhancement/handleGetEnhancementSpot.d.ts +53 -0
  176. package/dist/handlers/enhancement/handleGetEnhancementSpot.d.ts.map +1 -0
  177. package/dist/handlers/enhancement/handleGetEnhancementSpot.js +153 -0
  178. package/dist/handlers/enhancement/handleGetEnhancements.d.ts +64 -0
  179. package/dist/handlers/enhancement/handleGetEnhancements.d.ts.map +1 -0
  180. package/dist/handlers/enhancement/handleGetEnhancements.js +599 -0
  181. package/dist/handlers/function/handleCheckFunctionModule.d.ts +59 -0
  182. package/dist/handlers/function/handleCheckFunctionModule.d.ts.map +1 -0
  183. package/dist/handlers/function/handleCheckFunctionModule.js +140 -0
  184. package/dist/handlers/function/handleCreateFunctionGroup.d.ts +52 -0
  185. package/dist/handlers/function/handleCreateFunctionGroup.d.ts.map +1 -0
  186. package/dist/handlers/function/handleCreateFunctionGroup.js +114 -0
  187. package/dist/handlers/function/handleCreateFunctionModule.d.ts +57 -0
  188. package/dist/handlers/function/handleCreateFunctionModule.d.ts.map +1 -0
  189. package/dist/handlers/function/handleCreateFunctionModule.js +137 -0
  190. package/dist/handlers/function/handleGetFunction.d.ts +17 -0
  191. package/dist/handlers/function/handleGetFunction.d.ts.map +1 -0
  192. package/dist/handlers/function/handleGetFunction.js +172 -0
  193. package/dist/handlers/function/handleGetFunctionGroup.d.ts +16 -0
  194. package/dist/handlers/function/handleGetFunctionGroup.d.ts.map +1 -0
  195. package/dist/handlers/function/handleGetFunctionGroup.js +132 -0
  196. package/dist/handlers/function/handleUpdateFunctionModuleSource.d.ts +54 -0
  197. package/dist/handlers/function/handleUpdateFunctionModuleSource.d.ts.map +1 -0
  198. package/dist/handlers/function/handleUpdateFunctionModuleSource.js +108 -0
  199. package/dist/handlers/function/handleValidateFunctionModule.d.ts +58 -0
  200. package/dist/handlers/function/handleValidateFunctionModule.d.ts.map +1 -0
  201. package/dist/handlers/function/handleValidateFunctionModule.js +132 -0
  202. package/dist/handlers/function/readonly/handleGetFunctionGroup.d.ts +16 -0
  203. package/dist/handlers/function/readonly/handleGetFunctionGroup.d.ts.map +1 -0
  204. package/dist/handlers/function/readonly/handleGetFunctionGroup.js +132 -0
  205. package/dist/handlers/include/handleGetInclude.d.ts +16 -0
  206. package/dist/handlers/include/handleGetInclude.d.ts.map +1 -0
  207. package/dist/handlers/include/handleGetInclude.js +81 -0
  208. package/dist/handlers/include/handleGetIncludesList.d.ts +36 -0
  209. package/dist/handlers/include/handleGetIncludesList.d.ts.map +1 -0
  210. package/dist/handlers/include/handleGetIncludesList.js +223 -0
  211. package/dist/handlers/interface/handleCreateInterface.d.ts +64 -0
  212. package/dist/handlers/interface/handleCreateInterface.d.ts.map +1 -0
  213. package/dist/handlers/interface/handleCreateInterface.js +175 -0
  214. package/dist/handlers/interface/handleGetInterface.d.ts +40 -0
  215. package/dist/handlers/interface/handleGetInterface.d.ts.map +1 -0
  216. package/dist/handlers/interface/handleGetInterface.js +134 -0
  217. package/dist/handlers/interface/handleUpdateInterfaceSource.d.ts +48 -0
  218. package/dist/handlers/interface/handleUpdateInterfaceSource.d.ts.map +1 -0
  219. package/dist/handlers/interface/handleUpdateInterfaceSource.js +127 -0
  220. package/dist/handlers/interface/readonly/handleGetInterface.d.ts +44 -0
  221. package/dist/handlers/interface/readonly/handleGetInterface.d.ts.map +1 -0
  222. package/dist/handlers/interface/readonly/handleGetInterface.js +134 -0
  223. package/dist/handlers/package/handleCreatePackage.d.ts +38 -0
  224. package/dist/handlers/package/handleCreatePackage.d.ts.map +1 -0
  225. package/dist/handlers/package/handleCreatePackage.js +127 -0
  226. package/dist/handlers/package/handleGetPackage.d.ts +16 -0
  227. package/dist/handlers/package/handleGetPackage.d.ts.map +1 -0
  228. package/dist/handlers/package/handleGetPackage.js +94 -0
  229. package/dist/handlers/package/readonly/handleGetPackage.d.ts +21 -0
  230. package/dist/handlers/package/readonly/handleGetPackage.d.ts.map +1 -0
  231. package/dist/handlers/package/readonly/handleGetPackage.js +94 -0
  232. package/dist/handlers/program/handleCreateProgram.d.ts +73 -0
  233. package/dist/handlers/program/handleCreateProgram.d.ts.map +1 -0
  234. package/dist/handlers/program/handleCreateProgram.js +220 -0
  235. package/dist/handlers/program/handleGetProgFullCode.d.ts +67 -0
  236. package/dist/handlers/program/handleGetProgFullCode.d.ts.map +1 -0
  237. package/dist/handlers/program/handleGetProgFullCode.js +249 -0
  238. package/dist/handlers/program/handleGetProgram.d.ts +16 -0
  239. package/dist/handlers/program/handleGetProgram.d.ts.map +1 -0
  240. package/dist/handlers/program/handleGetProgram.js +71 -0
  241. package/dist/handlers/program/handleUpdateProgramSource.d.ts +44 -0
  242. package/dist/handlers/program/handleUpdateProgramSource.d.ts.map +1 -0
  243. package/dist/handlers/program/handleUpdateProgramSource.js +121 -0
  244. package/dist/handlers/program/readonly/handleGetProgram.d.ts +20 -0
  245. package/dist/handlers/program/readonly/handleGetProgram.d.ts.map +1 -0
  246. package/dist/handlers/program/readonly/handleGetProgram.js +71 -0
  247. package/dist/handlers/search/handleGetObjectsByType.d.ts +42 -0
  248. package/dist/handlers/search/handleGetObjectsByType.d.ts.map +1 -0
  249. package/dist/handlers/search/handleGetObjectsByType.js +166 -0
  250. package/dist/handlers/search/handleGetObjectsList.d.ts +46 -0
  251. package/dist/handlers/search/handleGetObjectsList.d.ts.map +1 -0
  252. package/dist/handlers/search/handleGetObjectsList.js +145 -0
  253. package/dist/handlers/search/handleSearchObject.d.ts +28 -0
  254. package/dist/handlers/search/handleSearchObject.d.ts.map +1 -0
  255. package/dist/handlers/search/handleSearchObject.js +119 -0
  256. package/dist/handlers/service_definition/readonly/handleGetServiceDefinition.d.ts +17 -0
  257. package/dist/handlers/service_definition/readonly/handleGetServiceDefinition.d.ts.map +1 -0
  258. package/dist/handlers/service_definition/readonly/handleGetServiceDefinition.js +136 -0
  259. package/dist/handlers/structure/handleCreateStructure.d.ts +107 -0
  260. package/dist/handlers/structure/handleCreateStructure.d.ts.map +1 -0
  261. package/dist/handlers/structure/handleCreateStructure.js +184 -0
  262. package/dist/handlers/structure/handleGetStructure.d.ts +16 -0
  263. package/dist/handlers/structure/handleGetStructure.d.ts.map +1 -0
  264. package/dist/handlers/structure/handleGetStructure.js +139 -0
  265. package/dist/handlers/structure/readonly/handleGetStructure.d.ts +16 -0
  266. package/dist/handlers/structure/readonly/handleGetStructure.d.ts.map +1 -0
  267. package/dist/handlers/structure/readonly/handleGetStructure.js +139 -0
  268. package/dist/handlers/system/handleDescribeByList.d.ts +36 -0
  269. package/dist/handlers/system/handleDescribeByList.d.ts.map +1 -0
  270. package/dist/handlers/system/handleDescribeByList.js +121 -0
  271. package/dist/handlers/system/handleGetAbapAST.d.ts +26 -0
  272. package/dist/handlers/system/handleGetAbapAST.d.ts.map +1 -0
  273. package/dist/handlers/system/handleGetAbapAST.js +172 -0
  274. package/dist/handlers/system/handleGetAbapSemanticAnalysis.d.ts +26 -0
  275. package/dist/handlers/system/handleGetAbapSemanticAnalysis.d.ts.map +1 -0
  276. package/dist/handlers/system/handleGetAbapSemanticAnalysis.js +353 -0
  277. package/dist/handlers/system/handleGetAbapSystemSymbols.d.ts +26 -0
  278. package/dist/handlers/system/handleGetAbapSystemSymbols.d.ts.map +1 -0
  279. package/dist/handlers/system/handleGetAbapSystemSymbols.js +574 -0
  280. package/dist/handlers/system/handleGetAllTypes.d.ts +22 -0
  281. package/dist/handlers/system/handleGetAllTypes.d.ts.map +1 -0
  282. package/dist/handlers/system/handleGetAllTypes.js +102 -0
  283. package/dist/handlers/system/handleGetInactiveObjects.d.ts +20 -0
  284. package/dist/handlers/system/handleGetInactiveObjects.d.ts.map +1 -0
  285. package/dist/handlers/system/handleGetInactiveObjects.js +41 -0
  286. package/dist/handlers/system/handleGetObjectInfo.d.ts +41 -0
  287. package/dist/handlers/system/handleGetObjectInfo.d.ts.map +1 -0
  288. package/dist/handlers/system/handleGetObjectInfo.js +210 -0
  289. package/dist/handlers/system/handleGetObjectNodeFromCache.d.ts +40 -0
  290. package/dist/handlers/system/handleGetObjectNodeFromCache.d.ts.map +1 -0
  291. package/dist/handlers/system/handleGetObjectNodeFromCache.js +70 -0
  292. package/dist/handlers/system/handleGetObjectStructure.d.ts +26 -0
  293. package/dist/handlers/system/handleGetObjectStructure.d.ts.map +1 -0
  294. package/dist/handlers/system/handleGetObjectStructure.js +103 -0
  295. package/dist/handlers/system/handleGetSession.d.ts +33 -0
  296. package/dist/handlers/system/handleGetSession.d.ts.map +1 -0
  297. package/dist/handlers/system/handleGetSession.js +63 -0
  298. package/dist/handlers/system/handleGetSqlQuery.d.ts +49 -0
  299. package/dist/handlers/system/handleGetSqlQuery.d.ts.map +1 -0
  300. package/dist/handlers/system/handleGetSqlQuery.js +176 -0
  301. package/dist/handlers/system/handleGetTransaction.d.ts +42 -0
  302. package/dist/handlers/system/handleGetTransaction.d.ts.map +1 -0
  303. package/dist/handlers/system/handleGetTransaction.js +91 -0
  304. package/dist/handlers/system/handleGetTypeInfo.d.ts +69 -0
  305. package/dist/handlers/system/handleGetTypeInfo.d.ts.map +1 -0
  306. package/dist/handlers/system/handleGetTypeInfo.js +169 -0
  307. package/dist/handlers/system/handleGetWhereUsed.d.ts +69 -0
  308. package/dist/handlers/system/handleGetWhereUsed.d.ts.map +1 -0
  309. package/dist/handlers/system/handleGetWhereUsed.js +405 -0
  310. package/dist/handlers/table/handleCheckTable.d.ts +55 -0
  311. package/dist/handlers/table/handleCheckTable.d.ts.map +1 -0
  312. package/dist/handlers/table/handleCheckTable.js +138 -0
  313. package/dist/handlers/table/handleCreateTable.d.ts +42 -0
  314. package/dist/handlers/table/handleCreateTable.d.ts.map +1 -0
  315. package/dist/handlers/table/handleCreateTable.js +118 -0
  316. package/dist/handlers/table/handleGetTable.d.ts +16 -0
  317. package/dist/handlers/table/handleGetTable.d.ts.map +1 -0
  318. package/dist/handlers/table/handleGetTable.js +140 -0
  319. package/dist/handlers/table/handleGetTableContents.d.ts +56 -0
  320. package/dist/handlers/table/handleGetTableContents.d.ts.map +1 -0
  321. package/dist/handlers/table/handleGetTableContents.js +387 -0
  322. package/dist/handlers/table/handleValidateTable.d.ts +53 -0
  323. package/dist/handlers/table/handleValidateTable.d.ts.map +1 -0
  324. package/dist/handlers/table/handleValidateTable.js +125 -0
  325. package/dist/handlers/table/readonly/handleGetTable.d.ts +20 -0
  326. package/dist/handlers/table/readonly/handleGetTable.d.ts.map +1 -0
  327. package/dist/handlers/table/readonly/handleGetTable.js +140 -0
  328. package/dist/handlers/transport/handleCreateTransport.d.ts +50 -0
  329. package/dist/handlers/transport/handleCreateTransport.d.ts.map +1 -0
  330. package/dist/handlers/transport/handleCreateTransport.js +151 -0
  331. package/dist/handlers/transport/handleGetTransport.d.ts +44 -0
  332. package/dist/handlers/transport/handleGetTransport.d.ts.map +1 -0
  333. package/dist/handlers/transport/handleGetTransport.js +183 -0
  334. package/dist/handlers/view/handleCreateView.d.ts +52 -0
  335. package/dist/handlers/view/handleCreateView.d.ts.map +1 -0
  336. package/dist/handlers/view/handleCreateView.js +139 -0
  337. package/dist/handlers/view/handleGetView.d.ts +26 -0
  338. package/dist/handlers/view/handleGetView.d.ts.map +1 -0
  339. package/dist/handlers/view/handleGetView.js +349 -0
  340. package/dist/handlers/view/handleUpdateViewSource.d.ts +44 -0
  341. package/dist/handlers/view/handleUpdateViewSource.d.ts.map +1 -0
  342. package/dist/handlers/view/handleUpdateViewSource.js +136 -0
  343. package/dist/handlers/view/readonly/handleGetView.d.ts +26 -0
  344. package/dist/handlers/view/readonly/handleGetView.d.ts.map +1 -0
  345. package/dist/handlers/view/readonly/handleGetView.js +349 -0
  346. package/dist/index.d.ts +94 -0
  347. package/dist/index.d.ts.map +1 -0
  348. package/dist/index.js +2453 -0
  349. package/dist/lib/activationUtils.d.ts +59 -0
  350. package/dist/lib/activationUtils.d.ts.map +1 -0
  351. package/dist/lib/activationUtils.js +168 -0
  352. package/dist/lib/config/ArgumentsParser.d.ts +2 -0
  353. package/dist/lib/config/ArgumentsParser.d.ts.map +1 -1
  354. package/dist/lib/config/ArgumentsParser.js +11 -1
  355. package/dist/lib/config/ArgumentsParser.js.map +1 -1
  356. package/dist/lib/config/IServerConfig.d.ts +2 -0
  357. package/dist/lib/config/IServerConfig.d.ts.map +1 -1
  358. package/dist/lib/config/ServerConfigManager.d.ts.map +1 -1
  359. package/dist/lib/config/ServerConfigManager.js +3 -0
  360. package/dist/lib/config/ServerConfigManager.js.map +1 -1
  361. package/dist/lib/getFullCodeCache.d.ts +3 -0
  362. package/dist/lib/getFullCodeCache.d.ts.map +1 -0
  363. package/dist/lib/getFullCodeCache.js +56 -0
  364. package/dist/lib/toolsRegistry.d.ts +13 -0
  365. package/dist/lib/toolsRegistry.d.ts.map +1 -0
  366. package/dist/lib/toolsRegistry.js +410 -0
  367. package/dist/server/AuthBrokerConfig.d.ts.map +1 -1
  368. package/dist/server/AuthBrokerConfig.js +14 -9
  369. package/dist/server/AuthBrokerConfig.js.map +1 -1
  370. package/dist/server/BaseMcpServer.d.ts.map +1 -1
  371. package/dist/server/BaseMcpServer.js +6 -0
  372. package/dist/server/BaseMcpServer.js.map +1 -1
  373. package/dist/server/launcher.js +4 -4
  374. package/dist/server/launcher.js.map +1 -1
  375. package/dist/utils/lockStateManager.d.ts +64 -0
  376. package/dist/utils/lockStateManager.d.ts.map +1 -0
  377. package/dist/utils/lockStateManager.js +173 -0
  378. package/dist/utils/lockStateManager.js.map +1 -0
  379. package/docs/user-guide/AUTHENTICATION.md +7 -0
  380. package/docs/user-guide/AVAILABLE_TOOLS.md +189 -174
  381. package/docs/user-guide/AVAILABLE_TOOLS_COMPACT.md +189 -174
  382. package/docs/user-guide/AVAILABLE_TOOLS_HIGH.md +189 -174
  383. package/docs/user-guide/CLI_OPTIONS.md +14 -0
  384. package/package.json +2 -1
  385. package/dist/handlers/service_binding/high/handleListServiceBindings.d.ts +0 -44
  386. package/dist/handlers/service_binding/high/handleListServiceBindings.d.ts.map +0 -1
  387. package/dist/handlers/service_binding/high/handleListServiceBindings.js +0 -211
  388. package/dist/handlers/service_binding/high/handleListServiceBindings.js.map +0 -1
  389. package/dist/handlers/service_binding/high/serviceBindingXmlBuilder.d.ts +0 -11
  390. package/dist/handlers/service_binding/high/serviceBindingXmlBuilder.d.ts.map +0 -1
  391. package/dist/handlers/service_binding/high/serviceBindingXmlBuilder.js +0 -27
  392. package/dist/handlers/service_binding/high/serviceBindingXmlBuilder.js.map +0 -1
  393. package/dist/handlers/system/readonly/handleRuntimeGetDumpByUri.d.ts +0 -27
  394. package/dist/handlers/system/readonly/handleRuntimeGetDumpByUri.d.ts.map +0 -1
  395. package/dist/handlers/system/readonly/handleRuntimeGetDumpByUri.js +0 -47
  396. package/dist/handlers/system/readonly/handleRuntimeGetDumpByUri.js.map +0 -1
  397. package/dist/handlers/system/readonly/runtimeDumpReadCompat.d.ts +0 -8
  398. package/dist/handlers/system/readonly/runtimeDumpReadCompat.d.ts.map +0 -1
  399. package/dist/handlers/system/readonly/runtimeDumpReadCompat.js +0 -55
  400. package/dist/handlers/system/readonly/runtimeDumpReadCompat.js.map +0 -1
@@ -0,0 +1,405 @@
1
+ "use strict";
2
+ Object.defineProperty(exports, "__esModule", { value: true });
3
+ exports.TOOL_DEFINITION = void 0;
4
+ exports.handleGetWhereUsed = handleGetWhereUsed;
5
+ const utils_1 = require("../../lib/utils");
6
+ const utils_2 = require("../../lib/utils");
7
+ const getObjectsListCache_1 = require("../../lib/getObjectsListCache");
8
+ exports.TOOL_DEFINITION = {
9
+ "name": "GetWhereUsed",
10
+ "description": "Retrieve where-used references for ABAP objects via ADT usageReferences.",
11
+ "inputSchema": {
12
+ "type": "object",
13
+ "properties": {
14
+ "object_name": {
15
+ "type": "string",
16
+ "description": "Name of the ABAP object"
17
+ },
18
+ "object_type": {
19
+ "type": "string",
20
+ "description": "Type of the ABAP object"
21
+ },
22
+ "detailed": {
23
+ "type": "boolean",
24
+ "description": "If true, returns all references including packages and internal components.",
25
+ "default": false
26
+ }
27
+ },
28
+ "required": [
29
+ "object_name",
30
+ "object_type"
31
+ ]
32
+ }
33
+ };
34
+ /**
35
+ * Builds the URI for the object based on its type and name.
36
+ *
37
+ * Supported object_type values:
38
+ * - 'class' → ABAP class
39
+ * - 'program' → ABAP program
40
+ * - 'include' → ABAP include
41
+ * - 'function' → ABAP function group
42
+ * - 'interface' → ABAP interface
43
+ * - 'package' → ABAP package
44
+ * - 'table'/'TABL' → ABAP table (DDIC)
45
+ * - 'bdef'/'BDEF' → ABAP Behavior Definition
46
+ *
47
+ * You can extend this list by adding new cases for other ADT object types (e.g. CDS, DT, etc.).
48
+ *
49
+ * If an unsupported object_type is provided, an error will be thrown.
50
+ */
51
+ function buildObjectUri(objectName, objectType) {
52
+ const encodedName = (0, utils_2.encodeSapObjectName)(objectName);
53
+ switch (objectType) {
54
+ case 'class':
55
+ return `/sap/bc/adt/oo/classes/${encodedName}`;
56
+ case 'program':
57
+ return `/sap/bc/adt/programs/programs/${encodedName}`;
58
+ case 'include':
59
+ return `/sap/bc/adt/programs/includes/${encodedName}`;
60
+ case 'function':
61
+ return `/sap/bc/adt/functions/groups/${encodedName}`;
62
+ case 'functionmodule':
63
+ case 'function_module':
64
+ case 'function-module':
65
+ case 'fm':
66
+ case 'fugr/ff':
67
+ // objectName: GROUP|FM_NAME
68
+ if (objectName.includes('|')) {
69
+ const [group, fm] = objectName.split('|');
70
+ return `/sap/bc/adt/functions/groups/${(0, utils_2.encodeSapObjectName)(group)}/fmodules/${(0, utils_2.encodeSapObjectName)(fm)}`;
71
+ }
72
+ throw new utils_1.McpError(utils_1.ErrorCode.InvalidParams, 'Function module name must be in format GROUP|FM_NAME');
73
+ case 'interface':
74
+ return `/sap/bc/adt/oo/interfaces/${encodedName}`;
75
+ case 'badi':
76
+ case 'badi_class':
77
+ case 'badi-interface':
78
+ case 'badi-implementation':
79
+ return `/sap/bc/adt/oo/interfaces/${encodedName}`;
80
+ case 'badi_class_impl':
81
+ case 'badi-class-impl':
82
+ return `/sap/bc/adt/oo/classes/${encodedName}`;
83
+ case 'package':
84
+ return `/sap/bc/adt/packages/${encodedName}`;
85
+ case 'table':
86
+ case 'tabl':
87
+ case 'TABL':
88
+ return `/sap/bc/adt/ddic/tables/${encodedName}`;
89
+ case 'dataelement':
90
+ case 'data_element':
91
+ case 'data-element':
92
+ return `/sap/bc/adt/ddic/dataelements/${encodedName}`;
93
+ case 'domain':
94
+ return `/sap/bc/adt/ddic/domains/${encodedName}`;
95
+ case 'view':
96
+ case 'ddicview':
97
+ case 'cdsview':
98
+ return `/sap/bc/adt/ddic/views/${encodedName}`;
99
+ case 'searchhelp':
100
+ case 'search_help':
101
+ case 'search-help':
102
+ return `/sap/bc/adt/ddic/searchhelps/${encodedName}`;
103
+ case 'messageclass':
104
+ case 'message_class':
105
+ case 'message-class':
106
+ return `/sap/bc/adt/ddic/messageclasses/${encodedName}`;
107
+ case 'transaction':
108
+ return `/sap/bc/adt/transactions/${encodedName}`;
109
+ case 'bdef':
110
+ case 'BDEF':
111
+ return `/sap/bc/adt/bo/behaviordefinitions/${encodedName}`;
112
+ case 'enhancementspot':
113
+ case 'enhancement_spot':
114
+ case 'enhancement-spot':
115
+ case 'enhs':
116
+ case 'enho':
117
+ return `/sap/bc/adt/enhancements/enhsxsb/${encodedName}`;
118
+ case 'enhancementimpl':
119
+ case 'enhancement_impl':
120
+ case 'enhancement-impl':
121
+ case 'enhi':
122
+ return `/sap/bc/adt/enhancements/enhoxhh/${encodedName}`;
123
+ default:
124
+ throw new utils_1.McpError(utils_1.ErrorCode.InvalidParams, `Unsupported object type: ${objectType}`);
125
+ }
126
+ }
127
+ /**
128
+ * Resolves object identifier to human-readable name using quickSearch API
129
+ */
130
+ async function resolveObjectIdentifier(objectIdentifier) {
131
+ try {
132
+ const baseUrl = await (0, utils_2.getBaseUrl)();
133
+ const query = encodeURIComponent(`${objectIdentifier}*`);
134
+ const endpoint = `${baseUrl}/sap/bc/adt/repository/informationsystem/search?operation=quickSearch&query=${query}&maxResults=1`;
135
+ const response = await (0, utils_2.makeAdtRequestWithTimeout)(endpoint, 'GET', 'default');
136
+ // Parse XML response to extract description
137
+ const descriptionMatch = response.data.match(/adtcore:description="([^"]*)"/);
138
+ if (descriptionMatch) {
139
+ return descriptionMatch[1];
140
+ }
141
+ return null;
142
+ }
143
+ catch (error) {
144
+ // If resolution fails, return null (we'll use original name)
145
+ return null;
146
+ }
147
+ }
148
+ /**
149
+ * Checks if a reference is internal class structure (self-reference)
150
+ */
151
+ function isInternalClassStructure(ref) {
152
+ // Check objectIdentifier for self-references
153
+ if (ref.objectIdentifier) {
154
+ // Pattern: CL_BUS_ABSTRACT_MAIN_SCREEN===CP means it's the class itself
155
+ // Pattern: CL_BUS_ABSTRACT_MAIN_SCREEN===CO means it's used somewhere else
156
+ if (ref.objectIdentifier.includes('===CP') || ref.objectIdentifier.includes('===CI') || ref.objectIdentifier.includes('===CU')) {
157
+ return true; // Internal structure
158
+ }
159
+ }
160
+ // Check if parentUri points to the same class as the reference
161
+ if (ref.parentUri && ref.uri) {
162
+ const parentClass = ref.parentUri.match(/\/classes\/([^\/]+)/)?.[1];
163
+ const refClass = ref.uri.match(/\/classes\/([^\/]+)/)?.[1];
164
+ if (parentClass && refClass && parentClass === refClass) {
165
+ // Additional check: if it's a method/attribute within the same class
166
+ if (ref.uri.includes('#type=CLAS%2FOM') || ref.uri.includes('#type=CLAS%2FOA')) {
167
+ return true; // Internal method or attribute
168
+ }
169
+ }
170
+ }
171
+ return false;
172
+ }
173
+ /**
174
+ * Enhances references with resolved names for better readability
175
+ */
176
+ async function enhanceReferencesWithNames(references) {
177
+ const enhancedReferences = [...references];
178
+ // Process references that have cryptic names but objectIdentifiers
179
+ for (let i = 0; i < enhancedReferences.length; i++) {
180
+ const ref = enhancedReferences[i];
181
+ // If name is empty or cryptic and we have objectIdentifier, try to resolve it
182
+ if (ref.objectIdentifier && (!ref.name || ref.name.length === 0)) {
183
+ const resolvedName = await resolveObjectIdentifier(ref.objectIdentifier);
184
+ if (resolvedName) {
185
+ enhancedReferences[i] = {
186
+ ...ref,
187
+ name: resolvedName,
188
+ originalName: ref.name // Keep original for reference
189
+ };
190
+ }
191
+ }
192
+ }
193
+ return enhancedReferences;
194
+ }
195
+ /**
196
+ * Filters references to show only the most relevant ones (excludes packages and internal components)
197
+ */
198
+ function filterMinimalReferences(references) {
199
+ return references.filter(ref => {
200
+ // PRIORITY 1: Always show enhancement implementations (most important for developers)
201
+ if (ref.type === 'ENHO/XHH') {
202
+ return true;
203
+ }
204
+ // PRIORITY 2: Show main results that are marked as important (but not packages)
205
+ if (ref.isResult === true && ref.type !== 'DEVC/K') {
206
+ return true;
207
+ }
208
+ // PRIORITY 3: Show function modules with direct usage (real implementations)
209
+ if (ref.type === 'FUGR/FF' && ref.usageInformation && ref.usageInformation.includes('gradeDirect')) {
210
+ return true;
211
+ }
212
+ // HIDE EVERYTHING ELSE IN MINIMAL MODE:
213
+ // Hide ALL packages - they're organizational, not functional usage
214
+ if (ref.type === 'DEVC/K') {
215
+ return false;
216
+ }
217
+ // Hide internal class structure (self-references)
218
+ if (isInternalClassStructure(ref)) {
219
+ return false;
220
+ }
221
+ // Hide ALL class internal structure (sections, methods, attributes)
222
+ if (ref.name === 'Public Section' || ref.name === 'Private Section' || ref.name === 'Protected Section') {
223
+ return false;
224
+ }
225
+ // Hide ALL internal class components
226
+ if (ref.type && ref.type.startsWith('CLAS/')) {
227
+ return false;
228
+ }
229
+ // Hide ALL items with empty type (usually internal structure)
230
+ if (!ref.type) {
231
+ return false;
232
+ }
233
+ // Hide function groups (show only specific functions)
234
+ if (ref.type === 'FUGR/F') {
235
+ return false;
236
+ }
237
+ // Hide programs unless they're marked as main results
238
+ if (ref.type === 'PROG/P' && !ref.isResult) {
239
+ return false;
240
+ }
241
+ // Hide includes unless they're marked as main results
242
+ if (ref.type === 'PROG/I' && !ref.isResult) {
243
+ return false;
244
+ }
245
+ // Show only if it's a main result or enhancement
246
+ return ref.isResult === true || ref.type === 'ENHO/XHH';
247
+ });
248
+ }
249
+ /**
250
+ * Parses XML response and extracts where-used references
251
+ */
252
+ function parseWhereUsedResponse(xmlData) {
253
+ const references = [];
254
+ try {
255
+ // Simple XML parsing for usageReferences response
256
+ // Look for referencedObject elements
257
+ const objectMatches = xmlData.match(/<usageReferences:referencedObject[^>]*>(.*?)<\/usageReferences:referencedObject>/gs);
258
+ if (objectMatches) {
259
+ for (const objectMatch of objectMatches) {
260
+ // Extract attributes from the referencedObject element
261
+ const uriMatch = objectMatch.match(/uri="([^"]*)"/);
262
+ const parentUriMatch = objectMatch.match(/parentUri="([^"]*)"/);
263
+ const isResultMatch = objectMatch.match(/isResult="([^"]*)"/);
264
+ const canHaveChildrenMatch = objectMatch.match(/canHaveChildren="([^"]*)"/);
265
+ const usageInformationMatch = objectMatch.match(/usageInformation="([^"]*)"/);
266
+ const uri = uriMatch ? uriMatch[1] : '';
267
+ const parentUri = parentUriMatch ? parentUriMatch[1] : undefined;
268
+ const isResult = isResultMatch ? isResultMatch[1] === 'true' : undefined;
269
+ const canHaveChildren = canHaveChildrenMatch ? canHaveChildrenMatch[1] === 'true' : undefined;
270
+ const usageInformation = usageInformationMatch ? usageInformationMatch[1] : undefined;
271
+ // Extract adtObject attributes
272
+ const adtObjectMatch = objectMatch.match(/<usageReferences:adtObject[^>]*>/);
273
+ let name = '';
274
+ let type = '';
275
+ if (adtObjectMatch) {
276
+ const nameMatch = adtObjectMatch[0].match(/adtcore:name="([^"]*)"/);
277
+ const typeMatch = adtObjectMatch[0].match(/adtcore:type="([^"]*)"/);
278
+ name = nameMatch ? nameMatch[1] : '';
279
+ type = typeMatch ? typeMatch[1] : '';
280
+ }
281
+ // Extract objectIdentifier if present
282
+ const objectIdentifierMatch = objectMatch.match(/<objectIdentifier>([^<]*)<\/objectIdentifier>/);
283
+ const objectIdentifier = objectIdentifierMatch ? objectIdentifierMatch[1] : undefined;
284
+ const reference = {
285
+ name,
286
+ type,
287
+ uri
288
+ };
289
+ if (parentUri)
290
+ reference.parentUri = parentUri;
291
+ if (isResult !== undefined)
292
+ reference.isResult = isResult;
293
+ if (canHaveChildren !== undefined)
294
+ reference.canHaveChildren = canHaveChildren;
295
+ if (usageInformation)
296
+ reference.usageInformation = usageInformation;
297
+ if (objectIdentifier)
298
+ reference.objectIdentifier = objectIdentifier;
299
+ references.push(reference);
300
+ }
301
+ }
302
+ }
303
+ catch (error) {
304
+ throw new utils_1.McpError(utils_1.ErrorCode.InternalError, `Failed to parse XML response: ${error instanceof Error ? error.message : String(error)}`);
305
+ }
306
+ return references;
307
+ }
308
+ /**
309
+ * Returns where-used references for ABAP objects.
310
+ *
311
+ * Supported object_type values:
312
+ * - class
313
+ * - program
314
+ * - include
315
+ * - function (function group)
316
+ * - functionmodule (function module, format: GROUP|FM_NAME)
317
+ * - interface
318
+ * - badi, badi_class, badi-implementation
319
+ * - package
320
+ * - table, tabl, TABL
321
+ * - dataelement
322
+ * - domain
323
+ * - view, ddicview, cdsview
324
+ * - searchhelp
325
+ * - messageclass
326
+ * - transaction
327
+ * - bdef, BDEF
328
+ * - enhancementspot, enhs, enho
329
+ * - enhancementimpl, enhi
330
+ */
331
+ async function handleGetWhereUsed(args) {
332
+ try {
333
+ // Validate required parameters
334
+ if (!args?.object_name) {
335
+ throw new utils_1.McpError(utils_1.ErrorCode.InvalidParams, 'Object name is required');
336
+ }
337
+ if (!args?.object_type) {
338
+ throw new utils_1.McpError(utils_1.ErrorCode.InvalidParams, 'Object type is required');
339
+ }
340
+ // Accept any object_type, validation is now handled in buildObjectUri
341
+ const typedArgs = args;
342
+ // 1. Build the object URI
343
+ const objectUri = buildObjectUri(typedArgs.object_name, typedArgs.object_type);
344
+ // 2. Prepare the usageReferences request
345
+ const baseUrl = await (0, utils_2.getBaseUrl)();
346
+ const endpoint = `${baseUrl}/sap/bc/adt/repository/informationsystem/usageReferences?uri=${encodeURIComponent(objectUri)}`;
347
+ const requestBody = '<?xml version="1.0" encoding="UTF-8"?><usagereferences:usageReferenceRequest xmlns:usagereferences="http://www.sap.com/adt/ris/usageReferences"><usagereferences:affectedObjects/></usagereferences:usageReferenceRequest>';
348
+ // 3. Make the POST request
349
+ const response = await (0, utils_2.makeAdtRequestWithTimeout)(endpoint, 'POST', 'default', requestBody);
350
+ // 5. Parse the XML response
351
+ const allReferences = parseWhereUsedResponse(response.data);
352
+ // 6. Filter references if detailed=false (default)
353
+ const isDetailed = typedArgs.detailed === true;
354
+ let references = allReferences;
355
+ if (!isDetailed) {
356
+ references = filterMinimalReferences(allReferences);
357
+ }
358
+ // 7. Format the response based on detailed mode
359
+ let formattedReferences;
360
+ if (isDetailed) {
361
+ // Detailed mode: show all fields
362
+ formattedReferences = references;
363
+ }
364
+ else {
365
+ // Minimal mode: show only name and type
366
+ formattedReferences = references.map(ref => ({
367
+ name: ref.name,
368
+ type: ref.type
369
+ }));
370
+ }
371
+ const formattedResponse = {
372
+ object_name: typedArgs.object_name,
373
+ object_type: typedArgs.object_type,
374
+ object_uri: objectUri,
375
+ detailed: isDetailed,
376
+ total_references: references.length,
377
+ total_found: allReferences.length,
378
+ filtered_out: isDetailed ? 0 : allReferences.length - references.length,
379
+ references: formattedReferences
380
+ };
381
+ const result = {
382
+ isError: false,
383
+ content: [
384
+ {
385
+ type: "json",
386
+ json: formattedResponse,
387
+ },
388
+ ],
389
+ };
390
+ getObjectsListCache_1.objectsListCache.setCache(result);
391
+ return result;
392
+ }
393
+ catch (error) {
394
+ // MCP-compliant error response: always return content[] with type "text"
395
+ return {
396
+ isError: true,
397
+ content: [
398
+ {
399
+ type: "text",
400
+ text: `ADT error: ${String(error)}`
401
+ }
402
+ ]
403
+ };
404
+ }
405
+ }
@@ -0,0 +1,55 @@
1
+ /**
2
+ * CheckTable Handler - Syntax check for ABAP table via ADT API
3
+ *
4
+ * Uses runTableCheckRun from @mcp-abap-adt/adt-clients/core/table for table-specific checking.
5
+ * Requires session_id for stateful operations.
6
+ */
7
+ export declare const TOOL_DEFINITION: {
8
+ readonly name: "CheckTable";
9
+ readonly description: "Perform syntax check on an ABAP table. Returns syntax errors, warnings, and messages. Requires session_id for stateful operations. Can use session_id and session_state from GetSession to maintain the same session.";
10
+ readonly inputSchema: {
11
+ readonly type: "object";
12
+ readonly properties: {
13
+ readonly table_name: {
14
+ readonly type: "string";
15
+ readonly description: "Table name (e.g., Z_MY_TABLE)";
16
+ };
17
+ readonly reporter: {
18
+ readonly type: "string";
19
+ readonly description: "Check reporter: 'tableStatusCheck' or 'abapCheckRun'. Default: abapCheckRun";
20
+ readonly enum: readonly ["tableStatusCheck", "abapCheckRun"];
21
+ };
22
+ readonly session_id: {
23
+ readonly type: "string";
24
+ readonly description: "Session ID from GetSession. If not provided, a new session will be created.";
25
+ };
26
+ readonly session_state: {
27
+ readonly type: "object";
28
+ readonly description: "Session state from GetSession (cookies, csrf_token, cookie_store). Required if session_id is provided.";
29
+ readonly properties: {
30
+ readonly cookies: {
31
+ readonly type: "string";
32
+ };
33
+ readonly csrf_token: {
34
+ readonly type: "string";
35
+ };
36
+ readonly cookie_store: {
37
+ readonly type: "object";
38
+ };
39
+ };
40
+ };
41
+ };
42
+ readonly required: readonly ["table_name"];
43
+ };
44
+ };
45
+ /**
46
+ * Main handler for CheckTable MCP tool
47
+ */
48
+ export declare function handleCheckTable(args: any): Promise<{
49
+ isError: boolean;
50
+ content: {
51
+ type: string;
52
+ text: any;
53
+ }[];
54
+ }>;
55
+ //# sourceMappingURL=handleCheckTable.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handleCheckTable.d.ts","sourceRoot":"","sources":["../../../src/handlers/table/handleCheckTable.ts"],"names":[],"mappings":"AAAA;;;;;GAKG;AAQH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;;CA+BlB,CAAC;AAaX;;GAEG;AACH,wBAAsB,gBAAgB,CAAC,IAAI,EAAE,GAAG;;;;;;GAyG/C"}
@@ -0,0 +1,138 @@
1
+ "use strict";
2
+ /**
3
+ * CheckTable Handler - Syntax check for ABAP table via ADT API
4
+ *
5
+ * Uses runTableCheckRun from @mcp-abap-adt/adt-clients/core/table for table-specific checking.
6
+ * Requires session_id for stateful operations.
7
+ */
8
+ Object.defineProperty(exports, "__esModule", { value: true });
9
+ exports.TOOL_DEFINITION = void 0;
10
+ exports.handleCheckTable = handleCheckTable;
11
+ const utils_1 = require("../../lib/utils");
12
+ const sessionUtils_1 = require("../../lib/sessionUtils");
13
+ const adt_clients_1 = require("@mcp-abap-adt/adt-clients");
14
+ const checkRunParser_1 = require("../../lib/checkRunParser");
15
+ exports.TOOL_DEFINITION = {
16
+ name: "CheckTable",
17
+ description: "Perform syntax check on an ABAP table. Returns syntax errors, warnings, and messages. Requires session_id for stateful operations. Can use session_id and session_state from GetSession to maintain the same session.",
18
+ inputSchema: {
19
+ type: "object",
20
+ properties: {
21
+ table_name: {
22
+ type: "string",
23
+ description: "Table name (e.g., Z_MY_TABLE)"
24
+ },
25
+ reporter: {
26
+ type: "string",
27
+ description: "Check reporter: 'tableStatusCheck' or 'abapCheckRun'. Default: abapCheckRun",
28
+ enum: ["tableStatusCheck", "abapCheckRun"]
29
+ },
30
+ session_id: {
31
+ type: "string",
32
+ description: "Session ID from GetSession. If not provided, a new session will be created."
33
+ },
34
+ session_state: {
35
+ type: "object",
36
+ description: "Session state from GetSession (cookies, csrf_token, cookie_store). Required if session_id is provided.",
37
+ properties: {
38
+ cookies: { type: "string" },
39
+ csrf_token: { type: "string" },
40
+ cookie_store: { type: "object" }
41
+ }
42
+ }
43
+ },
44
+ required: ["table_name"]
45
+ }
46
+ };
47
+ /**
48
+ * Main handler for CheckTable MCP tool
49
+ */
50
+ async function handleCheckTable(args) {
51
+ try {
52
+ const { table_name, reporter = 'abapCheckRun', session_id, session_state } = args;
53
+ if (!table_name) {
54
+ return (0, utils_1.return_error)(new Error('table_name is required'));
55
+ }
56
+ const validReporters = ['tableStatusCheck', 'abapCheckRun'];
57
+ const checkReporter = (reporter && validReporters.includes(reporter))
58
+ ? reporter
59
+ : 'abapCheckRun';
60
+ const connection = (0, utils_1.getManagedConnection)();
61
+ // Restore session state if provided
62
+ if (session_id && session_state) {
63
+ connection.setSessionState({
64
+ cookies: session_state.cookies || null,
65
+ csrfToken: session_state.csrf_token || null,
66
+ cookieStore: session_state.cookie_store || {}
67
+ });
68
+ }
69
+ else {
70
+ // Ensure connection is established
71
+ await connection.connect();
72
+ }
73
+ // Use provided session_id or generate new one (required for table check)
74
+ const sessionId = session_id || (0, sessionUtils_1.generateSessionId)();
75
+ const tableName = table_name.toUpperCase();
76
+ utils_1.logger.info(`Starting table check: ${tableName} (reporter: ${checkReporter}, session: ${sessionId.substring(0, 8)}...)`);
77
+ try {
78
+ const builder = new adt_clients_1.CrudClient(connection);
79
+ await builder.checkTable(checkReporter);
80
+ const response = builder.getCheckResult();
81
+ if (!response) {
82
+ throw new Error('Table check did not return a response');
83
+ }
84
+ // Parse check results
85
+ const checkResult = (0, checkRunParser_1.parseCheckRunResponse)(response);
86
+ // Get updated session state after check
87
+ const updatedSessionState = connection.getSessionState();
88
+ utils_1.logger.info(`✅ CheckTable completed: ${tableName}`);
89
+ utils_1.logger.info(` Status: ${checkResult.status}`);
90
+ utils_1.logger.info(` Errors: ${checkResult.errors.length}, Warnings: ${checkResult.warnings.length}`);
91
+ return (0, utils_1.return_response)({
92
+ data: JSON.stringify({
93
+ success: checkResult.success,
94
+ table_name: tableName,
95
+ reporter: checkReporter,
96
+ check_result: checkResult,
97
+ session_id: sessionId,
98
+ session_state: updatedSessionState ? {
99
+ cookies: updatedSessionState.cookies,
100
+ csrf_token: updatedSessionState.csrfToken,
101
+ cookie_store: updatedSessionState.cookieStore
102
+ } : null,
103
+ message: checkResult.success
104
+ ? `Table ${tableName} has no syntax errors`
105
+ : `Table ${tableName} has ${checkResult.errors.length} error(s) and ${checkResult.warnings.length} warning(s)`
106
+ }, null, 2)
107
+ });
108
+ }
109
+ catch (error) {
110
+ utils_1.logger.error(`Error checking table ${tableName}:`, error);
111
+ let errorMessage = `Failed to check table: ${error.message || String(error)}`;
112
+ if (error.response?.status === 404) {
113
+ errorMessage = `Table ${tableName} not found.`;
114
+ }
115
+ else if (error.response?.data && typeof error.response.data === 'string') {
116
+ try {
117
+ const { XMLParser } = require('fast-xml-parser');
118
+ const parser = new XMLParser({
119
+ ignoreAttributes: false,
120
+ attributeNamePrefix: '@_'
121
+ });
122
+ const errorData = parser.parse(error.response.data);
123
+ const errorMsg = errorData['exc:exception']?.message?.['#text'] || errorData['exc:exception']?.message;
124
+ if (errorMsg) {
125
+ errorMessage = `SAP Error: ${errorMsg}`;
126
+ }
127
+ }
128
+ catch (parseError) {
129
+ // Ignore parse errors
130
+ }
131
+ }
132
+ return (0, utils_1.return_error)(new Error(errorMessage));
133
+ }
134
+ }
135
+ catch (error) {
136
+ return (0, utils_1.return_error)(error);
137
+ }
138
+ }
@@ -0,0 +1,42 @@
1
+ /**
2
+ * CreateTable Handler - ABAP Table Creation via ADT API
3
+ *
4
+ * Uses TableBuilder from @mcp-abap-adt/adt-clients for all operations.
5
+ * Session and lock management handled internally by builder.
6
+ *
7
+ * Workflow: validate -> create -> lock -> update -> check -> unlock -> (activate)
8
+ */
9
+ export declare const TOOL_DEFINITION: {
10
+ readonly name: "CreateTable";
11
+ readonly description: "Create a new ABAP table via the ADT API using provided DDL. Mirrors Eclipse ADT behaviour with status/check runs, lock handling, activation and verification.";
12
+ readonly inputSchema: {
13
+ readonly type: "object";
14
+ readonly properties: {
15
+ readonly table_name: {
16
+ readonly type: "string";
17
+ readonly description: "Table name (e.g., ZZ_TEST_TABLE_001). Must follow SAP naming conventions.";
18
+ };
19
+ readonly ddl_code: {
20
+ readonly type: "string";
21
+ readonly description: "Complete DDL code for table creation. Example: '@EndUserText.label : \\'My Table\\' @AbapCatalog.tableCategory : #TRANSPARENT define table ztst_table { key client : abap.clnt not null; key id : abap.char(10); name : abap.char(255); }'";
22
+ };
23
+ readonly package_name: {
24
+ readonly type: "string";
25
+ readonly description: "Package name (e.g., ZOK_LOCAL, $TMP for local objects)";
26
+ };
27
+ readonly transport_request: {
28
+ readonly type: "string";
29
+ readonly description: "Transport request number (e.g., E19K905635). Required for transportable packages.";
30
+ };
31
+ };
32
+ readonly required: readonly ["table_name", "ddl_code", "package_name"];
33
+ };
34
+ };
35
+ /**
36
+ * Main handler for CreateTable MCP tool
37
+ *
38
+ * Uses TableBuilder from @mcp-abap-adt/adt-clients for all operations
39
+ * Session and lock management handled internally by builder
40
+ */
41
+ export declare function handleCreateTable(args: any): Promise<any>;
42
+ //# sourceMappingURL=handleCreateTable.d.ts.map
@@ -0,0 +1 @@
1
+ {"version":3,"file":"handleCreateTable.d.ts","sourceRoot":"","sources":["../../../src/handlers/table/handleCreateTable.ts"],"names":[],"mappings":"AAAA;;;;;;;GAOG;AAQH,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;;;;CAyBlB,CAAC;AAUX;;;;;GAKG;AACH,wBAAsB,iBAAiB,CAAC,IAAI,EAAE,GAAG,GAAG,OAAO,CAAC,GAAG,CAAC,CA4F/D"}