arc-1 0.9.19 → 0.9.21

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 (177) hide show
  1. package/README.md +7 -4
  2. package/dist/adt/client.d.ts +29 -1
  3. package/dist/adt/client.d.ts.map +1 -1
  4. package/dist/adt/client.js +72 -3
  5. package/dist/adt/client.js.map +1 -1
  6. package/dist/adt/ddic-xml.d.ts +29 -0
  7. package/dist/adt/ddic-xml.d.ts.map +1 -1
  8. package/dist/adt/ddic-xml.js +112 -1
  9. package/dist/adt/ddic-xml.js.map +1 -1
  10. package/dist/adt/devtools.d.ts +9 -2
  11. package/dist/adt/devtools.d.ts.map +1 -1
  12. package/dist/adt/devtools.js +126 -5
  13. package/dist/adt/devtools.js.map +1 -1
  14. package/dist/adt/diagnostics.d.ts +99 -4
  15. package/dist/adt/diagnostics.d.ts.map +1 -1
  16. package/dist/adt/diagnostics.js +443 -10
  17. package/dist/adt/diagnostics.js.map +1 -1
  18. package/dist/adt/errors.d.ts +13 -1
  19. package/dist/adt/errors.d.ts.map +1 -1
  20. package/dist/adt/errors.js +244 -25
  21. package/dist/adt/errors.js.map +1 -1
  22. package/dist/adt/features.d.ts.map +1 -1
  23. package/dist/adt/features.js +2 -1
  24. package/dist/adt/features.js.map +1 -1
  25. package/dist/adt/gcts.d.ts +3 -3
  26. package/dist/adt/gcts.d.ts.map +1 -1
  27. package/dist/adt/gcts.js +24 -3
  28. package/dist/adt/gcts.js.map +1 -1
  29. package/dist/adt/http.d.ts.map +1 -1
  30. package/dist/adt/http.js +4 -3
  31. package/dist/adt/http.js.map +1 -1
  32. package/dist/adt/transport.d.ts +43 -4
  33. package/dist/adt/transport.d.ts.map +1 -1
  34. package/dist/adt/transport.js +84 -10
  35. package/dist/adt/transport.js.map +1 -1
  36. package/dist/adt/types.d.ts +104 -0
  37. package/dist/adt/types.d.ts.map +1 -1
  38. package/dist/adt/xml-parser.d.ts +37 -0
  39. package/dist/adt/xml-parser.d.ts.map +1 -1
  40. package/dist/adt/xml-parser.js +102 -0
  41. package/dist/adt/xml-parser.js.map +1 -1
  42. package/dist/authz/policy.d.ts.map +1 -1
  43. package/dist/authz/policy.js +11 -1
  44. package/dist/authz/policy.js.map +1 -1
  45. package/dist/cache/cache.d.ts +25 -0
  46. package/dist/cache/cache.d.ts.map +1 -1
  47. package/dist/cache/cache.js.map +1 -1
  48. package/dist/cache/caching-layer.d.ts +31 -2
  49. package/dist/cache/caching-layer.d.ts.map +1 -1
  50. package/dist/cache/caching-layer.js +102 -2
  51. package/dist/cache/caching-layer.js.map +1 -1
  52. package/dist/cache/memory.d.ts +2 -1
  53. package/dist/cache/memory.d.ts.map +1 -1
  54. package/dist/cache/memory.js +46 -0
  55. package/dist/cache/memory.js.map +1 -1
  56. package/dist/cache/sqlite.d.ts +2 -1
  57. package/dist/cache/sqlite.d.ts.map +1 -1
  58. package/dist/cache/sqlite.js +64 -0
  59. package/dist/cache/sqlite.js.map +1 -1
  60. package/dist/cli.js +4 -2
  61. package/dist/cli.js.map +1 -1
  62. package/dist/handlers/context.d.ts.map +1 -1
  63. package/dist/handlers/context.js +27 -4
  64. package/dist/handlers/context.js.map +1 -1
  65. package/dist/handlers/diagnose.d.ts.map +1 -1
  66. package/dist/handlers/diagnose.js +88 -4
  67. package/dist/handlers/diagnose.js.map +1 -1
  68. package/dist/handlers/dispatch.d.ts.map +1 -1
  69. package/dist/handlers/dispatch.js +9 -0
  70. package/dist/handlers/dispatch.js.map +1 -1
  71. package/dist/handlers/feature-cache.d.ts +5 -0
  72. package/dist/handlers/feature-cache.d.ts.map +1 -1
  73. package/dist/handlers/feature-cache.js +10 -0
  74. package/dist/handlers/feature-cache.js.map +1 -1
  75. package/dist/handlers/git.d.ts.map +1 -1
  76. package/dist/handlers/git.js +3 -3
  77. package/dist/handlers/git.js.map +1 -1
  78. package/dist/handlers/manage.d.ts.map +1 -1
  79. package/dist/handlers/manage.js +44 -0
  80. package/dist/handlers/manage.js.map +1 -1
  81. package/dist/handlers/object-types.d.ts +1 -1
  82. package/dist/handlers/object-types.d.ts.map +1 -1
  83. package/dist/handlers/object-types.js +17 -2
  84. package/dist/handlers/object-types.js.map +1 -1
  85. package/dist/handlers/query.d.ts.map +1 -1
  86. package/dist/handlers/query.js +35 -3
  87. package/dist/handlers/query.js.map +1 -1
  88. package/dist/handlers/read.d.ts.map +1 -1
  89. package/dist/handlers/read.js +33 -8
  90. package/dist/handlers/read.js.map +1 -1
  91. package/dist/handlers/schemas.d.ts +79 -5
  92. package/dist/handlers/schemas.d.ts.map +1 -1
  93. package/dist/handlers/schemas.js +33 -0
  94. package/dist/handlers/schemas.js.map +1 -1
  95. package/dist/handlers/tool-registry.d.ts +4 -4
  96. package/dist/handlers/tool-registry.d.ts.map +1 -1
  97. package/dist/handlers/tool-registry.js +6 -0
  98. package/dist/handlers/tool-registry.js.map +1 -1
  99. package/dist/handlers/tools.d.ts.map +1 -1
  100. package/dist/handlers/tools.js +132 -34
  101. package/dist/handlers/tools.js.map +1 -1
  102. package/dist/handlers/transport.d.ts.map +1 -1
  103. package/dist/handlers/transport.js +82 -5
  104. package/dist/handlers/transport.js.map +1 -1
  105. package/dist/handlers/write/create.d.ts.map +1 -1
  106. package/dist/handlers/write/create.js +224 -7
  107. package/dist/handlers/write/create.js.map +1 -1
  108. package/dist/handlers/write-helpers.d.ts +1 -0
  109. package/dist/handlers/write-helpers.d.ts.map +1 -1
  110. package/dist/handlers/write-helpers.js +49 -5
  111. package/dist/handlers/write-helpers.js.map +1 -1
  112. package/dist/handlers/write.d.ts.map +1 -1
  113. package/dist/handlers/write.js +18 -2
  114. package/dist/handlers/write.js.map +1 -1
  115. package/dist/plugins/manifest-interpreter.d.ts.map +1 -1
  116. package/dist/plugins/manifest-interpreter.js +3 -1
  117. package/dist/plugins/manifest-interpreter.js.map +1 -1
  118. package/dist/public/testing.d.ts +2 -1
  119. package/dist/public/testing.d.ts.map +1 -1
  120. package/dist/public/testing.js +13 -0
  121. package/dist/public/testing.js.map +1 -1
  122. package/dist/public/types.d.ts +2 -2
  123. package/dist/public/types.d.ts.map +1 -1
  124. package/dist/public/ui/app.js +1044 -0
  125. package/dist/public/ui/arc-mark.svg +5 -0
  126. package/dist/public/ui/index.html +43 -0
  127. package/dist/public/ui/styles.css +563 -0
  128. package/dist/server/audit.d.ts +4 -2
  129. package/dist/server/audit.d.ts.map +1 -1
  130. package/dist/server/audit.js +42 -13
  131. package/dist/server/audit.js.map +1 -1
  132. package/dist/server/config.d.ts.map +1 -1
  133. package/dist/server/config.js +103 -1
  134. package/dist/server/config.js.map +1 -1
  135. package/dist/server/http.d.ts +2 -1
  136. package/dist/server/http.d.ts.map +1 -1
  137. package/dist/server/http.js +22 -1
  138. package/dist/server/http.js.map +1 -1
  139. package/dist/server/logger.d.ts +1 -1
  140. package/dist/server/logger.d.ts.map +1 -1
  141. package/dist/server/logger.js +9 -4
  142. package/dist/server/logger.js.map +1 -1
  143. package/dist/server/plugin-loader.d.ts.map +1 -1
  144. package/dist/server/plugin-loader.js +1 -1
  145. package/dist/server/plugin-loader.js.map +1 -1
  146. package/dist/server/safe-http-client.d.ts +12 -6
  147. package/dist/server/safe-http-client.d.ts.map +1 -1
  148. package/dist/server/safe-http-client.js +84 -15
  149. package/dist/server/safe-http-client.js.map +1 -1
  150. package/dist/server/server.d.ts +1 -1
  151. package/dist/server/server.d.ts.map +1 -1
  152. package/dist/server/server.js +29 -4
  153. package/dist/server/server.js.map +1 -1
  154. package/dist/server/sinks/file.d.ts +3 -0
  155. package/dist/server/sinks/file.d.ts.map +1 -1
  156. package/dist/server/sinks/file.js +15 -3
  157. package/dist/server/sinks/file.js.map +1 -1
  158. package/dist/server/sinks/stderr.d.ts.map +1 -1
  159. package/dist/server/sinks/stderr.js +2 -30
  160. package/dist/server/sinks/stderr.js.map +1 -1
  161. package/dist/server/types.d.ts +22 -0
  162. package/dist/server/types.d.ts.map +1 -1
  163. package/dist/server/types.js +7 -0
  164. package/dist/server/types.js.map +1 -1
  165. package/dist/server/ui-log-buffer.d.ts +29 -0
  166. package/dist/server/ui-log-buffer.d.ts.map +1 -0
  167. package/dist/server/ui-log-buffer.js +72 -0
  168. package/dist/server/ui-log-buffer.js.map +1 -0
  169. package/dist/server/ui-state.d.ts +32 -0
  170. package/dist/server/ui-state.d.ts.map +1 -0
  171. package/dist/server/ui-state.js +230 -0
  172. package/dist/server/ui-state.js.map +1 -0
  173. package/dist/server/ui.d.ts +20 -0
  174. package/dist/server/ui.d.ts.map +1 -0
  175. package/dist/server/ui.js +275 -0
  176. package/dist/server/ui.js.map +1 -0
  177. package/package.json +13 -9
