-
Notifications
You must be signed in to change notification settings - Fork 169
chore: add developer guide and code examples to extend MCP server via library exports MCP-299 #767
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Changes from 3 commits
9a6f1df
79fe868
c5bffeb
2ea82d5
e00143b
18f8da3
c786c6b
164b79f
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Large diffs are not rendered by default.
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,29 +1,13 @@ | ||
| import { ListClustersTool } from "./read/listClusters.js"; | ||
| import { ListProjectsTool } from "./read/listProjects.js"; | ||
| import { InspectClusterTool } from "./read/inspectCluster.js"; | ||
| import { CreateFreeClusterTool } from "./create/createFreeCluster.js"; | ||
| import { CreateAccessListTool } from "./create/createAccessList.js"; | ||
| import { InspectAccessListTool } from "./read/inspectAccessList.js"; | ||
| import { ListDBUsersTool } from "./read/listDBUsers.js"; | ||
| import { CreateDBUserTool } from "./create/createDBUser.js"; | ||
| import { CreateProjectTool } from "./create/createProject.js"; | ||
| import { ListOrganizationsTool } from "./read/listOrgs.js"; | ||
| import { ConnectClusterTool } from "./connect/connectCluster.js"; | ||
| import { ListAlertsTool } from "./read/listAlerts.js"; | ||
| import { GetPerformanceAdvisorTool } from "./read/getPerformanceAdvisor.js"; | ||
|
|
||
| export const AtlasTools = [ | ||
| ListClustersTool, | ||
| ListProjectsTool, | ||
| InspectClusterTool, | ||
| CreateFreeClusterTool, | ||
| CreateAccessListTool, | ||
| InspectAccessListTool, | ||
| ListDBUsersTool, | ||
| CreateDBUserTool, | ||
| CreateProjectTool, | ||
| ListOrganizationsTool, | ||
| ConnectClusterTool, | ||
| ListAlertsTool, | ||
| GetPerformanceAdvisorTool, | ||
| ]; | ||
| export { ListClustersTool } from "./read/listClusters.js"; | ||
| export { ListProjectsTool } from "./read/listProjects.js"; | ||
| export { InspectClusterTool } from "./read/inspectCluster.js"; | ||
| export { CreateFreeClusterTool } from "./create/createFreeCluster.js"; | ||
| export { CreateAccessListTool } from "./create/createAccessList.js"; | ||
| export { InspectAccessListTool } from "./read/inspectAccessList.js"; | ||
| export { ListDBUsersTool } from "./read/listDBUsers.js"; | ||
| export { CreateDBUserTool } from "./create/createDBUser.js"; | ||
| export { CreateProjectTool } from "./create/createProject.js"; | ||
| export { ListOrganizationsTool } from "./read/listOrgs.js"; | ||
| export { ConnectClusterTool } from "./connect/connectCluster.js"; | ||
| export { ListAlertsTool } from "./read/listAlerts.js"; | ||
| export { GetPerformanceAdvisorTool } from "./read/getPerformanceAdvisor.js"; |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,6 +1,4 @@ | ||
| import { DeleteDeploymentTool } from "./delete/deleteDeployment.js"; | ||
| import { ListDeploymentsTool } from "./read/listDeployments.js"; | ||
| import { CreateDeploymentTool } from "./create/createDeployment.js"; | ||
| import { ConnectDeploymentTool } from "./connect/connectDeployment.js"; | ||
|
|
||
| export const AtlasLocalTools = [ListDeploymentsTool, DeleteDeploymentTool, CreateDeploymentTool, ConnectDeploymentTool]; | ||
| export { DeleteDeploymentTool } from "./delete/deleteDeployment.js"; | ||
| export { ListDeploymentsTool } from "./read/listDeployments.js"; | ||
| export { CreateDeploymentTool } from "./create/createDeployment.js"; | ||
| export { ConnectDeploymentTool } from "./connect/connectDeployment.js"; |
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -1,13 +1,20 @@ | ||
| import { AtlasTools } from "./atlas/tools.js"; | ||
| import { AtlasLocalTools } from "./atlasLocal/tools.js"; | ||
| import { MongoDbTools } from "./mongodb/tools.js"; | ||
| import * as AtlasTools from "./atlas/tools.js"; | ||
| import * as AtlasLocalTools from "./atlasLocal/tools.js"; | ||
| import * as MongoDbTools from "./mongodb/tools.js"; | ||
|
|
||
| const AllTools = [...MongoDbTools, ...AtlasTools, ...AtlasLocalTools]; | ||
| const AllTools = { | ||
| ...MongoDbTools, | ||
| ...AtlasTools, | ||
| ...AtlasLocalTools, | ||
| } as const; | ||
|
||
|
|
||
| // Export all the different categories of tools | ||
| export { AllTools, MongoDbTools, AtlasTools, AtlasLocalTools }; | ||
|
|
||
| // Export the base tool class and supporting types. | ||
| export { | ||
| ToolBase, | ||
| type ToolClass, | ||
| type ToolConstructorParams, | ||
| type ToolCategory, | ||
| type OperationType, | ||
|
|
||
Uh oh!
There was an error while loading. Please reload this page.