Building a Personal MCP Server for Claude
Stop copy-pasting your bio. Build a custom Model Context Protocol (MCP) server in TypeScript to give Claude native access to your projects, resume, and personal context.

I’m tired of pasting my "about me" blurb every time I start a new chat with Claude. If you’re a developer using Claude for Desktop, you should be using the Model Context Protocol (MCP). It’s an open standard that lets AI models interact with your local data and tools through a unified interface.
Instead of generic context, we’re going to build a personal MCP server in TypeScript. This server will act as a dedicated knowledge base for your bio, active projects, and technical stack. When you ask Claude "What should I work on next?", it will actually know what's in your active_projects.json.
The Stack
We’re keeping this lean. No databases, no complex auth. Just a local Node.js process talking to Claude over stdio.
- Language: TypeScript
- Runtime: Node.js (v18+)
- SDK:
@modelcontextprotocol/sdk - Validation:
zod
1. Project Setup
Start by initializing a new TypeScript project. The MCP SDK uses ESM, so make sure your package.json reflects that.
mkdir my-personal-mcp && cd my-personal-mcp
npm init -y
npm install @modelcontextprotocol/sdk zod
npm install -D typescript @types/node tsx
Update your package.json to include "type": "module" and a build script. Your tsconfig.json should target ES2022 or higher.
2. Define Your Data
Create a data.json file. This is where your personal context lives. Storing it as JSON makes it trivial for the MCP server to parse and serve to the LLM.
{
"bio": "Full-stack developer focused on SaaS and open-source tools.",
"tech_stack": ["TypeScript", "Next.js", "PostgreSQL", "FastAPI"],
"projects": [
{
"name": "ArbindBuilds",
"status": "active",
"description": "A content system for indie makers."
}
]
}
3. The Server Implementation
The core logic happens in src/index.ts. We use McpServer to register a tool. This tool will read our JSON file and return the contents to Claude.
import { McpServer } from "@modelcontextprotocol/sdk/server/mcp.js";
import { StdioServerTransport } from "@modelcontextprotocol/sdk/server/stdio.js";
import { readFileSync } from "fs";
import { resolve } from "path";
// 1. Initialize the server
const server = new McpServer({
name: "personal-context-server",
version: "1.0.0",
});
// 2. Register the tool
server.tool(
"get_personal_info",
"Retrieves bio, projects, and tech stack information about Arbind",
{}, // No arguments needed for this basic call
async () => {
try {
const dataPath = resolve(process.cwd(), "data.json");
const data = JSON.parse(readFileSync(dataPath, "utf-8"));
return {
content: [
{
type: "text",
text: JSON.stringify(data, null, 2),
},
],
};
} catch (error) {
return {
content: [{ type: "text", text: "Error: Could not read personal data." }],
isError: true,
};
}
}
);
// 3. Connect using stdio transport
async function main() {
const transport = new StdioServerTransport();
await server.connect(transport);
console.error("Personal MCP server running on stdio");
}
main().catch((err) => {
console.error("Fatal error:", err);
process.exit(1);
});
Comments
Tagged