mcp-karyawan
This server provides full CRUD (Create, Read, Update, Delete) management of employee (karyawan) records. You can:
Create a new employee with
nama,jabatan,departemen,email, and an optionalstatus(defaults to'aktif'). A unique UUID is automatically generated.List all employees to retrieve all stored records.
Get a specific employee by their unique
id.Update an employee's details (any of
nama,jabatan,departemen,email,status) by providing theidand the fields to change. Missing or null fields are left unchanged.Delete an employee permanently using their
id.
Click on "Deploy Server".
Wait a few minutes for the server to deploy. Once ready, it will show a "Started" state.
In the chat, type
@followed by the MCP server name and your instructions, e.g., "@mcp-karyawanlist all employees"
That's it! The server will respond to your query, and you can continue using it as needed.
Here is a step-by-step guide with screenshots.
Karyawan MCP Demo
Server Model Context Protocol (MCP) sederhana untuk demo — menyediakan operasi CRUD (Create, Read, Update, Delete) data karyawan yang bisa dipanggil langsung oleh Claude (Claude Code maupun Claude Desktop) sebagai tools.
Data disimpan in-memory (array JavaScript), jadi hanya untuk keperluan belajar/demo — data akan hilang setiap kali server di-restart.
Fungsinya apa?
Server ini mengekspos 5 tools MCP yang bisa dipanggil Claude untuk mengelola data karyawan tanpa perlu database:
Tool | Deskripsi | Input |
| Ambil semua data karyawan | - |
| Ambil satu karyawan berdasarkan |
|
| Tambah karyawan baru |
|
| Ubah data karyawan (field yang tidak diisi tidak berubah) |
|
| Hapus karyawan berdasarkan |
|
Setiap karyawan punya field: id (number, auto-increment), nama, posisi, divisi, gaji.
Related MCP server: MCP Playground
File utama
src/index.ts— satu-satunya file source. Berisi definisi data karyawan (seed data) dan registrasi 5 tools MCP di atas, lalu menjalankan server lewat stdio transport.package.json— dependency utama:@modelcontextprotocol/serverdanzod(untuk validasi input tool).
Instalasi
Requirement
Node.js versi 20+ (disarankan v22/v24 karena bisa langsung menjalankan file
.tstanpa build/transpile terpisah).
1. Clone repo
git clone <url-repo-ini>
cd mcp-demo2. Install dependency
npm install3. Coba jalankan manual (opsional, untuk memastikan server jalan)
node src/index.tsJika muncul log weather MCP server running on stdio di terminal, server sudah berjalan dan menunggu koneksi lewat stdio. Tekan Ctrl+C untuk berhenti.
Menghubungkan ke Claude Code
Jalankan perintah berikut dari root project ini (ganti path sesuai lokasi clone di komputer kamu):
claude mcp add karyawan-mcp-demo -- node ./src/index.tsCek apakah server sudah terdaftar:
claude mcp listSetelah itu, tools list_karyawan, get_karyawan, create_karyawan, update_karyawan, dan delete_karyawan bisa langsung dipanggil Claude Code di sesi chat kamu.
Menghubungkan ke Claude Desktop
Buka file konfigurasi MCP milik Claude Desktop (buat file/folder-nya kalau belum ada):
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.json
Tambahkan entry berikut ke bagian
mcpServers(sesuaikan pathsrc/index.tsdengan lokasi clone repo di komputermu):{ "mcpServers": { "karyawan-mcp-demo": { "command": "node", "args": ["/path/ke/mcp-demo/src/index.ts"] } } }Simpan file, lalu restart Claude Desktop sepenuhnya (keluar dari aplikasi, buka lagi).
Buka chat baru, cek ikon "tools"/MCP di Claude Desktop — server
karyawan-mcp-demobeserta 5 tools-nya seharusnya sudah muncul dan siap dipakai.
Contoh pemakaian
Setelah terhubung, tinggal minta ke Claude, misalnya:
"Tampilkan semua karyawan"
"Tambah karyawan baru bernama Sarah Mitchell, posisi Backend Engineer, divisi Engineering, gaji 15000000"
"Update gaji karyawan dengan id
...jadi 16000000""Hapus karyawan dengan id
..."
Claude akan otomatis memanggil tool MCP yang sesuai.
Available Tools
5 toolscreate_karyawanA
Buat data karyawan baru. Id akan digenerate otomatis (uuid).
| Name | Required | Description | Default |
|---|---|---|---|
| nama | Yes | ||
| Yes | |||
| status | No | aktif | |
| jabatan | Yes | ||
| departemen | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, description carries full burden; it discloses auto-generated ID (UUID) but does not mention authorization, side effects, or confirmation behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Two short sentences, front-loaded with purpose, no redundancy or superfluous information.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Output schema exists so return values are covered, but description lacks parameter details and guidance for a create operation with 5 parameters.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0% and description adds no meaning to parameters beyond their titles; only ID generation is clarified.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states the tool creates a new employee record ('Buat data karyawan baru') and specifies auto-generated ID, distinguishing it from list/get/update/delete siblings.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance on when to use vs alternatives; usage is implied by the create nature, but no when-not or context provided.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
delete_karyawanC
Hapus data karyawan berdasarkan id.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description carries full burden. It merely states 'delete' without disclosing permanence, required permissions, cascading effects, or what the output contains. The output schema exists but is not explained.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
Single sentence is efficient and front-loaded. However, it omits potentially essential details, making it borderline under-specified.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
For a simple delete tool with an output schema, the description fails to clarify if deletion is permanent, what happens to related data, or what the response indicates. Incomplete for safe usage.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema coverage is 0%, so description must compensate. The description implies 'id' selects the record, but adds no format, constraints, or examples beyond the schema field name.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
Description clearly states the verb 'Hapus' (delete) and resource 'data karyawan' (employee data), distinguishing it from sibling CRUD tools. However, it lacks specificity like 'permanently deletes' or 'removes record'.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No explicit guidance on when to use or alternatives. It is implied for deleting by id, but no context about prerequisites, side effects, or comparison with update/create tools.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
get_karyawanA
Ambil data satu karyawan berdasarkan id. Gagal jika id tidak ditemukan.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries the burden. It discloses that the tool fails if the id is not found, providing error behavior. Additional details like read-only nature are implicit but acceptable.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is two sentences with no redundant information. It is front-loaded with the primary action and includes the error condition concisely.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the low complexity (one parameter, single resource) and presence of an output schema, the description covers purpose and error behavior. It is complete enough for an agent to select and invoke correctly, though slightly more detail on the id would help.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
The description does not elaborate on the 'id' parameter beyond its existence. With 0% schema coverage, it fails to add meaning such as format, example, or source, despite the parameter being self-explanatory.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description uses a specific verb 'Ambil' (retrieve) and resource 'data satu karyawan' (data of one employee), clearly distinguishing it from sibling tools like list_karyawan (multiple records) and update/delete/create (mutations).
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description states it retrieves data based on id, implying usage when a specific id is known. It does not explicitly list when not to use or provide alternatives, but the context is clear enough.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
list_karyawanA
Tampilkan semua data karyawan.
| Name | Required | Description | Default |
|---|---|---|---|
No parameters | |||
Output Schema
| Name | Required | Description |
|---|---|---|
| result | Yes |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description must carry the full behavioral burden. It does not disclose important traits like output format (list vs single), pagination, ordering, or performance implications.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
A single, direct sentence with no unnecessary words. Perfectly concise for a simple tool.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
Given the tool has no parameters and an output schema exists, the description is nearly complete. However, it could explicitly state that it returns a list of all employees, though 'tampilkan semua data karyawan' implies a full listing.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
There are zero parameters, so schema coverage is 100% by default. Baseline is 4; the description adds no parameter details but none are needed.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the tool's action (display) and resource (all employee data). It effectively distinguishes from sibling tools like get_karyawan (likely single record), update, delete, and create.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
No guidance on when to use this tool vs alternatives. For instance, it doesn't mention that get_karyawan is better for retrieving a specific employee, or that list returns all without filtering.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
update_karyawanA
Perbarui data karyawan berdasarkan id. Field bernilai None tidak diubah.
| Name | Required | Description | Default |
|---|---|---|---|
| id | Yes | ||
| nama | No | ||
| No | |||
| status | No | ||
| jabatan | No | ||
| departemen | No |
Output Schema
| Name | Required | Description |
|---|---|---|
No output parameters | ||
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations provided, the description carries the full burden. It discloses that fields with value None are not changed, which is important behavioral information. However, it does not mention other aspects like authorization requirements or return behavior.
Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.
Is the description appropriately sized, front-loaded, and free of redundancy?
The description is only two sentences, concise and front-loaded with the core action and key behavioral note. Every sentence adds value without redundancy.
Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.
Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?
The description covers the core behavior (update by id, None fields unchanged) but lacks detail on parameter usage, return values, or prerequisites. Given 6 parameters and an output schema exists (unseen), more context could improve completeness for an AI agent.
Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.
Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?
Schema description coverage is 0%, so the description must add meaning. It only explains the id parameter implicitly and the behavior for None fields. For 6 parameters, this is insufficient to clarify the semantics of nama, email, status, jabatan, and departemen beyond their names.
Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.
Does the description clearly state what the tool does and how it differs from similar tools?
The description clearly states the action 'Perbarui' (update), the resource 'data karyawan' (employee data), and the key identifier 'berdasarkan id' (by id). It effectively distinguishes this tool from sibling tools like create, list, get, and delete.
Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.
Does the description explain when to use this tool, when not to, or what alternatives exist?
The description implies when to use the tool (to update employee data by id) but does not explicitly mention when not to use it or provide alternatives. Sibling tools are listed but not referenced, offering no guidance on selection.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
5 tool updates
v0.1.0- First observed
create_karyawan - First observed
delete_karyawan - First observed
get_karyawan - First observed
list_karyawan - First observed
update_karyawan
TDQS
Scored across 5 tools
Each tool targets a distinct CRUD operation on the same 'karyawan' resource, with no overlap. The actions (list, get, update, delete, create) are clearly differentiated.
All tools follow a consistent verb_noun pattern in snake_case (e.g., list_karyawan, create_karyawan), with no deviations or mixed conventions.
5 tools provide a complete CRUD surface for a single resource, which is an appropriate and well-scoped set for a simple employee data management server.
The tool set covers all basic CRUD operations: create, read (both list and get), update, and delete. No obvious gaps for the stated purpose of managing karyawan data.
Maintenance
Related MCP Connectors
Hosted MCP server for AI-driven data ops. Create apps, manage schemas, and CRUD structured data.
- mcp-serverOAuthio.klokin
MCP server exposing klokin time-tracking operations (employees, time entries, stores) to AI clients.
Related MCP Servers
- FlicenseNot gradedqualityDmaintenanceA small MCP server that manages a product inventory using SQLite, providing CRUD operations through exposed MCP tools.-
- FlicenseDqualityDmaintenanceA demonstration MCP server that provides access to a SQLite employee database with tools for querying users and profiles, sending emails via Mailtrap, and proposing project teams based on employee skills.3-
- AlicenseNot gradedqualityDmaintenanceMCP server providing natural-language tools for managing and querying an employee database, including user CRUD, search, and statistics.MIT
- FlicenseNot gradedqualityDmaintenanceThis MCP server provides tools to manage a todo list with CRUD operations, enabling listing, creating, updating, and deleting todos.-