Skip to content

Conversation

@wellsiau-aws
Copy link
Contributor

@wellsiau-aws wellsiau-aws commented Jun 26, 2025

Still work in progress - pending test

Updated to support the new StreamableHTTP transport from mcp-go v0.32.0.

Resolves #68

1. Library Update

  • Updated github.com/mark3labs/mcp-go from v0.27.0 to v0.32.0
  • Migrated from server.NewSSEServer() to server.NewStreamableHTTPServer()

2. API Changes

The new mcp-go version changed how tool arguments are accessed:

Before (v0.27.0):

serviceSlug, ok := request.Params.Arguments["serviceSlug"].(string)
if !ok || serviceSlug == "" {
    return nil, fmt.Errorf("serviceSlug is required")
}

After (v0.32.0):

serviceSlug := request.GetString("serviceSlug", "")
if serviceSlug == "" {
    return nil, fmt.Errorf("serviceSlug is required")
}

3. Transport Implementation

New StreamableHTTP Implementation:

streamableServer := server.NewStreamableHTTPServer(hcServer,
    server.WithEndpointPath("/mcp"), // Standard MCP endpoint
    server.WithLogger(logger),
)

- Update mcp-go from v0.27.0 to v0.32.0
- Add StreamableHTTP server
- Update API calls to use new request.GetString() methods
- Maintain backward compatibility with stdio mode
@wellsiau-aws wellsiau-aws force-pushed the feature/http-mcp-server branch from 0888182 to 3887eec Compare June 26, 2025 23:39
@wellsiau-aws wellsiau-aws marked this pull request as draft June 26, 2025 23:41
@hashicorp-cla-app
Copy link

hashicorp-cla-app bot commented Jun 27, 2025

CLA assistant check

Thank you for your submission! We require that all contributors sign our Contributor License Agreement ("CLA") before we can accept the contribution. Read and sign the agreement

Learn more about why HashiCorp requires a CLA and what the CLA includes


1 out of 2 committers have signed the CLA.

  • wellsiau-aws
  • Workshop Participant

Workshop Participant seems not to be a GitHub user.
You need a GitHub account to be able to sign the CLA.
If you have already a GitHub account, please add the email address used for this commit to your account.

Have you signed the CLA already but the status is still pending? Recheck it.

@wellsiau-aws
Copy link
Contributor Author

closing this PR and re-opening a new one #99

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.

how to config terraform mcp server with docker opening port and mcp protocol as sse or streamhttp?

1 participant