@@ -27,13 +27,13 @@
27
27
  * same literal set, in table order.
28
28
  */
29
29
  /** All SAPRead object types available on on-premise (the superset). */
30
- export declare const SAPREAD_TYPES_ONPREM: ("PROG" | "CLAS" | "INTF" | "INCL" | "FUGR" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "DEVC" | "TRAN" | "VIEW" | "SKTD" | "FUNC" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA" | "TABLE_CONTENTS" | "TABLE_QUERY" | "SOBJ" | "SYSTEM" | "COMPONENTS" | "MESSAGES" | "TEXT_ELEMENTS" | "VARIANTS" | "BSP" | "BSP_DEPLOY" | "API_STATE" | "INACTIVE_OBJECTS" | "AUTH" | "FEATURE_TOGGLE" | "FTG2" | "ENHO" | "VERSIONS" | "VERSION_SOURCE")[];
30
+ export declare const SAPREAD_TYPES_ONPREM: ("PROG" | "CLAS" | "INTF" | "INCL" | "FUGR" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "DEVC" | "TRAN" | "VIEW" | "SKTD" | "FUNC" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA" | "TTYP" | "KTD" | "TABLE_CONTENTS" | "TABLE_QUERY" | "SOBJ" | "SYSTEM" | "COMPONENTS" | "MESSAGES" | "TEXT_ELEMENTS" | "VARIANTS" | "BSP" | "BSP_DEPLOY" | "API_STATE" | "INACTIVE_OBJECTS" | "AUTH" | "FEATURE_TOGGLE" | "FTG2" | "ENHO" | "VERSIONS" | "VERSION_SOURCE")[];
31
31
  /** SAPRead types available on BTP ABAP Environment (the `btp: true` rows). */
32
- export declare const SAPREAD_TYPES_BTP: ("CLAS" | "INTF" | "FUGR" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "DEVC" | "SKTD" | "FUNC" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA" | "TABLE_CONTENTS" | "TABLE_QUERY" | "SYSTEM" | "COMPONENTS" | "MESSAGES" | "BSP" | "BSP_DEPLOY" | "API_STATE" | "INACTIVE_OBJECTS")[];
32
+ export declare const SAPREAD_TYPES_BTP: ("CLAS" | "INTF" | "FUGR" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "DEVC" | "SKTD" | "FUNC" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA" | "KTD" | "TABLE_CONTENTS" | "TABLE_QUERY" | "SYSTEM" | "COMPONENTS" | "MESSAGES" | "BSP" | "BSP_DEPLOY" | "API_STATE" | "INACTIVE_OBJECTS")[];
33
33
  /** All SAPWrite object types available on on-premise (the superset). */
34
- export declare const SAPWRITE_TYPES_ONPREM: ("PROG" | "CLAS" | "INTF" | "INCL" | "FUGR" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "SKTD" | "TABL/DT" | "TABL/DS" | "FUNC" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA")[];
34
+ export declare const SAPWRITE_TYPES_ONPREM: ("PROG" | "CLAS" | "INTF" | "INCL" | "FUGR" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "SKTD" | "TABL/DT" | "TABL/DS" | "FUNC" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA" | "TTYP" | "KTD")[];
35
35
  /** SAPWrite types available on BTP ABAP Environment (the `btp: true` rows). */
36
- export declare const SAPWRITE_TYPES_BTP: ("CLAS" | "INTF" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "SKTD" | "TABL/DT" | "TABL/DS" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA")[];
36
+ export declare const SAPWRITE_TYPES_BTP: ("CLAS" | "INTF" | "DDLS" | "DCLS" | "BDEF" | "SRVD" | "DDLX" | "SRVB" | "TABL" | "DOMA" | "DTEL" | "MSAG" | "SKTD" | "TABL/DT" | "TABL/DS" | "DESD" | "DTSC" | "CSNM" | "EVTB" | "EVTO" | "COTA" | "KTD")[];
37
37
  /** SAPContext types on on-premise. */
38
38
  export declare const SAPCONTEXT_TYPES_ONPREM: ("PROG" | "CLAS" | "INTF" | "DDLS" | "FUNC")[];
39
39
  /** SAPContext types on BTP. */
@@ -1 +1 @@
1
- {"version":3,"file":"tool-registry.d.ts","sourceRoot":"","sources":["../../src/handlers/tool-registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAiFH,uEAAuE;AACvE,eAAO,MAAM,oBAAoB,ueAAsB,CAAC;AACxD,8EAA8E;AAC9E,eAAO,MAAM,iBAAiB,6UAAmB,CAAC;AA8BlD,wEAAwE;AACxE,eAAO,MAAM,qBAAqB,0OAAuB,CAAC;AAC1D,+EAA+E;AAC/E,eAAO,MAAM,kBAAkB,sMAAoB,CAAC;AAYpD,sCAAsC;AACtC,eAAO,MAAM,uBAAuB,gDAAyB,CAAC;AAC9D,+BAA+B;AAC/B,eAAO,MAAM,oBAAoB,8BAAsB,CAAC;AAIxD,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,oBAAoB,CAAC,CAAC,MAAM,CAAC,CAAC;AAChE,MAAM,MAAM,YAAY,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAClE,MAAM,MAAM,cAAc,GAAG,CAAC,OAAO,uBAAuB,CAAC,CAAC,MAAM,CAAC,CAAC"}
1
+ {"version":3,"file":"tool-registry.d.ts","sourceRoot":"","sources":["../../src/handlers/tool-registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAoFH,uEAAuE;AACvE,eAAO,MAAM,oBAAoB,wfAAsB,CAAC;AACxD,8EAA8E;AAC9E,eAAO,MAAM,iBAAiB,qVAAmB,CAAC;AAiClD,wEAAwE;AACxE,eAAO,MAAM,qBAAqB,2PAAuB,CAAC;AAC1D,+EAA+E;AAC/E,eAAO,MAAM,kBAAkB,8MAAoB,CAAC;AAYpD,sCAAsC;AACtC,eAAO,MAAM,uBAAuB,gDAAyB,CAAC;AAC9D,+BAA+B;AAC/B,eAAO,MAAM,oBAAoB,8BAAsB,CAAC;AAIxD,MAAM,MAAM,WAAW,GAAG,CAAC,OAAO,oBAAoB,CAAC,CAAC,MAAM,CAAC,CAAC;AAChE,MAAM,MAAM,YAAY,GAAG,CAAC,OAAO,qBAAqB,CAAC,CAAC,MAAM,CAAC,CAAC;AAClE,MAAM,MAAM,cAAc,GAAG,CAAC,OAAO,uBAAuB,CAAC,CAAC,MAAM,CAAC,CAAC"}
@@ -64,11 +64,14 @@ const SAPREAD_TYPE_TABLE = [
64
64
  { type: 'SRVD', btp: true },
65
65
  { type: 'SRVB', btp: true },
66
66
  { type: 'SKTD', btp: true },
67
+ // Friendly alias for Knowledge Transfer Documents; normalized to canonical SKTD at dispatch.
68
+ { type: 'KTD', btp: true },
67
69
  { type: 'TABL', btp: true },
68
70
  { type: 'VIEW', btp: false },
69
71
  { type: 'DOMA', btp: true },
70
72
  { type: 'DTEL', btp: true },
71
73
  { type: 'TRAN', btp: false },
74
+ { type: 'TTYP', btp: false },
72
75
  { type: 'TABLE_CONTENTS', btp: true },
73
76
  { type: 'TABLE_QUERY', btp: true },
74
77
  { type: 'DEVC', btp: true },
@@ -120,6 +123,8 @@ const SAPWRITE_TYPE_TABLE = [
120
123
  { type: 'SRVD', btp: true },
121
124
  { type: 'SRVB', btp: true },
122
125
  { type: 'SKTD', btp: true },
126
+ // Friendly alias for Knowledge Transfer Documents; normalized to canonical SKTD at dispatch.
127
+ { type: 'KTD', btp: true },
123
128
  { type: 'TABL', btp: true },
124
129
  // Subtype routing for create — see docs/plans/completed/fix-tabl-ds-create-routing.md.
125
130
  { type: 'TABL/DT', btp: true },
@@ -127,6 +132,7 @@ const SAPWRITE_TYPE_TABLE = [
127
132
  { type: 'DOMA', btp: true },
128
133
  { type: 'DTEL', btp: true },
129
134
  { type: 'MSAG', btp: true },
135
+ { type: 'TTYP', btp: false },
130
136
  // Server-driven objects (8.16+) — write via the generic blue:blueSource + AFF JSON engine.
131
137
  // Rows derive from SDO_TYPES exactly like the SAPRead table above.
132
138
  ...SDO_TYPES.map((t) => ({ type: t, btp: true })),
@@ -1 +1 @@
1
- {"version":3,"file":"tool-registry.js","sourceRoot":"","sources":["../../src/handlers/tool-registry.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;;;;;;;;;;;GA2BG;AAEH,OAAO,EAAE,SAAS,EAAE,MAAM,yBAAyB,CAAC;AAEpD;;;;;;;;;GASG;AACH,SAAS,gBAAgB,CACvB,KAAmB;IAEnB,MAAM,IAAI,GAAG,IAAI,GAAG,EAAU,CAAC;IAC/B,KAAK,MAAM,GAAG,IAAI,KAAK,EAAE,CAAC;QACxB,IAAI,IAAI,CAAC,GAAG,CAAC,GAAG,CAAC,IAAI,CAAC;YAAE,MAAM,IAAI,KAAK,CAAC,sC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gB,kBAAkB,CAChC,MAAM,EAAE,YAAY,EACpB,mBAAmB,CAAC,EAAE,OAAO,EAC7B,gBAAgB,CAAC,EAAE,gBAAgB,GAClC,cAAc,EAAE,CAwpClB"}
1
+ {"version":3,"file":"tools.d.ts","sourceRoot":"","sources":["../../src/handlers/tools.ts"],"names":[],"mappings":"AAAA;;;;;;;;;;;;;;;;;GAiBG;AAEH,OAAO,KAAK,EAAE,gBAAgB,EAAE,MAAM,iBAAiB,CAAC;AAExD,OAAO,KAAK,EAAE,YAAY,EAAE,MAAM,oBAAoB,CAAC;AAYvD,8FAA8F;AAC9F,MAAM,WAAW,eAAe;IAC9B,YAAY,CAAC,EAAE,OAAO,CAAC;IACvB,eAAe,CAAC,EAAE,OAAO,CAAC;IAC1B,cAAc,CAAC,EAAE,OAAO,CAAC;IACzB,aAAa,CAAC,EAAE,OAAO,CAAC;IACxB,KAAK,CAAC,EAAE,MAAM,CAAC;CAChB;AAED,MAAM,WAAW,cAAc;IAC7B,IAAI,EAAE,MAAM,CAAC;IACb,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC,MAAM,EAAE,OAAO,CAAC,CAAC;IACrC,WAAW,CAAC,EAAE,eAAe,CAAC;CAC/B;AAwbD,wBAAgB,kBAAkB,CAChC,MAAM,EAAE,YAAY,EACpB,mBAAmB,CAAC,EAAE,OAAO,EAC7B,gBAAgB,CAAC,EAAE,gBAAgB,GAClC,cAAc,EAAE,CAgwClB"}
@@ -39,8 +39,9 @@ const TOOL_ANNOTATIONS = {
39
39
  SAPNavigate: { readOnlyHint: true },
40
40
  SAPQuery: { readOnlyHint: true },
41
41
  SAPContext: { readOnlyHint: true },
42
- SAPDiagnose: { readOnlyHint: true },
43
42
  // Mutating, non-destructive (no delete action).
43
+ // SAPDiagnose.apply_quickfix is a write/Update action, so the tool is not read-only.
44
+ SAPDiagnose: { readOnlyHint: false, destructiveHint: false },
44
45
  SAPLint: { readOnlyHint: false, destructiveHint: false },
45
46
  SAPActivate: { readOnlyHint: false, destructiveHint: false },
46
47
  // Mutating AND destructive (delete / unlink / overwriting actions).
@@ -56,14 +57,14 @@ function isBtpMode(config) {
56
57
  // ─── SAPRead Types ──────────────────────────────────────────────────
57
58
  /** All SAPRead types available on on-premise */
58
59
  /** SAPRead types available on BTP ABAP Environment (no PROG, INCL, VIEW, TEXT_ELEMENTS, VARIANTS) */
59
- const SAPREAD_DESC_ONPREM = 'Read SAP ABAP objects. Types: PROG, CLAS, INTF, FUNC, FUGR (use expand_includes=true to get all include sources), INCL, DDLS, DCLS (CDS access controls), DDLX (CDS metadata extensions — UI annotations), BDEF, SRVD, SRVB (service bindings — returns structured binding info: OData version, publish status, service definition ref), SKTD (Knowledge Transfer Documents — Markdown documentation attached to ABAP objects like CDS views, BDEFs, classes), TABL (DDIC TABL — covers transparent tables like T000 AND DDIC structures like BAPIRET2; returns CDS-like source. ARC-1 auto-resolves the URL: tries /sap/bc/adt/ddic/tables/ first, falls back to /sap/bc/adt/ddic/structures/. Note: there is no separate STRU type — TABL is the canonical short type for both, mirroring TADIR R3TR TABL and abapGit conventions), VIEW, DOMA (DDIC domains — returns type info, value table, fixed values), DTEL (data elements — returns domain, labels, search help), TRAN (transaction codes — returns description, program, package), TABLE_CONTENTS (simple row preview — no filter or single-column filter; use TABLE_QUERY for multi-column WHERE), TABLE_QUERY (structured multi-column query on DDIC tables and CDS views via the freestyle endpoint — supports AND conditions, column selection; gated by allowDataPreview; use instead of TABLE_CONTENTS when filtering on multiple fields. Note: CDS views require SAP_BASIS 752+ — NW 7.50/7.51 rejects them with "TABLE is invalid here"), DEVC, SOBJ (BOR business objects — returns method catalog or full implementation), SYSTEM, COMPONENTS, MSAG (message classes — returns class metadata + messages array), TEXT_ELEMENTS, VARIANTS. For CLAS: omit include to get the full class source (definition + implementation combined). The include param is optional — use it only to read class-local sections: definitions (local types), implementations (local helper classes), macros, testclasses (ABAP Unit). For CLAS with method param: use method="*" to list all methods with signatures and visibility, or method="method_name" to read a single method implementation (95% fewer tokens than full source). For SOBJ: returns BOR method catalog; use method param to read a specific method implementation. BSP (deployed UI5/Fiori apps — list apps, browse files, read content; use name to browse app structure, include for subfolder or file), BSP_DEPLOY (query deployed UI5 apps via ABAP Repository OData Service — returns name, package, description). API_STATE (API release state — checks if an object is released for ABAP Cloud / S/4HANA Clean Core; returns contract states C0-C4, successor info; use objectType param for non-class objects). INACTIVE_OBJECTS (list all objects pending activation — no name param needed; use before SAPActivate batch_activate to see what needs activating). AUTH (Authorization Fields — returns check table, domain, conversion exit, org-level flags; on-prem only). FEATURE_TOGGLE (Feature Toggles — returns current toggle state per system from SAP switch framework; on-prem only). ENHO (Enhancement Implementations / BAdI — returns technology type, referenced enhancement object, and BAdI implementations with implementing classes; on-prem only). VERSIONS (list revision history of an object — returns JSON with object metadata and revisions [{id, author, timestamp, versionTitle?, transport?, uri}]; pass optional include for CLAS or group for FUNC; on-prem only and may return 404 for some DDIC types on non-S/4 backends). VERSION_SOURCE (fetch source at a specific revision URI from VERSIONS response; returns raw source text; on-prem only). ' +
60
+ const SAPREAD_DESC_ONPREM = 'Read SAP ABAP objects. Use SAPRead when you need exact raw source, a specific method body, grep output, inactive drafts, revision history, or metadata. For "what does this object do?", object explanation, spec work, reviews, or pre-change orientation, prefer SAPContext first because it returns intent-level context before raw source. Types: PROG, CLAS, INTF, FUNC, FUGR (use expand_includes=true to get all include sources), INCL, DDLS, DCLS (CDS access controls), DDLX (CDS metadata extensions — UI annotations), BDEF, SRVD, SRVB (service bindings — returns structured binding info: OData version, publish status, service definition ref), SKTD/KTD (Knowledge Transfer Documents — Markdown documentation attached to KTD-capable ABAP objects like DDLS, BDEF, SRVD, SRVB, and packages; KTD is a friendly alias for SKTD), TABL (DDIC TABL — covers transparent tables like T000 AND DDIC structures like BAPIRET2; returns CDS-like source. ARC-1 auto-resolves the URL: tries /sap/bc/adt/ddic/tables/ first, falls back to /sap/bc/adt/ddic/structures/. Note: there is no separate STRU type — TABL is the canonical short type for both, mirroring TADIR R3TR TABL and abapGit conventions), VIEW, DOMA (DDIC domains — returns type info, value table, fixed values), DTEL (data elements — returns domain, labels, search help), TRAN (transaction codes — returns description, program, package), TABLE_CONTENTS (simple row preview — no filter or single-column filter; use TABLE_QUERY for multi-column WHERE), TABLE_QUERY (structured multi-column query on DDIC tables and CDS views via the freestyle endpoint — supports AND conditions, column selection; gated by allowDataPreview; use instead of TABLE_CONTENTS when filtering on multiple fields. Note: CDS views require SAP_BASIS 752+ — NW 7.50/7.51 rejects them with "TABLE is invalid here"), DEVC, SOBJ (BOR business objects — returns method catalog or full implementation), SYSTEM, COMPONENTS, MSAG (message classes — returns class metadata + messages array), TEXT_ELEMENTS, VARIANTS. For CLAS: omit include to get the full class source (definition + implementation combined). The include param is optional — use it only to read class-local sections: definitions (local types), implementations (local helper classes), macros, testclasses (ABAP Unit). For CLAS with method param: use method="*" to list all methods with signatures and visibility, or method="method_name" to read a single method implementation (95% fewer tokens than full source). For SOBJ: returns BOR method catalog; use method param to read a specific method implementation. BSP (deployed UI5/Fiori apps — list apps, browse files, read content; use name to browse app structure, include for subfolder or file), BSP_DEPLOY (query deployed UI5 apps via ABAP Repository OData Service — returns name, package, description). API_STATE (API release state — checks if an object is released for ABAP Cloud / S/4HANA Clean Core; returns contract states C0-C4, successor info; use objectType param for non-class objects). INACTIVE_OBJECTS (list all objects pending activation — no name param needed; use before SAPActivate batch_activate to see what needs activating). AUTH (Authorization Fields — returns check table, domain, conversion exit, org-level flags; on-prem only). FEATURE_TOGGLE (Feature Toggles — returns current toggle state per system from SAP switch framework; on-prem only). ENHO (Enhancement Implementations / BAdI — returns technology type, referenced enhancement object, and BAdI implementations with implementing classes; on-prem only). VERSIONS (list revision history of an object — returns JSON with object metadata and revisions [{id, author, timestamp, versionTitle?, transport?, uri}]; pass optional include for CLAS or group for FUNC; on-prem only and may return 404 for some DDIC types on non-S/4 backends). VERSION_SOURCE (fetch source at a specific revision URI from VERSIONS response; returns raw source text; on-prem only). ' +
60
61
  'Optional grep parameter: pass a case-insensitive regex to return only matching source lines (+context, with line numbers) instead of the full object — token-efficient search across source-bearing types; for CLAS, matches are annotated with the owning class/method. ' +
61
62
  'Optional version parameter (default "active"): set to "inactive" to read the user\'s unactivated draft, or "auto" for the developer view. Active reads include a note when an inactive draft exists.';
62
- const SAPREAD_DESC_BTP = 'Read SAP ABAP objects (BTP ABAP Environment). Types: CLAS, INTF, FUNC (released/custom only), FUGR (released/custom only), DDLS (CDS views — primary data model on BTP), DCLS (CDS access controls), DDLX (CDS metadata extensions — UI annotations for Fiori Elements), BDEF (RAP behavior definitions), SRVD (service definitions), SRVB (service bindings — returns structured binding info: OData version, publish status, service definition ref), SKTD (Knowledge Transfer Documents — Markdown documentation attached to ABAP objects like CDS views, BDEFs, classes), TABL (DDIC TABL — covers both custom transparent tables AND DDIC structures; returns CDS-like source. ARC-1 auto-resolves /tables/ vs /structures/ via fallback. Note: there is no separate STRU type — TABL is the canonical short type for both), DOMA (DDIC domains — type info, value table, fixed values), DTEL (data elements — domain, labels, search help), TABLE_CONTENTS (custom tables and released CDS only — SAP standard tables are blocked; no filter or single-column filter only), TABLE_QUERY (structured multi-column query on custom DDIC tables and released CDS views; use when filtering on multiple fields. Requires SAP_BASIS 752+ for CDS view support), DEVC, SYSTEM, COMPONENTS, MSAG (custom message classes only). For CLAS: omit include to get the full class source. The include param reads class-local sections: definitions, implementations, macros, testclasses. For CLAS with method param: use method="*" to list all methods with signatures and visibility, or method="method_name" to read a single method (95% fewer tokens). Note: PROG, INCL, VIEW, TRAN, TEXT_ELEMENTS, VARIANTS are not available on BTP — use CLAS with IF_OO_ADT_CLASSRUN for console applications, and DDLS for data models instead of classic views. VERSIONS and VERSION_SOURCE are currently on-prem only in ARC-1 and are intentionally not exposed on BTP yet. BSP (deployed UI5/Fiori apps — list apps, browse files, read content; use name to browse app structure, include for subfolder or file), BSP_DEPLOY (query deployed UI5 apps via ABAP Repository OData Service — returns name, package, description). API_STATE (API release state — checks if an object is released for ABAP Cloud / Clean Core; returns contract states C0-C4, successor info; essential for cloud development; use objectType param for non-class objects). INACTIVE_OBJECTS (list all objects pending activation — no name param needed; use before SAPActivate batch_activate to see what needs activating). ' +
63
+ const SAPREAD_DESC_BTP = 'Read SAP ABAP objects (BTP ABAP Environment). Use SAPRead when you need exact raw source, a specific method body, grep output, inactive drafts, or metadata. For "what does this object do?", object explanation, spec work, reviews, or pre-change orientation, prefer SAPContext first because it returns intent-level context before raw source. Types: CLAS, INTF, FUNC (released/custom only), FUGR (released/custom only), DDLS (CDS views — primary data model on BTP), DCLS (CDS access controls), DDLX (CDS metadata extensions — UI annotations for Fiori Elements), BDEF (RAP behavior definitions), SRVD (service definitions), SRVB (service bindings — returns structured binding info: OData version, publish status, service definition ref), SKTD/KTD (Knowledge Transfer Documents — Markdown documentation attached to KTD-capable ABAP objects like DDLS, BDEF, SRVD, SRVB, and packages; KTD is a friendly alias for SKTD), TABL (DDIC TABL — covers both custom transparent tables AND DDIC structures; returns CDS-like source. ARC-1 auto-resolves /tables/ vs /structures/ via fallback. Note: there is no separate STRU type — TABL is the canonical short type for both), DOMA (DDIC domains — type info, value table, fixed values), DTEL (data elements — domain, labels, search help), TABLE_CONTENTS (custom tables and released CDS only — SAP standard tables are blocked; no filter or single-column filter only), TABLE_QUERY (structured multi-column query on custom DDIC tables and released CDS views; use when filtering on multiple fields. Requires SAP_BASIS 752+ for CDS view support), DEVC, SYSTEM, COMPONENTS, MSAG (custom message classes only). For CLAS: omit include to get the full class source. The include param reads class-local sections: definitions, implementations, macros, testclasses. For CLAS with method param: use method="*" to list all methods with signatures and visibility, or method="method_name" to read a single method (95% fewer tokens). Note: PROG, INCL, VIEW, TRAN, TEXT_ELEMENTS, VARIANTS are not available on BTP — use CLAS with IF_OO_ADT_CLASSRUN for console applications, and DDLS for data models instead of classic views. VERSIONS and VERSION_SOURCE are currently on-prem only in ARC-1 and are intentionally not exposed on BTP yet. BSP (deployed UI5/Fiori apps — list apps, browse files, read content; use name to browse app structure, include for subfolder or file), BSP_DEPLOY (query deployed UI5 apps via ABAP Repository OData Service — returns name, package, description). API_STATE (API release state — checks if an object is released for ABAP Cloud / Clean Core; returns contract states C0-C4, successor info; essential for cloud development; use objectType param for non-class objects). INACTIVE_OBJECTS (list all objects pending activation — no name param needed; use before SAPActivate batch_activate to see what needs activating). ' +
63
64
  'Optional grep parameter: pass a case-insensitive regex to return only matching source lines (+context, with line numbers) instead of the full object — token-efficient search across source-bearing types; for CLAS, matches are annotated with the owning class/method. ' +
64
65
  'Optional version parameter (default "active"): set to "inactive" to read the user\'s unactivated draft, or "auto" for the developer view. Active reads include a note when an inactive draft exists.';
65
66
  // ─── SAPWrite Types ─────────────────────────────────────────────────
66
- const SAPWRITE_DESC_ONPREM = 'Create or update ABAP source code and DDIC metadata. Handles lock/modify/unlock automatically. Supports PROG, CLAS, INTF, FUNC, FUGR, INCL, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD, TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. ' +
67
+ const SAPWRITE_DESC_ONPREM = 'Create or update ABAP source code and DDIC metadata. Handles lock/modify/unlock automatically. Supports PROG, CLAS, INTF, FUNC, FUGR, INCL, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD/KTD, TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. ' +
67
68
  'Type codes are auto-normalized and case-insensitive (e.g., "CLAS/OC" → "CLAS"). ' +
68
69
  'For delete, only type and name are required (plus optional transport); other fields are ignored. ' +
69
70
  'Optional fields may be omitted entirely — do not send empty strings or null to "skip" a field; irrelevant ones are ignored. ' +
@@ -74,7 +75,7 @@ const SAPWRITE_DESC_ONPREM = 'Create or update ABAP source code and DDIC metadat
74
75
  'MSAG (message classes) use metadata XML writes: provide "messages" array with {number, shortText} entries. Create empty then update, or provide messages at creation. ' +
75
76
  'SRVB (service bindings) use metadata XML writes: provide serviceDefinition (SRVD name), odataVersion ("V2"/"V4"), optional category (0=UI, 1=Web API). ' +
76
77
  'bindingType accepts human-readable values like "ODataV4-UI" which are auto-normalized. ' +
77
- 'SKTD (Knowledge Transfer Documents, Markdown docs attached to an ABAP object): create requires refObjectType (parent ADT type+subtype, e.g., "DDLS/DF"). A KTD inherits the name of the object it documents — so "name" MUST equal the parent object name (one KTD per object; refObjectName defaults to name and cannot differ). Update takes Markdown in "source"; delete uses the ADT deletion framework (two-step check/delete). Follow creates/updates with SAPActivate(type="SKTD", name="..."). ' +
78
+ 'SKTD/KTD (Knowledge Transfer Documents, Markdown docs attached to a KTD-capable ABAP object; KTD is a friendly alias for SKTD): create requires refObjectType (parent ADT type+subtype, e.g., "DDLS/DF", "BDEF/BDO", "SRVD/SRV", "SRVB/SVB", "DEVC/K"). Do not use CLAS/OC, INTF/OI, or PROG/P; use ABAP Doc for code objects. A KTD inherits the name of the object it documents — so "name" MUST equal the parent object name (one KTD per object; refObjectName defaults to name and cannot differ). Update takes Markdown in "source"; delete uses the ADT deletion framework (two-step check/delete). Follow creates/updates with SAPActivate(type="SKTD", name="..."). ' +
78
79
  'FUGR (function groups): create with package; serves as the parent container for FUNC. Delete the FUGR after deleting all its FMs. ' +
79
80
  'FUNC (function modules): require "group" parameter — the parent FUGR must exist (create it first via SAPWrite type=FUGR). Pass structured `parameters` array to manage FM signatures (IMPORTING/EXPORTING/CHANGING/TABLES/EXCEPTIONS/RAISING). Example: parameters=[{kind:"importing",name:"IV_X",type:"STRING",byValue:true},{kind:"exporting",name:"EV_Y",type:"STRING",byValue:true},{kind:"raising",name:"CX_ROOT"}]. Use SAPRead(type=FUNC, includeSignature=true) to read parameters back as structured JSON. SAPGUI-style *"...IMPORTING..."* parameter comment blocks in source are stripped before PUT as defense-in-depth (SAP rejects them with FUNC_ADT028); a warning is appended in that case. ' +
80
81
  'For edit_method: surgically replace a single method body in a CLAS without sending the full class source. ' +
@@ -86,7 +87,7 @@ const SAPWRITE_DESC_ONPREM = 'Create or update ABAP source code and DDIC metadat
86
87
  'For scaffold_rap_handlers: derive missing RAP behavior handler signatures from an interface BDEF and optionally create missing lhc_* skeletons plus inject declarations and empty implementation stubs into an existing behavior pool class. ' +
87
88
  'For generate_behavior_implementation: one-shot RAP behavior pool — auto-discover the bound BDEF via class metadata (rootEntityRef), scaffold every required handler (creating lhc_<alias> skeletons when missing), write under one lock, and (by default) activate. Reliable equivalent of Eclipse ADT\'s "Generate Behavior Implementation" Cmd+1 quickfix without the broken /sap/bc/adt/quickfixes/proposals/.../create_class_implementation server endpoint. ' +
88
89
  'Server-driven objects (ABAP Platform 2025 / SAP_BASIS 8.16+, discovery-gated): DESD (CDS Logical External Schema), DTSC (CDS Static Cache), CSNM (CSN Model), EVTB (RAP Event Binding), EVTO (RAP Event Object), COTA (Communication Target). For these, create/update/delete operate on the generic AFF blue:blueSource object — pass the AFF JSON in "source" (e.g. {"formatVersion":"1","header":{...}}); create leaves the object inactive, so follow with SAPActivate. On pre-8.16 systems these types return a clean "requires SAP_BASIS 8.16+" error.';
89
- const SAPWRITE_DESC_BTP = 'Create or update ABAP source code and DDIC metadata (BTP ABAP Environment). Handles lock/modify/unlock automatically. Supports CLAS, INTF, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD, TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. ' +
90
+ const SAPWRITE_DESC_BTP = 'Create or update ABAP source code and DDIC metadata (BTP ABAP Environment). Handles lock/modify/unlock automatically. Supports CLAS, INTF, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD/KTD, TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. ' +
90
91
  'Type codes are auto-normalized and case-insensitive (e.g., "CLAS/OC" → "CLAS"). ' +
91
92
  'For delete, only type and name are required (plus optional transport); other fields are ignored. ' +
92
93
  'Optional fields may be omitted entirely — do not send empty strings or null to "skip" a field; irrelevant ones are ignored. ' +
@@ -96,7 +97,7 @@ const SAPWRITE_DESC_BTP = 'Create or update ABAP source code and DDIC metadata (
96
97
  'MSAG (message classes) use metadata XML writes: provide "messages" array with {number, shortText} entries. ' +
97
98
  'SRVB (service bindings) use metadata XML writes: provide serviceDefinition (SRVD name), odataVersion ("V2"/"V4"), optional category (0=UI, 1=Web API). ' +
98
99
  'bindingType accepts human-readable values like "ODataV4-UI" which are auto-normalized. ' +
99
- 'SKTD (Knowledge Transfer Documents, Markdown docs attached to an ABAP object): create requires refObjectType (parent ADT type+subtype, e.g., "DDLS/DF"). A KTD inherits the name of the object it documents — so "name" MUST equal the parent object name (one KTD per object; refObjectName defaults to name and cannot differ). Update takes Markdown in "source"; delete uses the ADT deletion framework (two-step check/delete). Follow creates/updates with SAPActivate(type="SKTD", name="..."). ' +
100
+ 'SKTD/KTD (Knowledge Transfer Documents, Markdown docs attached to a KTD-capable ABAP object; KTD is a friendly alias for SKTD): create requires refObjectType (parent ADT type+subtype, e.g., "DDLS/DF", "BDEF/BDO", "SRVD/SRV", "SRVB/SVB", "DEVC/K"). Do not use CLAS/OC, INTF/OI, or PROG/P; use ABAP Doc for code objects. A KTD inherits the name of the object it documents — so "name" MUST equal the parent object name (one KTD per object; refObjectName defaults to name and cannot differ). Update takes Markdown in "source"; delete uses the ADT deletion framework (two-step check/delete). Follow creates/updates with SAPActivate(type="SKTD", name="..."). ' +
100
101
  'Must use ABAP Cloud language version (no classic statements). Only Z*/Y* namespace allowed on BTP. ' +
101
102
  'For edit_method: surgically replace a single method body in a CLAS without sending the full class source. ' +
102
103
  'For local handler classes inside a class include (RAP behavior pools, local helpers, test classes), pass the qualified specifier "lhc_project~approve_project" — ARC-1 routes the read+write to /includes/implementations automatically. ' +
@@ -116,13 +117,14 @@ const SAPWRITE_MINIMAL_PAYLOAD_GUIDE = 'MINIMAL PAYLOAD — send ONLY the fields
116
117
  "delete needs only {action, type, name}; DOMA/DTEL/MSAG/SRVB need {action, type, name} plus that type's own DDIC fields; FUNC also needs group. " +
117
118
  'Do NOT send `include` unless type=CLAS, and do NOT send DDIC/metadata fields (dataType, length, decimals, signExists, lowercase, typeKind, domainName, odataVersion, category, version, labels, …) on a source-object or delete call. ';
118
119
  // ─── SAPContext Types ───────────────────────────────────────────────
119
- const SAPCONTEXT_DESC_ONPREM = 'Get compressed dependency context or CDS blast-radius impact for an ABAP / CDS object.\n\n' +
120
+ const SAPCONTEXT_DESC_ONPREM = 'Primary tool for understanding ABAP objects before specs, reviews, explanations, or changes. Use SAPContext instead of SAPRead when the user asks what a class, interface, program, function module, or CDS view does. For action="deps" it returns intent/context first: the object KTD when available, then compressed dependency contracts. Use SAPRead later only for exact source, method bodies, grep, drafts, revisions, or metadata.\n\n' +
121
+ 'Get compressed dependency context or CDS blast-radius impact for an ABAP / CDS object.\n\n' +
120
122
  "Decision rule — pick the action based on the user's question:\n" +
121
123
  '- "What breaks if I change <CDS view>?" / "Who consumes <I_*>?" / "Impact analysis on <DDLS>" / "Blast radius" → action="impact"\n' +
122
- '- "Understand dependencies before editing <object>" / "What does X depend on?" → action="deps" (default)\n' +
124
+ '- "What does <object> do?" / "Explain <object>" / "Prepare a spec/change/review for <object>" / "Understand dependencies before editing <object>" / "What does X depend on?" → action="deps" (default)\n' +
123
125
  '- "Find all callers of <object>" (cache-warmup required) → action="usages"\n\n' +
124
126
  'action="impact" (CDS blast-radius, DDLS only): ALWAYS use this for CDS change-impact questions. Returns upstream AST dependencies plus downstream where-used results classified into RAP-aware buckets: projectionViews, bdefs, serviceDefinitions, serviceBindings, accessControls (DCLS), metadataExtensions (DDLX), abapConsumers, documentation (SKTD), tables, other. Also emits additive sibling-consistency diagnostics (consistencyHints + siblingExtensionAnalysis) when sibling DDLS variants in the same package show asymmetric metadata-extension coverage. DO NOT replicate this with SAPQuery against DDDDLSRC/ACMDCLSRC/DDLXSRC_SRC/SRVDSRC_SRC — those text scans produce noise (non-dependency matches, package group nodes) that this classifier already filters out. Optional includeIndirect=true widens to transitive consumers. Optional siblingCheck=false disables sibling analysis; siblingMaxCandidates controls fan-out (default 4, hard cap 10).\n\n' +
125
- 'action="deps" (default): Returns only the public API contracts (method signatures, interface definitions, type declarations) of all objects that the target depends on — NOT the full source code. The most token-efficient way to understand dependencies. Instead of N separate SAPRead calls returning full source (~200 lines each), returns ONE response with compressed contracts (~15-30 lines each). Typical compression: 7-30x fewer tokens.\n\n' +
127
+ 'action="deps" (default): Returns the target object KTD first when one exists, then only the public API contracts (method signatures, interface definitions, type declarations) of all objects that the target depends on — NOT the full source code. The most token-efficient way to understand an object before editing. Instead of N separate SAPRead calls returning full source (~200 lines each), returns ONE response with KTD context plus compressed contracts (~15-30 lines each). Typical compression: 7-30x fewer tokens.\n\n' +
126
128
  'What deps extracts per dependency:\n' +
127
129
  '- Classes: CLASS DEFINITION with PUBLIC SECTION only (methods, types, constants). PROTECTED, PRIVATE and IMPLEMENTATION stripped.\n' +
128
130
  '- Interfaces: Full interface definition (interfaces are already public contracts).\n' +
@@ -132,14 +134,15 @@ const SAPCONTEXT_DESC_ONPREM = 'Get compressed dependency context or CDS blast-r
132
134
  'provides the dependency graph and field catalogs needed for cl_cds_test_environment doubles.\n\n' +
133
135
  'Filtering (deps): SAP standard objects (CL_ABAP_*, IF_ABAP_*, CX_SY_*) are excluded. Custom objects (Z*, Y*) are prioritized.\n\n' +
134
136
  'Use SAPContext BEFORE writing code that modifies or extends existing objects. ' +
135
- 'Use SAPRead to get the full source of the target object, then SAPContext to understand its dependencies.\n\n' +
137
+ 'Use SAPRead after SAPContext when you need exact source or method-level detail.\n\n' +
136
138
  'For non-CDS reverse-lookup, use SAPNavigate(action="references"). For CDS reverse-lookup, ALWAYS prefer action="impact" over SAPNavigate — it returns the same where-used data pre-classified into RAP buckets.';
137
- const SAPCONTEXT_DESC_BTP = 'Get compressed dependency context or CDS blast-radius impact for an ABAP / CDS object (BTP ABAP Environment).\n\n' +
139
+ const SAPCONTEXT_DESC_BTP = 'Primary tool for understanding ABAP objects before specs, reviews, explanations, or changes (BTP ABAP Environment). Use SAPContext instead of SAPRead when the user asks what a class, interface, or CDS view does. For action="deps" it returns intent/context first: the object KTD when available, then compressed dependency contracts. Use SAPRead later only for exact source, method bodies, grep, drafts, or metadata.\n\n' +
140
+ 'Get compressed dependency context or CDS blast-radius impact for an ABAP / CDS object (BTP ABAP Environment).\n\n' +
138
141
  "Decision rule — pick the action based on the user's question:\n" +
139
142
  '- "What breaks if I change <CDS view>?" / "Who consumes <I_*>?" / "Impact analysis on <DDLS>" / "Blast radius" → action="impact"\n' +
140
- '- "Understand dependencies before editing <object>" / "What does X depend on?" → action="deps" (default)\n\n' +
143
+ '- "What does <object> do?" / "Explain <object>" / "Prepare a spec/change/review for <object>" / "Understand dependencies before editing <object>" / "What does X depend on?" → action="deps" (default)\n\n' +
141
144
  'action="impact" (CDS blast-radius, DDLS only): ALWAYS use this for CDS change-impact questions. Returns upstream AST dependencies plus downstream where-used results classified into RAP-aware buckets: projectionViews, bdefs, serviceDefinitions, serviceBindings, accessControls (DCLS), metadataExtensions (DDLX), abapConsumers, documentation (SKTD), tables, other. Also emits additive sibling-consistency diagnostics (consistencyHints + siblingExtensionAnalysis) when sibling DDLS variants in the same package show asymmetric metadata-extension coverage. DO NOT replicate this with SAPQuery — the classifier already filters noise. Optional includeIndirect=true widens to transitive consumers. Optional siblingCheck=false disables sibling analysis; siblingMaxCandidates controls fan-out (default 4, hard cap 10).\n\n' +
142
- 'action="deps" (default): Returns only the public API contracts (method signatures, interface definitions, type declarations) of all objects that the target depends on — NOT the full source code.\n\n' +
145
+ 'action="deps" (default): Returns the target object KTD first when one exists, then only the public API contracts (method signatures, interface definitions, type declarations) of all objects that the target depends on — NOT the full source code.\n\n' +
143
146
  'What deps extracts per dependency:\n' +
144
147
  '- Classes: CLASS DEFINITION with PUBLIC SECTION only (methods, types, constants).\n' +
145
148
  '- Interfaces: Full interface definition (interfaces are already public contracts).\n' +
@@ -147,7 +150,7 @@ const SAPCONTEXT_DESC_BTP = 'Get compressed dependency context or CDS blast-radi
147
150
  "Each dependency's full source is included. Essential for CDS unit test generation.\n\n" +
148
151
  'On BTP: released SAP objects (CL_ABAP_*, IF_ABAP_*) are included since they form the primary development API surface. ' +
149
152
  'Custom objects (Z*, Y*) are also included.\n\n' +
150
- 'Use SAPContext BEFORE writing code that modifies or extends existing objects.';
153
+ 'Use SAPContext BEFORE writing code that modifies or extends existing objects. Use SAPRead after SAPContext when you need exact source or method-level detail.';
151
154
  // ─── SAPQuery ───────────────────────────────────────────────────────
152
155
  const SAPQUERY_DESC_ONPREM = 'Execute ABAP SQL queries against SAP tables. Returns structured data with column names and rows. ' +
153
156
  'Powerful for reverse-engineering: query metadata tables like DD02L (table catalog), DD03L (field catalog), ' +
@@ -174,14 +177,14 @@ const SAPSEARCH_DESC_BTP = 'Search for ABAP objects, exact object-directory entr
174
177
  // ─── SAPTransport ───────────────────────────────────────────────────
175
178
  const SAPTRANSPORT_DESC_ONPREM = 'Manage CTS transport requests (SE09/SE10 equivalent). ' +
176
179
  'Actions: list (defaults to current user, modifiable transports — both Workbench and Customizing), ' +
177
- 'get (details with tasks and objects), create (K=Workbench, W=Customizing, T=Transport of Copies), ' +
180
+ 'get (details with tasks and objects), create (always a Workbench (K) request — the package/target sets the transport target & layer, not the request category; optional explicit target. Customizing (W) and Transport-of-Copies (T) requests are not created here), ' +
178
181
  'release, delete, remove_object (remove an object, keep the request), reassign (change owner), release_recursive (release tasks first, then parent), ' +
179
182
  'check (check if a package requires a transport — provide type, name, package), ' +
180
183
  'history (find transports referencing an object — provide type, name; read-only, works without SAP_ALLOW_TRANSPORT_WRITES). ' +
181
184
  'Transport IDs look like A4HK900123. Status: D=modifiable, R=released.';
182
185
  const SAPTRANSPORT_DESC_BTP = 'Manage transport requests (BTP ABAP Environment, SE09/SE10 equivalent). ' +
183
186
  'Actions: list (defaults to current user, modifiable transports — both Workbench and Customizing), ' +
184
- 'get (details with tasks and objects), create (K=Workbench, W=Customizing, T=Transport of Copies), ' +
187
+ 'get (details with tasks and objects), create (always a Workbench (K) request — the package/target sets the transport target & layer, not the request category; optional explicit target. Customizing (W) and Transport-of-Copies (T) requests are not created here), ' +
185
188
  'release, delete, remove_object (remove an object, keep the request), reassign (change owner), release_recursive (release tasks first, then parent), ' +
186
189
  'check (check if a package requires a transport — provide type, name, package), ' +
187
190
  'history (find transports referencing an object — provide type, name; read-only, works without SAP_ALLOW_TRANSPORT_WRITES). ' +
@@ -205,7 +208,9 @@ const SAPMANAGE_DESC_ONPREM = 'Probe and report SAP system capabilities. Use thi
205
208
  '- "flp_create_group": Create a group (requires "groupId", "title").\n' +
206
209
  '- "flp_create_tile": Create a tile in a catalog (requires "catalogId", "tile").\n' +
207
210
  '- "flp_add_tile_to_group": Add a catalog tile to a group (requires "groupId", "catalogId", "tileInstanceId").\n' +
208
- '- "flp_delete_catalog": Delete a business catalog (requires "catalogId").\n\n' +
211
+ '- "flp_delete_catalog": Delete a business catalog (requires "catalogId").\n' +
212
+ '- "set_api_state": Release (or revoke) an object\'s API release contract for ABAP Cloud / Clean Core ' +
213
+ '(requires "objectUri", or "name" + "objectType"; "apiState" defaults to RELEASED, "contract" defaults to C1 — pass C0 for SRVD, C3 for classic views). The write counterpart of SAPRead(type="API_STATE").\n\n' +
209
214
  'Returns JSON with features, each having: id, available (bool), mode, message, and probedAt timestamp. ' +
210
215
  'Also returns systemType ("btp" or "onprem") for understanding available capabilities. ' +
211
216
  '"available: false" means do NOT attempt operations that depend on it.';
@@ -217,7 +222,9 @@ const SAPMANAGE_DESC_BTP = 'Probe and report SAP system capabilities (BTP ABAP E
217
222
  '- "cache_stats": Show object cache health and warmup state.\n' +
218
223
  '- "create_package": Create a package (DEVC) via ADT packages API.\n' +
219
224
  '- "delete_package": Delete an existing package.\n' +
220
- '- FLP actions: flp_list_catalogs, flp_list_groups, flp_list_tiles, flp_create_catalog, flp_create_group, flp_create_tile, flp_add_tile_to_group, flp_delete_catalog.\n\n' +
225
+ '- FLP actions: flp_list_catalogs, flp_list_groups, flp_list_tiles, flp_create_catalog, flp_create_group, flp_create_tile, flp_add_tile_to_group, flp_delete_catalog.\n' +
226
+ '- "set_api_state": Release (or revoke) an object\'s API release contract for ABAP Cloud / Clean Core ' +
227
+ '(requires "objectUri", or "name" + "objectType"; "apiState" defaults to RELEASED, "contract" defaults to C1 — pass C0 for SRVD, C3 for classic views). The write counterpart of SAPRead(type="API_STATE").\n\n' +
221
228
  'Returns JSON with features and systemType="btp". On BTP, RAP/CDS and transports are always available. ' +
222
229
  'abapGit, AMDP, UI5/BSP, and FLP customization may not be available depending on the BTP ABAP configuration.';
223
230
  const SAPMANAGE_ACTIONS_READ = [
@@ -237,6 +244,7 @@ const SAPMANAGE_ACTIONS_WRITE = [
237
244
  'flp_create_tile',
238
245
  'flp_add_tile_to_group',
239
246
  'flp_delete_catalog',
247
+ 'set_api_state',
240
248
  ];
241
249
  const SAPTRANSPORT_ACTIONS_READ = ['list', 'get', 'check', 'history', 'layers', 'targets'];
242
250
  const SAPTRANSPORT_ACTIONS_WRITE = ['create', 'release', 'delete', 'remove_object', 'reassign', 'release_recursive'];
@@ -402,8 +410,8 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
402
410
  type: 'string',
403
411
  enum: btp ? SAPREAD_TYPES_BTP : SAPREAD_TYPES_ONPREM,
404
412
  description: btp
405
- ? 'Object type to read (BTP): CLAS, INTF, FUNC, FUGR, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD, TABL (transparent tables and DDIC structures), DOMA, DTEL, MSAG, TABLE_CONTENTS, TABLE_QUERY, DEVC, SYSTEM, COMPONENTS, BSP, BSP_DEPLOY, API_STATE, INACTIVE_OBJECTS. Server-driven objects (8.16+ / ABAP Cloud, discovery-gated, return JSON metadata + AFF JSON source): DESD (CDS Logical External Schema), EVTB (RAP Event Binding), EVTO (RAP Event Object), DTSC (CDS Static Cache), CSNM (Core Schema Notation Model), COTA (Communication Target). Deprecated alias: MESSAGES (use MSAG).'
406
- : 'Object type to read (on-prem): PROG, CLAS, INTF, FUNC, FUGR, INCL, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD, TABL (transparent tables and DDIC structures), VIEW, DOMA, DTEL, MSAG, TRAN, TABLE_CONTENTS, TABLE_QUERY, DEVC, SOBJ, SYSTEM, COMPONENTS, TEXT_ELEMENTS, VARIANTS, BSP, BSP_DEPLOY, API_STATE, INACTIVE_OBJECTS, AUTH, FEATURE_TOGGLE, ENHO, VERSIONS, VERSION_SOURCE. Server-driven objects (ABAP Platform 2025 / SAP_BASIS 8.16+, discovery-gated, return JSON metadata + AFF JSON source): DESD (CDS Logical External Schema), EVTB (RAP Event Binding), EVTO (RAP Event Object), DTSC (CDS Static Cache), CSNM (Core Schema Notation Model), COTA (Communication Target). Deprecated aliases: MESSAGES (use MSAG), FTG2 (use FEATURE_TOGGLE).',
413
+ ? 'Object type to read (BTP): CLAS, INTF, FUNC, FUGR, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD or KTD (Knowledge Transfer Documents), TABL (transparent tables and DDIC structures), DOMA, DTEL, MSAG, TABLE_CONTENTS, TABLE_QUERY, DEVC, SYSTEM, COMPONENTS, BSP, BSP_DEPLOY, API_STATE, INACTIVE_OBJECTS. Server-driven objects (8.16+ / ABAP Cloud, discovery-gated, return JSON metadata + AFF JSON source): DESD (CDS Logical External Schema), EVTB (RAP Event Binding), EVTO (RAP Event Object), DTSC (CDS Static Cache), CSNM (Core Schema Notation Model), COTA (Communication Target). Deprecated alias: MESSAGES (use MSAG).'
414
+ : 'Object type to read (on-prem): PROG, CLAS, INTF, FUNC, FUGR, INCL, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD or KTD (Knowledge Transfer Documents), TABL (transparent tables and DDIC structures), VIEW, DOMA, DTEL, MSAG, TRAN, TABLE_CONTENTS, TABLE_QUERY, DEVC, SOBJ, SYSTEM, COMPONENTS, TEXT_ELEMENTS, VARIANTS, BSP, BSP_DEPLOY, API_STATE, INACTIVE_OBJECTS, AUTH, FEATURE_TOGGLE, ENHO, VERSIONS, VERSION_SOURCE. Server-driven objects (ABAP Platform 2025 / SAP_BASIS 8.16+, discovery-gated, return JSON metadata + AFF JSON source): DESD (CDS Logical External Schema), EVTB (RAP Event Binding), EVTO (RAP Event Object), DTSC (CDS Static Cache), CSNM (Core Schema Notation Model), COTA (Communication Target). Deprecated aliases: MESSAGES (use MSAG), FTG2 (use FEATURE_TOGGLE).',
407
415
  },
408
416
  name: { type: 'string', description: 'Object name (e.g., ZTEST_PROGRAM, ZCL_ORDER, MARA)' },
409
417
  action: {
@@ -441,7 +449,7 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
441
449
  maxLength: MAX_GREP_PATTERN_LENGTH,
442
450
  description: 'Regex pattern (case-insensitive) to search within the object source. Returns only matching lines with 1-based line numbers and ±3 context lines, instead of the full source — token-efficient. ' +
443
451
  'For CLAS, matches are annotated with the owning class/method; combine with include= to scope a section, but do NOT combine with method= (use grep to find, then method= to read). ' +
444
- 'Works for source-bearing types (CLAS, INTF, DDLS, DCLS, BDEF, SRVD, SRVB, SKTD, DDLX, TABL' +
452
+ 'Works for source-bearing types (CLAS, INTF, DDLS, DCLS, BDEF, SRVD, SRVB, SKTD/KTD, DDLX, TABL' +
445
453
  (btp ? '' : ', PROG, FUNC, FUGR, INCL, VIEW') +
446
454
  '). Falls back to a literal search when the pattern is not valid regex.',
447
455
  },
@@ -556,8 +564,8 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
556
564
  type: 'string',
557
565
  enum: btp ? SAPWRITE_TYPES_BTP : SAPWRITE_TYPES_ONPREM,
558
566
  description: btp
559
- ? 'Object type (for create/update/delete/edit_method/edit_class_definition/add_method/edit_method_signature/delete_method/change_method_visibility). Supported on BTP: CLAS, INTF, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD, TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. Class-section surgery actions require type=CLAS. Server-driven objects (8.16+, discovery-gated): DESD, DTSC, CSNM, EVTB, EVTO, COTA — create/update/delete with AFF JSON in "source", then SAPActivate.'
560
- : 'Object type (for create/update/delete/edit_method/edit_class_definition/add_method/edit_method_signature/delete_method/change_method_visibility). Supported on-prem: PROG, CLAS, INTF, FUNC, FUGR, INCL, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD, TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. Class-section surgery actions require type=CLAS. Server-driven objects (8.16+, discovery-gated): DESD, DTSC, CSNM, EVTB, EVTO, COTA — create/update/delete with AFF JSON in "source", then SAPActivate.',
567
+ ? 'Object type (for create/update/delete/edit_method/edit_class_definition/add_method/edit_method_signature/delete_method/change_method_visibility). Supported on BTP: CLAS, INTF, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD or KTD (Knowledge Transfer Documents), TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. Class-section surgery actions require type=CLAS. Server-driven objects (8.16+, discovery-gated): DESD, DTSC, CSNM, EVTB, EVTO, COTA — create/update/delete with AFF JSON in "source", then SAPActivate.'
568
+ : 'Object type (for create/update/delete/edit_method/edit_class_definition/add_method/edit_method_signature/delete_method/change_method_visibility). Supported on-prem: PROG, CLAS, INTF, FUNC, FUGR, INCL, DDLS, DCLS, DDLX, BDEF, SRVD, SRVB, SKTD or KTD (Knowledge Transfer Documents), TABL, TABL/DT, TABL/DS, DOMA, DTEL, MSAG. Class-section surgery actions require type=CLAS. Server-driven objects (8.16+, discovery-gated): DESD, DTSC, CSNM, EVTB, EVTO, COTA — create/update/delete with AFF JSON in "source", then SAPActivate.',
561
569
  },
562
570
  name: {
563
571
  type: 'string',
@@ -626,6 +634,15 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
626
634
  description: 'For FUNC: parent function-group name. Required for FUNC create (the FUGR must already exist — create it first via SAPWrite type=FUGR). Auto-resolved via search for FUNC update/delete if omitted.',
627
635
  },
628
636
  dataType: { type: 'string', description: 'DOMA/DTEL: ABAP data type (e.g., CHAR, NUMC, DEC)' },
637
+ rowType: {
638
+ type: 'string',
639
+ description: 'TTYP create: the row type — a built-in ABAP type (STRING, I, …) or a DDIC structure/type name. Required for TTYP create.',
640
+ },
641
+ rowTypeKind: {
642
+ type: 'string',
643
+ enum: ['builtin', 'structure'],
644
+ description: 'TTYP create: row-type mode (auto-detected from rowType if omitted).',
645
+ },
629
646
  length: { type: 'number', description: 'DOMA/DTEL: data type length' },
630
647
  decimals: { type: 'number', description: 'DOMA/DTEL: decimal places' },
631
648
  outputLength: { type: 'number', description: 'DOMA: output length' },
@@ -733,15 +750,15 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
733
750
  },
734
751
  refObjectType: {
735
752
  type: 'string',
736
- description: 'SKTD create: ADT type+subtype of the parent object the KTD documents (e.g., "DDLS/DF", "CLAS/OC", "INTF/OI", "PROG/P", "BDEF/BDO", "SRVD/SRV"). Required for SKTD create.',
753
+ description: 'SKTD/KTD create: ADT type+subtype of the parent object the KTD documents (e.g., "DDLS/DF", "BDEF/BDO", "SRVD/SRV", "SRVB/SVB", "DEVC/K"). Do not use CLAS/OC, INTF/OI, or PROG/P; use ABAP Doc for code objects. Required for SKTD/KTD create.',
737
754
  },
738
755
  refObjectName: {
739
756
  type: 'string',
740
- description: 'SKTD create: name of the parent object the KTD documents (defaults to "name").',
757
+ description: 'SKTD/KTD create: name of the parent object the KTD documents (defaults to "name").',
741
758
  },
742
759
  refObjectDescription: {
743
760
  type: 'string',
744
- description: 'SKTD create: description of the parent object (shown in Eclipse tooltips).',
761
+ description: 'SKTD/KTD create: description of the parent object (shown in Eclipse tooltips).',
745
762
  },
746
763
  objects: {
747
764
  type: 'array',
@@ -765,6 +782,11 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
765
782
  description: 'Object-specific transport request. Overrides top-level transport for this item.',
766
783
  },
767
784
  dataType: { type: 'string', description: 'DOMA/DTEL: ABAP data type' },
785
+ rowType: {
786
+ type: 'string',
787
+ description: 'TTYP: row type (built-in ABAP type or DDIC structure/type name)',
788
+ },
789
+ rowTypeKind: { type: 'string', enum: ['builtin', 'structure'], description: 'TTYP: row-type mode' },
768
790
  length: { type: 'number', description: 'DOMA/DTEL: data type length' },
769
791
  decimals: { type: 'number', description: 'DOMA/DTEL: decimal places' },
770
792
  outputLength: { type: 'number', description: 'DOMA: output length' },
@@ -988,9 +1010,17 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
988
1010
  '- "quickfix": Get SAP quick fix proposals for a specific source position. Requires name + type + source + line. Optional: column, sourceUri for exact ADT include/source targets.\n' +
989
1011
  '- "apply_quickfix": Apply one quick fix proposal and return text deltas (does not write source). Requires name + type + source + line + proposalUri + proposalUserContent. Optional: column, sourceUri, proposalAffectedObjects. proposalUserContent may be an empty string; pass it through exactly from quickfix.\n' +
990
1012
  '- "dumps": List or read ABAP short dumps (ST22). Without id: lists recent dumps (filter by user, maxResults). With id: returns focused chapter sections by default; set includeFullText=true to include the full formatted dump blob. Optional sections=[kap0,kap3,...] to request specific chapter IDs.\n' +
991
- '- "traces": List or analyze ABAP profiler traces. Without id: lists trace files. With id + analysis: returns trace analysis (hitlist = hot spots, statements = call tree, dbAccesses = database access statistics).\n\n' +
1013
+ '- "traces": List or analyze ABAP profiler traces. Without id: lists recorded trace files. With id + analysis: returns trace analysis (hitlist = hot spots, statements = call tree, dbAccesses = database access statistics).\n' +
1014
+ '- "trace_start": ARM an ABAP profiler trace so the NEXT matching execution is recorded — for debugging a slow OData/Gateway call or report. Defaults: trace the next HTTP/URL request by the connected user with SQL tracing on. Then reproduce the slow action and read it via action="traces" with the returned id (analysis="dbAccesses" shows which tables/joins dominate). Optional: traceUser, processType (any/http/dialog/batch/rfc; default http), objectType (default = the valid type for the process type, e.g. url for http), maxExecutions (default 1), expiresHours (default 24), sqlTrace (default true), aggregate (default true), description. Write scope (mutates server state).\n' +
1015
+ '- "trace_requests": List armed (not-yet-consumed) trace requests for a user (default the connected user) — to confirm a request is armed or find a stale one to cancel.\n' +
1016
+ '- "trace_cancel": Cancel an armed trace request by id (from trace_start or trace_requests). Write scope.\n\n' +
992
1017
  '- "system_messages": List SM02 system messages via ADT feed (filter by user, maxResults, from, to).\n' +
993
- '- "gateway_errors": List SAP Gateway error log entries (/IWFND/ERROR_LOG, on-prem). For detail mode provide detailUrl (preferred) or id+errorType.\n\n' +
1018
+ '- "gateway_errors": List SAP Gateway error log entries (/IWFND/ERROR_LOG, on-prem). For detail mode provide detailUrl (preferred) or id+errorType.\n' +
1019
+ '- "odata_perf": Diagnose WHY a Fiori/OData request is slow. Requires url (the host-relative OData path from the app\'s Network tab). ARC-1 GETs it with ?sap-statistics=true and a wall-clock timer, then returns the server-side timing split (gwtotal, gwapp, gwappdb=DB time, gwfw=framework, icfauth=auth) plus a verdict routing you to the dominant cost (DB vs ABAP/SADL vs framework vs auth). Read-only GET; gated like data preview.\n' +
1020
+ '- "cds_sql": Show the native SQL a CDS view compiles to (ADT "Show SQL Create Statement"). Requires name (the CDS DDL source / DDLS, e.g. "I_CURRENCY"). Returns the CREATE VIEW statement(s) so you can see the joins/scans behind a slow entity. Read-only; may be unavailable on older releases (e.g. NW 7.50).\n' +
1021
+ '- "sql_trace_state": Read the current ST05 trace state (SQL/buffer/enqueue/RFC/HTTP/… on-off per app server + filters). Read-only.\n' +
1022
+ '- "set_sql_trace_state": Arm or disarm the ST05 SQL trace. Requires sqlOn (true=arm, false=disarm); optional user filters the trace to one SAP user. Workflow: arm → reproduce the slow request → sql_trace_directory for the record link. Needs SAP_ALLOW_WRITES (mutates server trace state).\n' +
1023
+ '- "sql_trace_directory": Return where the recorded SQL statements are read — SAP answers with the TMC "SQL Trace Analysis" deep-link (there is no ADT SQL-record API; open the URL in a browser, needs /sap/bc/stmc active). Read-only.\n\n' +
994
1024
  'Quickfix workflow: run syntax/ATC first to identify issues and line positions, then call quickfix to retrieve SAP-verified proposals, then apply_quickfix to get exact text deltas, and finally write the updated source via SAPWrite.',
995
1025
  inputSchema: {
996
1026
  type: 'object',
@@ -1004,17 +1034,29 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
1004
1034
  'cds_testcases',
1005
1035
  'dumps',
1006
1036
  'traces',
1037
+ 'trace_start',
1038
+ 'trace_requests',
1039
+ 'trace_cancel',
1007
1040
  'system_messages',
1008
1041
  'gateway_errors',
1009
1042
  'object_state',
1010
1043
  'quickfix',
1011
1044
  'apply_quickfix',
1045
+ 'odata_perf',
1046
+ 'cds_sql',
1047
+ 'sql_trace_state',
1048
+ 'set_sql_trace_state',
1049
+ 'sql_trace_directory',
1012
1050
  ],
1013
1051
  description: 'Diagnostic action',
1014
1052
  },
1015
1053
  name: {
1016
1054
  type: 'string',
1017
- description: 'Object name (for syntax/unittest/atc/object_state); the CDS entity / DDLS source name for cds_testcases',
1055
+ description: 'Object name (for syntax/unittest/atc/object_state); the CDS entity / DDLS source name for cds_testcases and cds_sql',
1056
+ },
1057
+ url: {
1058
+ type: 'string',
1059
+ description: 'For action="odata_perf": the host-relative OData path to probe, copied from the Fiori app\'s Network tab (e.g. "/sap/opu/odata4/sap/.../Entity?$filter=..." or "/sap/opu/odata/sap/<SRV>/<EntitySet>?$top=20"). Must be a path on the SAP system ARC-1 connects to — absolute URLs are rejected.',
1018
1060
  },
1019
1061
  type: {
1020
1062
  type: 'string',
@@ -1067,7 +1109,7 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
1067
1109
  variant: { type: 'string', description: 'ATC check variant (for atc action)' },
1068
1110
  id: {
1069
1111
  type: 'string',
1070
- description: 'Dump or trace ID (for dumps/traces actions). Omit to list, provide to get details.',
1112
+ description: 'Dump or trace ID (for dumps/traces actions); also the trace-request id to cancel (for trace_cancel). Omit to list, provide to get details.',
1071
1113
  },
1072
1114
  detailUrl: {
1073
1115
  type: 'string',
@@ -1099,11 +1141,53 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
1099
1141
  type: 'boolean',
1100
1142
  description: 'For dumps detail mode only: include full formattedText blob. Default false to reduce token usage.',
1101
1143
  },
1144
+ coverage: {
1145
+ type: 'boolean',
1146
+ description: 'For action="unittest": also return statement/branch/procedure coverage for the object, plus methodsBelowFull — the methods below 100% statement coverage, worst first (what to test next) — in one extra round-trip. If the coverage endpoint or measurement is unavailable, returns the tests without coverage. Default false.',
1147
+ },
1148
+ sqlOn: {
1149
+ type: 'boolean',
1150
+ description: 'For action="set_sql_trace_state": true to arm the ST05 SQL trace, false to disarm. Combine with user to filter the trace to one SAP user.',
1151
+ },
1102
1152
  analysis: {
1103
1153
  type: 'string',
1104
1154
  enum: ['hitlist', 'statements', 'dbAccesses'],
1105
1155
  description: 'Trace analysis type (for traces action with id). hitlist = execution hot spots, statements = call tree, dbAccesses = database access stats.',
1106
1156
  },
1157
+ traceUser: {
1158
+ type: 'string',
1159
+ description: 'For trace_start/trace_requests: the SAP user whose matching execution is traced/listed. Defaults to the connected user.',
1160
+ },
1161
+ processType: {
1162
+ type: 'string',
1163
+ enum: ['any', 'http', 'dialog', 'batch', 'rfc'],
1164
+ description: 'For trace_start: the kind of work process to capture. Default "http" (OData/Gateway). dialog = SAP GUI transaction, batch = background job, rfc = RFC call.',
1165
+ },
1166
+ objectType: {
1167
+ type: 'string',
1168
+ enum: ['any', 'url', 'transaction', 'report', 'functionModule'],
1169
+ description: 'For trace_start: what to match within the process. Defaults to the valid type for the process type (http→url, dialog→transaction, batch→report, rfc→functionModule).',
1170
+ },
1171
+ maxExecutions: {
1172
+ type: 'number',
1173
+ description: 'For trace_start: how many matching executions to capture before the request is consumed (default 1).',
1174
+ },
1175
+ expiresHours: {
1176
+ type: 'number',
1177
+ description: 'For trace_start: hours until the armed request auto-expires (default 24).',
1178
+ },
1179
+ sqlTrace: {
1180
+ type: 'boolean',
1181
+ description: 'For trace_start: capture SQL/DB accesses (default true — required for analysis="dbAccesses").',
1182
+ },
1183
+ aggregate: {
1184
+ type: 'boolean',
1185
+ description: 'For trace_start: aggregate the trace (default true).',
1186
+ },
1187
+ description: {
1188
+ type: 'string',
1189
+ description: 'For trace_start: optional label for the trace request.',
1190
+ },
1107
1191
  },
1108
1192
  required: ['action'],
1109
1193
  },
@@ -1120,7 +1204,7 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
1120
1204
  enum: ['impact', 'deps', 'usages'],
1121
1205
  description: 'Action:\n' +
1122
1206
  '"impact" = CDS blast-radius analysis (DDLS only). USE THIS for any question like "what breaks if I change <view>", "who consumes <I_*>", "impact analysis on <CDS>", "downstream of <view>". Returns upstream AST dependencies + downstream where-used classified into RAP buckets (projectionViews, bdefs, serviceDefinitions, serviceBindings, accessControls, metadataExtensions, abapConsumers, documentation, tables, other), plus additive sibling-consistency diagnostics (consistencyHints + siblingExtensionAnalysis) when related DDLS siblings show asymmetric DDLX coverage. ALWAYS prefer over SAPQuery against DDDDLSRC/ACMDCLSRC/DDLXSRC_SRC/SRVDSRC_SRC (those text-scans produce noise this classifier filters out). Non-DDLS input returns a guardrail error.\n' +
1123
- '"deps" (default, can be omitted) = forward dependency context — "what does <object> depend on?". Returns public API contracts of dependencies.\n' +
1207
+ '"deps" (default, can be omitted) = object understanding / forward dependency context — "what does <object> do?" or "what does <object> depend on?". Returns the object KTD when available plus public API contracts of dependencies.\n' +
1124
1208
  '"usages" = reverse dependency lookup — "who calls <object>?". Requires cache warmup (--cache-warmup). Only "name" is needed. For CDS entities prefer action="impact" instead.',
1125
1209
  },
1126
1210
  type: {
@@ -1167,6 +1251,10 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
1167
1251
  type: 'number',
1168
1252
  description: 'Only for action="impact". Maximum sibling DDLS candidates to compare. Default 4; hard cap 10.',
1169
1253
  },
1254
+ includeKtd: {
1255
+ type: 'boolean',
1256
+ description: 'Only for action="deps". When true/default, prepend the object Knowledge Transfer Document (KTD/SKTD) when one exists. Set false to skip the KTD lookup.',
1257
+ },
1170
1258
  },
1171
1259
  required: ['name'],
1172
1260
  },
@@ -1222,11 +1310,21 @@ export function getToolDefinitions(config, textSearchAvailable, resolvedFeatures
1222
1310
  },
1223
1311
  objectUri: {
1224
1312
  type: 'string',
1225
- description: 'ADT URI of the object to move (e.g., /sap/bc/adt/oo/classes/zcl_my_class). If not provided, resolved automatically from objectName + objectType via search.',
1313
+ description: 'ADT URI of the object to move (e.g., /sap/bc/adt/oo/classes/zcl_my_class). If not provided, resolved automatically from objectName + objectType via search. For set_api_state: the object whose API release contract to set (or pass name + objectType instead).',
1226
1314
  },
1227
1315
  objectType: {
1228
1316
  type: 'string',
1229
- description: 'ADT object type (e.g., CLAS/OC, DDLS/DF, PROG/P). Required for change_package.',
1317
+ description: 'ADT object type (e.g., CLAS/OC, DDLS/DF, PROG/P). Required for change_package. For set_api_state: object type of "name" when objectUri is omitted (e.g. CLAS, INTF, DDLS, TABL).',
1318
+ },
1319
+ apiState: {
1320
+ type: 'string',
1321
+ enum: ['RELEASED', 'NOT_RELEASED'],
1322
+ description: 'For set_api_state: target state of the object\'s API release contract — RELEASED (mark released for ABAP Cloud / Clean Core) or NOT_RELEASED (revoke). Default RELEASED. Visibility (ABAP Cloud / Key User Apps) follows the contract\'s defaults. Read the current state first with SAPRead(type="API_STATE").',
1323
+ },
1324
+ contract: {
1325
+ type: 'string',
1326
+ enum: ['C0', 'C1', 'C2', 'C3', 'C4'],
1327
+ description: 'For set_api_state: which release contract to set. Default C1 (Key-User/Cloud — the common clean-core contract). Object types support different contracts: e.g. service definitions (SRVD) only support C0, classic DDIC views only C3, behavior definitions and tables support C0+C1. If the object does not support the chosen contract, the error lists the ones it does.',
1230
1328
  },
1231
1329
  objectName: {
1232
1330
  type: 'string',