Skip to content
This repository was archived by the owner on Apr 8, 2025. It is now read-only.

doc: add await and fix param key name #267

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

KelvinQiu802
Copy link

  1. Add await for this.mcp.connect since it returns a Promise.
  2. use inputSchema instead of input_schema (fix type)

Motivation and Context

  1. Without await, an error will occur when calling getTools because the connection has not been established yet.
  2. In the Node MCP SDK, the type definition for Tool is inputSchema, not input_schema.

How Has This Been Tested?

Fix and run it

Breaking Changes

no

Types of changes

  • Bug fix (non-breaking change which fixes an issue)
  • New feature (non-breaking change which adds functionality)
  • Breaking change (fix or feature that would cause existing functionality to change)
  • Documentation update

Checklist

  • I have read the MCP Documentation
  • My code follows the repository's style guidelines
  • New and existing tests pass locally
  • I have added appropriate error handling
  • I have added or updated documentation as needed

Additional context

1. Add await for this.mcp.connect since it returns a Promise.
2. use inputSchema instead of input_schema (fix type)
@KelvinQiu802 KelvinQiu802 changed the title fix: await and param key name doc: add await and fix param key name Apr 6, 2025
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant