Provides authentication for the VS Code integration, allowing users to login with GitHub to access the MCP server functionality within VS Code.
MCP Server Basic Example
This is a basic example of a Model Context Protocol (MCP) server implementation that demonstrates core functionality including tools and resources.
Setup Steps
- Initialize the project (Go to any local folder and launch powershell or cmd):
Create virtual environment and activate it
- Install dependencies:
or
Features
The server implements the following features:
Tools
add(a: int, b: int)
: Adds two numberssubtract(a: int, b: int)
: Subtracts second number from first
Resources
greeting://{name}
: Returns a personalized greeting
Running the Server
To run the server with the MCP Inspector for development:
To run the server normally:
To install the server in Claude desktop app:
MCP connect in VS code
- Open folder/mcp-server-basic in vs code
- open terminal and run below command :
- Click Cntrl+Shift+I to launch chat in vs code
- Do login with Github and setup
- Folow the below steps (two way to add mcp configuration for vs code user settings):
Project Structure
main.py
: Main server implementation with tools and resourcespyproject.toml
: Project configuration and dependencies
This server cannot be installed
A basic implementation of a Model Context Protocol server that demonstrates core functionality with simple math tools (add, subtract) and greeting resources for AI assistants like Claude.
Related MCP Servers
- -securityAlicense-qualityA simple implementation of a Model Context Protocol server that demonstrates core functionality including mathematical tools (add, subtract) and personalized greeting resources.Last updated -56PythonGPL 3.0
- -securityFlicense-qualityA sample implementation of Model Context Protocol server demonstrating core functionality with simple arithmetic tools and greeting resources.Last updated -Python
- -securityFlicense-qualityA basic Model Context Protocol server implementation that demonstrates core functionality including tools and resources for AI chat applications.Last updated -Python
- AsecurityFlicenseAqualityA Model Context Protocol server implementation that provides basic utility tools including echo, uppercase text conversion, and mathematical calculations.Last updated -3738JavaScript