@mcp-abap-adt/core 2.0.1 → 2.1.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/CHANGELOG.md +19 -0
- package/dist/handlers/system/readonly/handleGetWhereUsed.d.ts +12 -7
- package/dist/handlers/system/readonly/handleGetWhereUsed.d.ts.map +1 -1
- package/dist/handlers/system/readonly/handleGetWhereUsed.js +20 -31
- package/dist/handlers/system/readonly/handleGetWhereUsed.js.map +1 -1
- package/package.json +2 -3
package/CHANGELOG.md
CHANGED
|
@@ -2,6 +2,25 @@
|
|
|
2
2
|
|
|
3
3
|
## [Unreleased]
|
|
4
4
|
|
|
5
|
+
## [2.1.0] - 2025-12-31
|
|
6
|
+
### Fixed
|
|
7
|
+
- Updated `@mcp-abap-adt/auth-broker` so installs now pull `0.2.17` instead of the stale `0.2.14` release that was hiding upstream fixes.
|
|
8
|
+
- Removed the accidental `@mcp-abap-adt/core` dependency that caused consumers to download the old `1.4.1` tarball.
|
|
9
|
+
|
|
10
|
+
## [2.0.3] - 2025-12-31
|
|
11
|
+
### Changed
|
|
12
|
+
- **@mcp-abap-adt/auth-broker**: bumped to `0.2.15` so the locked dependency pulls in the latest fixes referenced by the release.
|
|
13
|
+
|
|
14
|
+
### Fixed
|
|
15
|
+
- **CI workflow package install**: `.github/workflows/ci.yml` now looks for `mcp-abap-adt-core-*.tgz`, matching the actual npm pack output before testing global install.
|
|
16
|
+
|
|
17
|
+
## [2.0.2] - 2025-12-30
|
|
18
|
+
### Changed
|
|
19
|
+
- **GetWhereUsed handler**: Now uses `getWhereUsedList()` from adt-clients and returns parsed JSON with structured references instead of raw XML
|
|
20
|
+
|
|
21
|
+
### Fixed
|
|
22
|
+
- **Release workflow**: Simplified to use npm registry instead of uploading tgz artifacts
|
|
23
|
+
|
|
5
24
|
## [2.0.1] - 2025-12-30
|
|
6
25
|
### Documentation
|
|
7
26
|
- Added glama.ai badge with security/license/quality grades
|
|
@@ -1,12 +1,12 @@
|
|
|
1
1
|
/**
|
|
2
2
|
* WhereUsed handler using AdtClient utilities
|
|
3
3
|
* Endpoint: /sap/bc/adt/repository/informationsystem/usageReferences
|
|
4
|
-
* Uses
|
|
4
|
+
* Uses getWhereUsedList for parsed results
|
|
5
5
|
*/
|
|
6
6
|
import type { HandlerContext } from '../../../lib/handlers/interfaces';
|
|
7
7
|
export declare const TOOL_DEFINITION: {
|
|
8
8
|
readonly name: "GetWhereUsed";
|
|
9
|
-
readonly description: "[read-only] Retrieve where-used references for ABAP objects via ADT usageReferences.
|
|
9
|
+
readonly description: "[read-only] Retrieve where-used references for ABAP objects via ADT usageReferences. Returns parsed list of referencing objects with their types and packages.";
|
|
10
10
|
readonly inputSchema: {
|
|
11
11
|
readonly type: "object";
|
|
12
12
|
readonly properties: {
|
|
@@ -34,10 +34,7 @@ interface WhereUsedArgs {
|
|
|
34
34
|
}
|
|
35
35
|
/**
|
|
36
36
|
* Returns where-used references for ABAP objects using AdtClient utilities.
|
|
37
|
-
*
|
|
38
|
-
* Two-step workflow:
|
|
39
|
-
* 1. Fetch scope configuration (if enable_all_types is true)
|
|
40
|
-
* 2. Execute where-used search with scope
|
|
37
|
+
* Uses getWhereUsedList for parsed structured results.
|
|
41
38
|
*/
|
|
42
39
|
export declare function handleGetWhereUsed(context: HandlerContext, args: WhereUsedArgs): Promise<{
|
|
43
40
|
isError: boolean;
|
|
@@ -48,7 +45,15 @@ export declare function handleGetWhereUsed(context: HandlerContext, args: WhereU
|
|
|
48
45
|
object_type: string;
|
|
49
46
|
enable_all_types: boolean;
|
|
50
47
|
total_references: number;
|
|
51
|
-
|
|
48
|
+
result_description: string;
|
|
49
|
+
references: {
|
|
50
|
+
name: string;
|
|
51
|
+
type: string;
|
|
52
|
+
uri: string;
|
|
53
|
+
package_name: string | undefined;
|
|
54
|
+
responsible: string | undefined;
|
|
55
|
+
usage_information: string | undefined;
|
|
56
|
+
}[];
|
|
52
57
|
};
|
|
53
58
|
}[];
|
|
54
59
|
} | {
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"handleGetWhereUsed.d.ts","sourceRoot":"","sources":["../../../../src/handlers/system/readonly/handleGetWhereUsed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAGvE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;CAyBlB,CAAC;AAEX,UAAU,aAAa;IACrB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAED
|
|
1
|
+
{"version":3,"file":"handleGetWhereUsed.d.ts","sourceRoot":"","sources":["../../../../src/handlers/system/readonly/handleGetWhereUsed.ts"],"names":[],"mappings":"AAAA;;;;GAIG;AAIH,OAAO,KAAK,EAAE,cAAc,EAAE,MAAM,kCAAkC,CAAC;AAGvE,eAAO,MAAM,eAAe;;;;;;;;;;;;;;;;;;;;;;CAyBlB,CAAC;AAEX,UAAU,aAAa;IACrB,WAAW,EAAE,MAAM,CAAC;IACpB,WAAW,EAAE,MAAM,CAAC;IACpB,gBAAgB,CAAC,EAAE,OAAO,CAAC;CAC5B;AAED;;;GAGG;AACH,wBAAsB,kBAAkB,CACtC,OAAO,EAAE,cAAc,EACvB,IAAI,EAAE,aAAa;;;;;;;;;;;;;;;;;;;;;;;;;;GAyEpB"}
|
|
@@ -2,7 +2,7 @@
|
|
|
2
2
|
/**
|
|
3
3
|
* WhereUsed handler using AdtClient utilities
|
|
4
4
|
* Endpoint: /sap/bc/adt/repository/informationsystem/usageReferences
|
|
5
|
-
* Uses
|
|
5
|
+
* Uses getWhereUsedList for parsed results
|
|
6
6
|
*/
|
|
7
7
|
Object.defineProperty(exports, "__esModule", { value: true });
|
|
8
8
|
exports.TOOL_DEFINITION = void 0;
|
|
@@ -12,7 +12,7 @@ const getObjectsListCache_1 = require("../../../lib/getObjectsListCache");
|
|
|
12
12
|
const utils_1 = require("../../../lib/utils");
|
|
13
13
|
exports.TOOL_DEFINITION = {
|
|
14
14
|
name: 'GetWhereUsed',
|
|
15
|
-
description: '[read-only] Retrieve where-used references for ABAP objects via ADT usageReferences.
|
|
15
|
+
description: '[read-only] Retrieve where-used references for ABAP objects via ADT usageReferences. Returns parsed list of referencing objects with their types and packages.',
|
|
16
16
|
inputSchema: {
|
|
17
17
|
type: 'object',
|
|
18
18
|
properties: {
|
|
@@ -35,10 +35,7 @@ exports.TOOL_DEFINITION = {
|
|
|
35
35
|
};
|
|
36
36
|
/**
|
|
37
37
|
* Returns where-used references for ABAP objects using AdtClient utilities.
|
|
38
|
-
*
|
|
39
|
-
* Two-step workflow:
|
|
40
|
-
* 1. Fetch scope configuration (if enable_all_types is true)
|
|
41
|
-
* 2. Execute where-used search with scope
|
|
38
|
+
* Uses getWhereUsedList for parsed structured results.
|
|
42
39
|
*/
|
|
43
40
|
async function handleGetWhereUsed(context, args) {
|
|
44
41
|
const { connection, logger } = context;
|
|
@@ -55,36 +52,28 @@ async function handleGetWhereUsed(context, args) {
|
|
|
55
52
|
// Create AdtClient and get utilities
|
|
56
53
|
const client = new adt_clients_1.AdtClient(connection, logger);
|
|
57
54
|
const utils = client.getUtils();
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
if (typedArgs.enable_all_types === true) {
|
|
61
|
-
logger?.info('Fetching scope with all types enabled (Eclipse "select all" behavior)');
|
|
62
|
-
const scopeResponse = await utils.getWhereUsedScope({
|
|
63
|
-
object_name: typedArgs.object_name,
|
|
64
|
-
object_type: typedArgs.object_type,
|
|
65
|
-
});
|
|
66
|
-
// Modify scope to enable all types
|
|
67
|
-
scopeXml = utils.modifyWhereUsedScope(scopeResponse.data, {
|
|
68
|
-
enableAll: true,
|
|
69
|
-
});
|
|
70
|
-
}
|
|
71
|
-
// Step 2: Execute where-used search
|
|
72
|
-
// If scopeXml is undefined, getWhereUsed will auto-fetch default scope
|
|
73
|
-
const result = await utils.getWhereUsed({
|
|
55
|
+
// Use getWhereUsedList for parsed results
|
|
56
|
+
const result = await utils.getWhereUsedList({
|
|
74
57
|
object_name: typedArgs.object_name,
|
|
75
58
|
object_type: typedArgs.object_type,
|
|
76
|
-
|
|
59
|
+
enableAllTypes: typedArgs.enable_all_types,
|
|
77
60
|
});
|
|
78
|
-
logger?.debug(`Where-used search completed for ${typedArgs.object_type}/${typedArgs.object_name}`);
|
|
79
|
-
//
|
|
80
|
-
const numberOfResults = result.data?.match(/numberOfResults="(\d+)"/)?.[1] || '0';
|
|
81
|
-
// Format response
|
|
61
|
+
logger?.debug(`Where-used search completed for ${typedArgs.object_type}/${typedArgs.object_name}: ${result.totalReferences} references`);
|
|
62
|
+
// Format response with parsed data
|
|
82
63
|
const formattedResponse = {
|
|
83
|
-
object_name:
|
|
84
|
-
object_type:
|
|
64
|
+
object_name: result.objectName,
|
|
65
|
+
object_type: result.objectType,
|
|
85
66
|
enable_all_types: typedArgs.enable_all_types || false,
|
|
86
|
-
total_references:
|
|
87
|
-
|
|
67
|
+
total_references: result.totalReferences,
|
|
68
|
+
result_description: result.resultDescription,
|
|
69
|
+
references: result.references.map((ref) => ({
|
|
70
|
+
name: ref.name,
|
|
71
|
+
type: ref.type,
|
|
72
|
+
uri: ref.uri,
|
|
73
|
+
package_name: ref.packageName,
|
|
74
|
+
responsible: ref.responsible,
|
|
75
|
+
usage_information: ref.usageInformation,
|
|
76
|
+
})),
|
|
88
77
|
};
|
|
89
78
|
const mcpResult = {
|
|
90
79
|
isError: false,
|
|
@@ -1 +1 @@
|
|
|
1
|
-
{"version":3,"file":"handleGetWhereUsed.js","sourceRoot":"","sources":["../../../../src/handlers/system/readonly/handleGetWhereUsed.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;
|
|
1
|
+
{"version":3,"file":"handleGetWhereUsed.js","sourceRoot":"","sources":["../../../../src/handlers/system/readonly/handleGetWhereUsed.ts"],"names":[],"mappings":";AAAA;;;;GAIG;;;AA4CH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CAAC;QACvE,OAAO;YACL,OAAO,EAAE,IAAI;YACb,OAAO,EAAE;gBACP;oBACE,IAAI,EAAE,MAAM;oBACZ,IAAI,EAAE,cAAc,MAAM,CAAC,KAAK,CAAC,EAAE;iBACpC;aACF;SACF,CAAC;IACJ,CAAC;AACH,CAAC"}
|
package/package.json
CHANGED
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
{
|
|
2
2
|
"name": "@mcp-abap-adt/core",
|
|
3
|
-
"version": "2.0
|
|
3
|
+
"version": "2.1.0",
|
|
4
4
|
"main": "dist/index.js",
|
|
5
5
|
"types": "dist/index.d.ts",
|
|
6
6
|
"exports": {
|
|
@@ -118,11 +118,10 @@
|
|
|
118
118
|
},
|
|
119
119
|
"dependencies": {
|
|
120
120
|
"@mcp-abap-adt/adt-clients": "^0.3.13",
|
|
121
|
-
"@mcp-abap-adt/auth-broker": "^0.2.
|
|
121
|
+
"@mcp-abap-adt/auth-broker": "^0.2.17",
|
|
122
122
|
"@mcp-abap-adt/auth-providers": "^0.2.10",
|
|
123
123
|
"@mcp-abap-adt/auth-stores": "^0.2.10",
|
|
124
124
|
"@mcp-abap-adt/connection": "^0.2.9",
|
|
125
|
-
"@mcp-abap-adt/core": "^1.4.1",
|
|
126
125
|
"@mcp-abap-adt/header-validator": "^0.1.8",
|
|
127
126
|
"@mcp-abap-adt/interfaces": "^0.2.15",
|
|
128
127
|
"@mcp-abap-adt/logger": "^0.1.4",
|