iTranslated by AI
How I Had Devin Build an MCP Server Starting from Scratch
Having Devin Create an MCP Server from Scratch
Hello! I'm ikkitang from Linkage Inc.
Lately, I've been purely enjoying the chaos of the rapid pace of "AI" updates.
Recently, Devin announced the Core plan, starting at $20.
I signed up immediately. For my first project, I decided to have Devin write some code so I could properly understand the inner workings of MCP, which I had previously only understood vaguely. This blog post is about that.
The Finished Product
If you load this into Claude Desktop and say something like "Create a UUID," it will actually generate one for you.
Insights about MCP
Difference Between MCP Client and MCP Server
Initially, I didn't fully understand the MCP concept. In fact, there are two components to MCP: "Client" and "Server":
- MCP Client: Used by an AI assistant (e.g., Claude) to utilize tools provided by an MCP server
- MCP Server: Provides specific functionality (e.g., UUID generation) and makes it accessible to MCP clients
Initially, I was trying to create an "MCP Client." Because of that, I made the following request to Devin:
I want to create an MCP client so that I can generate UUIDs
However, what I actually wanted to do was "create an MCP server and publish a UUID generation tool." This confusion is also documented in Issue #3.
Incidentally, in the code Devin initially produced, the implementation was such that "if the MCP Client couldn't connect to an MCP Server, the MCP Client itself would handle the UUID generation," which only added to the confusion.
Creating the MCP Server with Devin
After the confusion was cleared up, I correctly asked Devin to create an "MCP Server," and it did a great job building it.
Project Structure
The project created by Devin has the following structure:
devin-mcp-uuid-sample/
├── src/
│ ├── index.ts # Main file for the MCP server
│ ├── service/
│ │ └── UuidApi.ts # Logic for UUID generation and validation
│ └── index.test.ts # Test file
├── package.json
└── README.md
Implementation Details
The core part of the MCP server is implemented in the index.ts file. Here is a part of it:
// MCP server initialization
const server = new McpServer({
name: 'uuid-server',
version: '1.0.0'
});
// Utilizing UUID API functionality
const uuidApi = new UuidApi();
// Tool definition: Generate a single UUID
server.tool(
'generate-uuid',
{},
async () => {
const uuid = uuidApi.generateUuid();
return {
content: [{ type: 'text', text: uuid }]
};
}
);
// Tool definition: Generate multiple UUIDs
server.tool(
'generate-uuids',
{ count: z.number().min(1).max(100) },
async ({ count }) => {
const uuids = uuidApi.generateUuids(count);
return {
content: [{ type: 'text', text: uuids.join('\n') }]
};
}
);
Integration Between Claude Desktop and the MCP Server
The created MCP server can be used from clients like Claude Desktop. The setup process is very simple:
- Build the MCP server:
npm run build - Add the following to your Claude Desktop configuration:
{
"mcpServers": {
"uuid-generator": {
"command": "node",
"args": [
"/path/to/devin-mcp-uuid-sample/dist/src/index.js"
]
}
}
}
This makes the following tools available within Claude:
-
generate-uuid: Generates a single UUID -
generate-uuids: Generates a specified number of UUIDs (1–100) -
detect-uuid-version: Validates the validity and version of a specified UUID
I found that Claude wouldn't load the tools unless the tool names were clearly defined, so I'd like to write another casual blog post about that at some point.
Lessons Learned
From this experience, I gained the following insights:
- Understanding MCP Concepts: I was able to build it quickly and grasp the differences between an MCP Client and an MCP Server to a certain extent.
- Devin's Efficiency: Devin was incredibly convenient. I could give instructions before going to bed or send requests via Slack while out looking at cherry blossoms with my kids—essentially, the code was completed using just a smartphone.
I would create an Issue and then send the request via Slack.

A PR would be raised in just a few minutes.

When I performed a code review, it responded automatically and made the necessary fixes itself.

This is generally how the code progressed.
I think it cost roughly $7 to reach completion (using about 7 out of 20 ACUs).
I occasionally take notes, but then I completely forget about them. lol
Summary
I started this MCP Server development with zero prior knowledge, but I ended up with a deeper understanding precisely because I failed so much along the way.
The finished project is available on GitHub, so please check it out if you're interested.
Discussion