Skip to content

Implement DefaultMcpEndpointRouteBuilderConfigurator for MCP endpoint configuration #691

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

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

Conversation

DavidParks8
Copy link
Contributor

Motivation and Context

We need the ability to implement different transports (such as via orleans), without requiring consumers to use methods other than MapMcp.

Breaking Changes

No

Types of changes

  • New feature (non-breaking change which adds functionality)

?? throw new InvalidOperationException(
"You must call WithHttpTransport(). Unable to find required services. Call builder.Services.AddMcpServer().WithHttpTransport() in application startup code."
);
return configurator.Configure(endpoints, pattern);
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I don't think we should add a hook for a service to replace the implementation of MapMcp() entirely. If you want something that behaves radically differently, you can create your own MapWhateverMcp() method.

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It isn't radically different though, It is nearly exactly the same, minus the stateless behavior. Do we really want to force people to have to learn about MapWhateverMcp calls? I can guarantee you that some people will forget to change to the other MapWhatever call and will file an issue about "MapMcp" isn't working

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

Successfully merging this pull request may close these issues.

2 participants