Unlisted
Like
mcp
Val Town is a collaborative website to build and scale JavaScript apps.
Deploy APIs, crons, & store data – all from the browser, and deployed in milliseconds.
Viewing readonly version of main branch: v31View latest version
This is an HTTP handler that serves as an MCP (Model Control Protocol) server with tools to create and manage other MCP server vals.
- Create new MCP server vals using a template
- Update existing MCP server vals
- Get the MCP server template code
Creates a new MCP server val with the provided name and description.
Parameters:
name
: Name of the val to createdescription
: Description of the val
Updates an existing MCP server val with new code.
Parameters:
id
: ID of the val to updatecode
: New code for the val
Returns the MCP server template code.
This val requires the following environment variables:
VAL_TOWN_API_KEY
: Your Val Town API key for creating and updating valsREDIS_URL
: Redis URL for the MCP server (used by @vercel/mcp-adapter)
This val is designed to be used as an MCP server endpoint that can be connected to by AI assistants that support the MCP protocol. The assistant can then use the provided tools to create and manage MCP server vals.
The template used for new MCP server vals includes a basic "echo" tool that demonstrates the MCP handler functionality.