- Explore MCP Servers
- template-mcp-hello-world-ts
Template Mcp Hello World Ts
What is Template Mcp Hello World Ts
This project is a TypeScript template for creating a Model Context Protocol (MCP) server using the Blaxel platform. It serves as a simple ‘Hello World’ implementation, showcasing how to develop MCP tools and functions that can integrate with AI agents and language models via the MCP interface.
Use cases
The MCP server can be utilized to rapidly deploy AI functionalities, enabling interaction through standard protocols. It demonstrates a mechanism for AI agents to process input, validate parameters, and return responses, making it suitable for various AI-driven applications and services.
How to use
To use the MCP server, clone the repository, install dependencies with npm, and start the development server. You can deploy the server to the Blaxel platform using the Blaxel CLI. The server supports hot reloading for development and can be inspected using the MCP inspector.
Key features
Key features include a simple MCP server built in TypeScript, parameter validation with Zod, integration with the Blaxel platform, support for stdio and Blaxel transport protocols, hot reload development, and production-ready TypeScript compilation.
Where to use
This template is ideal for developers looking to create AI-driven tools and functions on the Blaxel platform. It can be used in various settings where integration with AI agents is needed, including chatbots, automated assistants, and any service requiring dynamic interaction based on user input.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Overview
What is Template Mcp Hello World Ts
This project is a TypeScript template for creating a Model Context Protocol (MCP) server using the Blaxel platform. It serves as a simple ‘Hello World’ implementation, showcasing how to develop MCP tools and functions that can integrate with AI agents and language models via the MCP interface.
Use cases
The MCP server can be utilized to rapidly deploy AI functionalities, enabling interaction through standard protocols. It demonstrates a mechanism for AI agents to process input, validate parameters, and return responses, making it suitable for various AI-driven applications and services.
How to use
To use the MCP server, clone the repository, install dependencies with npm, and start the development server. You can deploy the server to the Blaxel platform using the Blaxel CLI. The server supports hot reloading for development and can be inspected using the MCP inspector.
Key features
Key features include a simple MCP server built in TypeScript, parameter validation with Zod, integration with the Blaxel platform, support for stdio and Blaxel transport protocols, hot reload development, and production-ready TypeScript compilation.
Where to use
This template is ideal for developers looking to create AI-driven tools and functions on the Blaxel platform. It can be used in various settings where integration with AI agents is needed, including chatbots, automated assistants, and any service requiring dynamic interaction based on user input.
Clients Supporting MCP
The following are the main client software that supports the Model Context Protocol. Click the link to visit the official website for more information.
Content
Blaxel MCP Hello World TypeScript
A TypeScript template implementation of a Model Context Protocol (MCP) server using the Blaxel platform. This simple “Hello World” server demonstrates how to create MCP tools and functions that can be integrated with AI agents and language models through the standardized MCP interface.
📑 Table of Contents
- ✨ Features
- 🚀 Quick Start
- 📋 Prerequisites
- 💻 Installation
- 🔧 Usage
- 📁 Project Structure
- ❓ Troubleshooting
- 👥 Contributing
- 🆘 Support
- 📄 License
✨ Features
- Simple MCP server implementation with TypeScript
- “Hello World” tool function with parameter validation
- Zod schema validation for robust type safety
- Built-in Blaxel platform integration for seamless deployment
- Support for both stdio and Blaxel transport protocols
- Hot reload development environment
- Production-ready TypeScript compilation
- Easy integration with AI agents and language models
🚀 Quick Start
For those who want to get up and running quickly:
# Clone the repository
git clone https://github.com/blaxel-ai/template-mcp-hello-world-ts.git
# Navigate to the project directory
cd template-mcp-hello-world-ts
# Install dependencies
npm install
# Start the development server
npm dev
# In another terminal, deploy to Blaxel
bl deploy
# Test MCP server
npm run inspect
📋 Prerequisites
- Node.js: 18.0 or later
- Blaxel Platform Setup: Complete Blaxel setup by following the quickstart guide
- Blaxel CLI: Ensure you have the Blaxel CLI installed. If not, install it globally:
curl -fsSL https://raw.githubusercontent.com/blaxel-ai/toolkit/main/install.sh | BINDIR=/usr/local/bin sudo -E sh - Blaxel login: Login to Blaxel platform
bl login YOUR-WORKSPACE
- Blaxel CLI: Ensure you have the Blaxel CLI installed. If not, install it globally:
💻 Installation
Clone the repository and install dependencies:
git clone https://github.com/blaxel-ai/template-mcp-hello-world-ts.git
cd template-mcp-hello-world-ts
npm install
🔧 Usage
Running Locally
Start the development server with hot reloading:
npm dev
For production build and run:
# Build the TypeScript code
npm run build
# Run the compiled JavaScript
npm run prod
You can also inspect the MCP server using the official MCP inspector:
npm run inspect
Note: The development server automatically restarts when you make changes to the source code.
Testing
You can test your MCP function locally:
# Test with the MCP inspector
npm run inspect
The MCP tool expects a firstname parameter and returns a greeting message.
Deployment
When you are ready to deploy your MCP server:
bl deploy
This command uses your code and the configuration in blaxel.toml to deploy your MCP server as a function on the Blaxel platform.
📁 Project Structure
- src/server.ts - Main MCP server implementation with the hello_world tool
- package.json - NPM package configuration with scripts and dependencies
- tsconfig.json - TypeScript compiler configuration
- blaxel.toml - Blaxel deployment configuration (function type)
❓ Troubleshooting
Common Issues
-
Blaxel Platform Issues:
- Ensure you’re logged in to your workspace:
bl login MY-WORKSPACE - Verify models are available:
bl get models - Check that functions exist:
bl get functions
- Ensure you’re logged in to your workspace:
-
MCP Server Connection Issues:
- Verify the server starts without errors using
npm run dev - Check that the MCP inspector can connect using
npm run inspect - Ensure TypeScript compiles successfully with
npm run build - Verify WebSocket connections if using Blaxel transport
- Verify the server starts without errors using
-
Dependency and Environment Issues:
- Make sure you have Node.js 18+
- Try
npm installto reinstall dependencies - Check for TypeScript compilation errors
- Verify that all required dependencies are installed
For more help, please submit an issue on GitHub.
👥 Contributing
Contributions are welcome! Here’s how you can contribute:
- Fork the repository
- Create a feature branch:
git checkout -b feature/amazing-feature - Commit your changes:
git commit -m 'Add amazing feature' - Push to the branch:
git push origin feature/amazing-feature - Submit a Pull Request
Please make sure to update tests as appropriate and follow the TypeScript code style of the project.
🆘 Support
If you need help with this template:
- Submit an issue for bug reports or feature requests
- Visit the Blaxel Documentation for platform guidance
- Check the Model Context Protocol Documentation for MCP-specific help
- Join our Discord Community for real-time assistance
📄 License
This project is licensed under the MIT License. See the LICENSE file for more details.
Dev Tools Supporting MCP
The following are the main code editors that support the Model Context Protocol. Click the link to visit the official website for more information.










