Skip to content

How to use prompts and resources in MCP servers? Can prompts and resources be reused or called from tools? #481

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

Open
pedrojfds opened this issue May 12, 2025 · 1 comment
Labels
enhancement New feature or request

Comments

@pedrojfds
Copy link

I'm building an MCP server using @modelcontextprotocol/sdk with TypeScript and integrating it into an app like VSCode. From what I see, only tools are recognized and used by the app/client, while resources like prompt are not.

I'm trying to understand:

How are prompt resources meant to be used in an MCP server?

Can a prompt be invoked from within a tool? (e.g., a tool that internally calls a prompt and returns its result)

What's the recommended pattern for reusing prompts across tools or other resources?

In environments like VSCode, is there any support for exposing non-tool resources (like prompts or resources) or linking prompts and tools in some way?

Some documentation or example code would be really helpful to clarify how prompts and other resources should be structured and composed with tools.

Thanks a lot!

@pedrojfds pedrojfds added the enhancement New feature or request label May 12, 2025
@pedrojfds pedrojfds changed the title How to use prompt and other resource types in MCP servers? Can prompts be reused or called from tools? How to use prompts and resources in MCP servers? Can prompts and resources be reused or called from tools? May 12, 2025
@mogulsstar
Copy link

same question

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants