Skip to content

Commit c9c118a

Browse files
oleksandrkitsclaude
andcommitted
Add global cross-service tools to MCP Tools panel
Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>
1 parent a25b28e commit c9c118a

6 files changed

Lines changed: 71 additions & 5 deletions

File tree

dist/7846.aeb0ae4823b8f56f.js

Lines changed: 0 additions & 1 deletion
This file was deleted.

dist/7846.ec7ac8023cd7c3fa.js

Lines changed: 1 addition & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

dist/index.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -9,5 +9,5 @@
99
<body class="mat-typography">
1010
<df-root></df-root>
1111
<script type="text/javascript" src="https://assets.calendly.com/assets/external/widget.js"></script>
12-
<script src="runtime.2912efdf33852667.js" type="module"></script><script src="polyfills.cb64ea9d35bc0a9e.js" type="module"></script><script src="main.ad26fc0e021d9867.js" type="module"></script></body>
12+
<script src="runtime.80f033498e05fea4.js" type="module"></script><script src="polyfills.cb64ea9d35bc0a9e.js" type="module"></script><script src="main.ad26fc0e021d9867.js" type="module"></script></body>
1313
</html>
Lines changed: 1 addition & 1 deletion
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

src/app/adf-services/df-service-details/df-service-details.component.html

Lines changed: 43 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -888,11 +888,52 @@ <h4 class="text-center" style="color: black !important">
888888
<div class="details-section" *ngIf="!mcpServicesLoaded">
889889
<p>Loading services...</p>
890890
</div>
891-
<div class="details-section" *ngIf="mcpServicesLoaded && mcpServices.length === 0">
891+
<div class="details-section" *ngIf="mcpServicesLoaded && mcpServices.length === 0 && mcpGlobalTools.length === 0">
892892
<p>No database or file services found.</p>
893893
</div>
894-
<div *ngIf="mcpServicesLoaded && mcpServices.length > 0" class="mcp-tools-container">
894+
<div *ngIf="mcpServicesLoaded" class="mcp-tools-container">
895895
<mat-accordion multi>
896+
<!-- Global (cross-service) tools -->
897+
<mat-expansion-panel>
898+
<mat-expansion-panel-header>
899+
<mat-panel-title class="mcp-service-header">
900+
<mat-slide-toggle
901+
color="primary"
902+
[checked]="isAllGlobalToolsEnabled()"
903+
(change)="toggleAllGlobalTools($event.checked)"
904+
(click)="$event.stopPropagation()">
905+
</mat-slide-toggle>
906+
<span>Global Tools</span>
907+
</mat-panel-title>
908+
<mat-panel-description>
909+
Cross-service &middot; {{ mcpGlobalTools.length }} tools
910+
</mat-panel-description>
911+
</mat-expansion-panel-header>
912+
<table class="mcp-services-table full-width">
913+
<thead>
914+
<tr>
915+
<th class="toggle-col"></th>
916+
<th>Tool Name</th>
917+
<th>Description</th>
918+
</tr>
919+
</thead>
920+
<tbody>
921+
<tr *ngFor="let tool of mcpGlobalTools" [class.disabled-row]="!isToolEnabled(tool.name)">
922+
<td class="toggle-col">
923+
<mat-slide-toggle
924+
color="primary"
925+
[checked]="isToolEnabled(tool.name)"
926+
(change)="toggleTool(tool.name, $event.checked)">
927+
</mat-slide-toggle>
928+
</td>
929+
<td><code>{{ tool.name }}</code></td>
930+
<td>{{ tool.description }}</td>
931+
</tr>
932+
</tbody>
933+
</table>
934+
</mat-expansion-panel>
935+
936+
<!-- Per-service tools -->
896937
<mat-expansion-panel *ngFor="let svc of mcpServices" [expanded]="svc.expanded">
897938
<mat-expansion-panel-header>
898939
<mat-panel-title class="mcp-service-header">

src/app/adf-services/df-service-details/df-service-details.component.ts

Lines changed: 25 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -189,6 +189,17 @@ export class DfServiceDetailsComponent implements OnInit {
189189
}[] = [];
190190
mcpServicesLoaded = false;
191191
disabledTools = new Set<string>();
192+
mcpGlobalTools: { name: string; title: string; description: string }[] = [
193+
{ name: 'list_apis', title: 'List Available APIs', description: 'List all available database APIs and their tool prefixes' },
194+
{ name: 'all_get_tables', title: 'Get Tables from All Databases', description: 'Retrieve tables from all connected database services in one call' },
195+
{ name: 'all_find_table', title: 'Find Table Across Databases', description: 'Search for a table by name across all connected databases' },
196+
{ name: 'all_get_stored_procedures', title: 'Get Stored Procedures from All', description: 'Retrieve stored procedures from all connected databases' },
197+
{ name: 'all_get_stored_functions', title: 'Get Stored Functions from All', description: 'Retrieve stored functions from all connected databases' },
198+
{ name: 'all_get_resources', title: 'Get Resources from All', description: 'Retrieve all available resources from all connected databases' },
199+
{ name: 'all_list_files', title: 'List Files from All Storage', description: 'List files from all connected file storage services' },
200+
{ name: 'search', title: 'Search (stub)', description: 'Stub search implementation for connectors that require it' },
201+
{ name: 'fetch', title: 'Fetch (stub)', description: 'Stub fetch implementation for connectors that require it' },
202+
];
192203

193204
constructor(
194205
private activatedRoute: ActivatedRoute,
@@ -778,6 +789,20 @@ export class DfServiceDetailsComponent implements OnInit {
778789
}
779790
}
780791

792+
isAllGlobalToolsEnabled(): boolean {
793+
return this.mcpGlobalTools.some(t => !this.disabledTools.has(t.name));
794+
}
795+
796+
toggleAllGlobalTools(enabled: boolean) {
797+
for (const tool of this.mcpGlobalTools) {
798+
if (enabled) {
799+
this.disabledTools.delete(tool.name);
800+
} else {
801+
this.disabledTools.add(tool.name);
802+
}
803+
}
804+
}
805+
781806
isServiceEnabled(svc: { tools: { name: string }[] }): boolean {
782807
return svc.tools.some(t => !this.disabledTools.has(t.name));
783808
}

0 commit comments

Comments
 (0)