JavaBytes MCP Server
80 Java-focused tools for files, MySQL, JavaFX, Spring Boot and JS-to-Java migration, over stdio.
JavaBytes scores 68 (Good), licensed MIT and written in Java. It installs as a local process. It declares 17 tools. Filed under Databases. GitHub shows 2 stars. Package registries report about 788 downloads a week. Install configs are generated for 10 clients. Being listed in the registry is not the same as being vendor-official.
Good trust
68 of 100 from six public signals. Nobody can buy a point.
- Listed in the official MCP registry.
- OSI-style license: mit.
License, quality and maintenance
Quality: Grade B
81/100 for listing completeness. Lost points: 8 of 17 tools barely described, short summary, no docs link.
How quality is graded
Where the 68 comes from
22 + 20 + 2 + 10 + 4 + 10 = 68. Each factor is capped, so no single signal can carry a listing.
Active in the official MCP registry, plus a known vendor namespace.
Registry: 22 of 30 points.How recently the repository saw a commit or release.
Maintenance: 20 of 20 points.GitHub stars and weekly downloads, on a log scale.
Popularity: 2 of 20 points.A clear, OSI-style open-source license.
License: 10 of 10 points.Not archived, a secure install path, a pinned version.
Security: 4 of 10 points.A real summary, a README with depth, listed tools.
Docs: 10 of 10 points.Install
Pick your client, copy the config, paste it in.
Needs Cursor or VS Code installed on this device. The button opens the app and asks you to confirm before it adds the server.
{ "mcpServers": { "markymakes-dev-javabytes": { "command": "npx", "args": [ "-y", "javabytes-mcp@1.5.2" ], "env": { "JAVABYTES_ALLOWED_DIRS": "", "JAVABYTES_DB_URL": "", "JAVABYTES_DB_USER": "", "JAVABYTES_DB_PASSWORD": "YOUR_JAVABYTES_DB_PASSWORD" } } }}
Environment variables
| Name | Required | Notes |
|---|---|---|
JAVABYTES_ALLOWED_DIRS | Optional | Filesystem sandbox roots (defaults to working dir + JVM temp dir) |
JAVABYTES_DB_URL | Optional | JDBC URL for the MySQL tools |
JAVABYTES_DB_USER | Optional | MySQL user |
JAVABYTES_DB_PASSWORDSecret | Optional | MySQL password |
Tools17Tool docs quality grade D
All capabilitiesSpring Boot layout inspection
Generates a self-contained JDBC helper that reads credentials from env
describe_tabletoolColumn metadata; identifiers are validated and backtick-quoted
Read env vars; secret-like values masked unless reveal=true
Parse mongoose/prisma/sequelize/SQL/JSON data declarations into tables and columns, with per-field confidence and an honest limitations list
Adds the Monocle property (dry run by default; apply=true to write)
Execute proposed normalized DDL against a user-supplied JDBC URL to create the schema (creates only; refuses existing-table collision unless confirm=true)
get_system_infotoolJVM/OS/hardware info
Clear the canvas
Draw rectangle/circle/line/text
Snapshot to a real PNG via SwingFXUtils + ImageIO
Create an off-screen canvas
About
JavaBytes
A general-purpose Java MCP (Model Context Protocol) server that speaks JSON-RPC 2.0 over stdio.
It exposes Java-oriented tools for file access, MySQL, JavaFX canvas rendering/export, project diagnostics, and code/CSS generation. It has no MCP SDK dependency: the protocol is implemented directly with Jackson.
Scope note: tools that only reword a prompt (most
*_generate_*tools) are conveniences. The tools that add real capability are the ones that touch the world: the file sandbox, live MySQL, JavaFX rendering, and project inspection.
Requirements
- Node.js 18+ (only for the
npxlauncher) - JDK 21 or newer (built and tested with JDK 25)
- Maven 3.9+ (only to build from source)
Install with npx
The javabytes-mcp package bundles the shaded jar, so a client only needs Node.js and Java:
npx -y javabytes-mcp
It resolves java from JAVABYTES_JAVA, then JAVA_HOME, then PATH, and the jar from
JAVABYTES_JAR or the bundled copy.
Client config — Claude Desktop and most clients:
{
"mcpServers": {
"javabytes": {
"command": "npx",
"args": ["-y", "javabytes-mcp"],
"env": {
"JAVABYTES_DB_URL": "jdbc:mysql://localhost:3306/appdb",
"JAVABYTES_DB_USER": "app",
"JAVABYTES_DB_PASSWORD": "change-me"
}
}
}
}
OpenCode (~/.config/opencode/opencode.json) uses a different shape — mcp, a command array,
and environment rather than env:
{
"mcp": {
"javabytes": {
"type": "local",
"command": ["npx", "-y", "javabytes-mcp"],
"environment": {
"JAVABYTES_DB_URL": "jdbc:mysql://localhost:3306/appdb",
"JAVABYTES_DB_USER": "app",
"JAVABYTES_DB_PASSWORD": "change-me"
},
"enabled": true
}
}
}
First Run (recommended)
# 1. Check your environment
npx -y javabytes-mcp doctor
# 2. Generate the config for your client (copy-paste into its config file)
npx -y javabytes-mcp config --client=opencode # → ~/.config/opencode/opencode.json
npx -y javabytes-mcp config --client=claude # → claude_desktop_config.json
npx -y javabytes-mcp config --client=cursor # → Cursor MCP settings
npx -y javabytes-mcp config --client=vscode # → .vscode/mcp.json
# 3. Restart your client and verify tools load (should show 50/80)
Example doctor output:
PASS java: 21.0.5 via JAVA_HOME (/usr/lib/jvm/java-21-openjdk/bin/java)
PASS jar: present (15.8 MB)
INFO db: JAVABYTES_DB_URL is not set - MySQL tools will be unconfigured
PASS update: up to date (1.2.0)
4 checks, 0 problems
Quick reference for config locations:
| Client | Config command | Where to paste |
|---|---|---|
| OpenCode | npx -y javabytes-mcp config --client=opencode | ~/.config/opencode/opencode.json |
| Claude Desktop | npx -y javabytes-mcp config --client=claude | ~/Library/Application Support/Claude/claude_desktop_config.json (macOS) or %APPDATA%\Claude\claude_desktop_config.json (Windows) |
| Cursor | npx -y javabytes-mcp config --client=cursor | ~/.cursor/mcp.json |
| VS Code | npx -y javabytes-mcp config --client=vscode | .vscode/mcp.json in your workspace |
Then set your real DB credentials:
# Optional: configure MySQL for live queries
export JAVABYTES_DB_URL=jdbc:mysql://localhost:3306/yourdb
export JAVABYTES_DB_USER=youruser
export JAVABYTES_DB_PASSWORD=yourpassword
# Restart the client / MCP server
The doctor command checks Java ≥ 21, the bundled jar, MySQL env, and npm updates.
The config command prints ready-to-paste JSON with placeholders — just update the
password and database URL, then restart your client.
Pick your path
The catalog holds 80 tools — enter through one task, not the catalog:
- "What's in my database?" — set
JAVABYTES_DB_URL(or passjdbc_urlper call), thenlist_tables→describe_table→analyze_schema_normalization. - "Port my JavaScript to Java." — load the
javabytes-migrateskill, or ask the server for its built-in crew prompts (prompts/list): recon, port, verify, report walk the whole loop. - "Build a backend / desktop app." — load
javabytes-backend(schema → REST API), then pair withjavabytes-desktopfor the JavaFX client. - "I only have an idea." — that is a valid starting point. Tell the
agent the idea;
javabytes-backendPhase 0 drafts the seed entities (plain SQL/JSON), then the standard chain runs — extract → normalize →generate_database→ REST app → JavaFX client. No commands to memorize. - "I need my defense document." —
javabytes-defensecompiles a defense-readyDOCUMENTATION.mdfrom evidence: title, introduction, objectives, scope and limitations, features with proof, database design with data dictionary, architecture, and anticipated panel questions.
Your first tool call (no client needed)
The server speaks JSON-RPC 2.0 on stdio, so any terminal can drive it — a good smoke test before wiring up a client:
echo '{"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"get_version"}}' | npx -y javabytes-mcp
You get back a result envelope with success: true and the server's version —
that is the whole protocol; every client does exactly this.
Windows cmd.exe: the outer single quotes above are PowerShell/bash syntax —
cmdpasses them through and the server answersParse error. Drop the quotes for cmd:echo {"jsonrpc":"2.0","id":1,"method":"tools/call","params":{"name":"get_version"}} | npx -y javabytes-mcp
If npx stalls or errors with a cache/lock message (EBUSY): install once
globally and run the binary directly —
npm install -g javabytes-mcp
javabytes-mcp doctor
Working across multiple databases
Coming from MySQL Workbench, your saved connections are just bookmarks —
JavaBytes doesn't need them. A connection card is a jdbc_url:
Workbench card: root @ 127.0.0.1:3306 / jenny
jdbc_url: jdbc:mysql://127.0.0.1:3306/jenny?user=root&password=...
Every database tool accepts a per-call jdbc_url, so one server session can
hop between schemas (URL-encode the password if it contains special
characters). Set JAVABYTES_DB_URL / JAVABYTES_DB_USER /
JAVABYTES_DB_PASSWORD to make one database the default and omit the
parameter entirely. To give an agent two databases simultaneously, add a
second MCP server entry with a different JAVABYTES_DB_URL — the tools stay
the same, the sandbox does not.
Build from source
mvn clean test # unit tests; live-MySQL tests run only with JAVABYTES_RUN_DB_TESTS=1
mvn package # produces target/javabytes.jar (shaded, runnable)
Run from source:
mvn -q exec:java
Run the shaded jar:
java -jar target/javabytes.jar
stdout is reserved for JSON-RPC. All logging goes to stderr.
Configuration
| Variable | Default | Purpose |
|---|---|---|
JAVABYTES_ALLOWED_DIRS | working dir + JVM temp dir | Fallback filesystem sandbox roots |
JAVABYTES_ENABLE | category defaults | Enable/disable tools by group or name |
JAVABYTES_DISABLE | category defaults | Disable specific tools |
JAVABYTES_LOG_FILE | unset | Optional JSON-RPC trace log |
JAVABYTES_DB_URL | jdbc:mysql://localhost:3306/appdb | MySQL JDBC URL |
JAVABYTES_DB_USER | app | MySQL user |
JAVABYTES_DB_PASSWORD | change-me | MySQL password |
Example:
JAVABYTES_ALLOWED_DIRS=/home/me/projects java -jar target/javabytes.jar
Tool groups and feature flags
Tools are grouped, and a group can be toggled without touching code:
| Group | Default | Contents |
|---|---|---|
files | on | sandboxed filesystem tools |
database | on | read-only MySQL query/list/describe |
system | on | system info, time conversion, version, tool list |
json | on | JSON path query |
javafx | on | off-screen canvas, drawing and PNG export |
analysis | on | code/UI/security/TODO analysis and Spring Boot inspection |
diagnostics | on | evidence-based project diagnostics |
ui, design, codegen, springboot | off | template generators |
A fresh server exposes 50 capability tools; the 30 template generators are opt-in
(JAVABYTES_ENABLE=all exposes all 80).
Enable or disable by group or by individual tool name:
# Add every Spring Boot and code generator
JAVABYTES_ENABLE=springboot,codegen java -jar target/javabytes.jar
# Everything, except one destructive tool
JAVABYTES_ENABLE=all JAVABYTES_DISABLE=delete_file java -jar target/javabytes.jar
Precedence, highest first: disabled by tool name → enabled by tool name → disabled group →
enabled group → all in the disable list → all in the enable list → the group default.
tools/list only advertises enabled tools; calling a disabled tool returns JSON-RPC -32602
with the flag needed to enable it.
Every tool descriptor also carries a title and MCP annotations (readOnlyHint,
destructiveHint, idempotentHint, openWorldHint) so clients can ask for confirmation or
auto-approve reads.
MCP roots
If the client advertises capabilities.roots, the server requests roots/list after
initialization and again after notifications/roots/list_changed. Usable file:// roots
replace the environment sandbox for the session, narrowing what file tools may touch. If the
client returns no usable roots, or the request fails, the JAVABYTES_ALLOWED_DIRS fallback
stays in effect. Filesystem roots such as C:\ and / are refused so a misconfiguration
cannot expose the whole disk.
Tool catalog
Capabilities
| Tool | What it does |
|---|---|
query_database | Read-only SQL (SELECT/SHOW/DESCRIBE/EXPLAIN/WITH), max 1000 rows |
list_tables | Tables and views |
describe_table | Column metadata; identifiers are validated and backtick-quoted |
javafx_init_canvas | Create an off-screen canvas |
javafx_draw_canvas | Draw rectangle/circle/line/text |
javafx_set_color | Set fill/stroke color |
javafx_clear_canvas | Clear the canvas |
javafx_export_image | Snapshot to a real PNG via SwingFXUtils + ImageIO |
project_diagnostic | Evidence-based dependency/configuration check |
analyze_springboot_project | Spring Boot layout inspection |
extract_data_models | Parse mongoose/prisma/sequelize/SQL/JSON data declarations into tables and columns, with per-field confidence and an honest limitations list |
models_to_schema | Convert parsed schema models into normalized schema proposals: proposed DDL, pass-through verdicts, and a verification list of medium/low-confidence fields |
generate_database | Execute proposed normalized DDL against a user-supplied JDBC URL to create the schema (creates only; refuses existing-table collision unless confirm=true) |
fix_javafx_headless | Adds the Monocle property (dry run by default; apply=true to write) |
create_mysql_client | Generates a self-contained JDBC helper that reads credentials from env |
get_system_info | JVM/OS/hardware info |
environment_variables | Read env vars; secret-like values masked unless reveal=true |
Filesystem (sandboxed)
read_text_file, write_file, list_directory, get_file_info, make_directory,
delete_file, search_files (glob + optional content regex), backup_file (no overwrite),
compare_files.
Convenience generators
generate_code, generate_tests, generate_docs, refactor_code, check_security,
find_todos, analyze_code, generate_css, generate_ui_code, generate_javafx_component,
extract_design_system, analyze_ui_layout, html_css_to_javafx_css, design_tokens,
anti_slop_review, translate_webapp, json_query, convert_time, get_version, list_services, and the
springboot_generate_* family (entity, repository, service, controller, DTO, properties,
security, relationship, actuator, exception handler, validation, pagination, file upload,
scheduled, async, cache, profile, docker, test).
These emit templates. They do not compile or run the result. Prefer prompting for anything
beyond their exact shape. All of them are disabled by default; enable them with
JAVABYTES_ENABLE=ui,design,codegen,springboot (or all).
Crew prompts (built-in migration manual)
Alongside tools the server advertises the MCP prompts capability and ships four prompt templates — the crew pack — mapped 1:1 to the java-anything pipeline phases:
recon— analyze the source app, choose the UI strategy with the human (ask-first wizard, ADR 0004/0013), produce the wave-ordered ticket list.port— translate the honest subset per unit, hand-write the rest, record cases for the gate.verify— run the migration gate per unit; a unit is done only when recorded behavior replays.report— assemble the Converted / Manual work / Unverified split; claims end where evidence ends.
Prompts are documentation: always advertised, never feature-gated, they call no tools and carry no logic. A drift test in CI asserts every tool name a prompt references still exists in the catalog, so renames can never silently break the crew manual.
Structured tool results
Every tool descriptor in tools/list carries a derived outputSchema — the result envelope as a
machine-checkable contract: success (boolean, required), error and message (optional
strings), tool-specific payload keys permitted. Successful tools/call results also carry
structuredContent: the envelope as a real JSON object, so typed clients (MCP Inspector,
FastMCP-style clients, IDE integrations) read results as data instead of re-parsing a string.
Error results omit structuredContent per the MCP spec; the envelope still travels in text
content, so text-reading clients see zero change. The schema is derived once in the same place
input schemas are rendered — no per-tool annotation, no drift, no new dependency (conformance is
a CI round-trip test, not a runtime validator).
Security model
- Path sandbox.
AppConfig.isPathAllowedrejects empty paths and null bytes, normalizes, resolves the real path of the deepest existing ancestor (so non-existent targets and symlinks are handled), and compares on component boundaries.C:\dev-evilnever matchesC:\dev. - Read-only SQL.
MyDatabaseClient.queryvalidates the statement, refuses multiple statements, sets the connection read-only, caps rows,(sf and applies a query timeout. - **Identifier validation.
describe_tableaccepts only plain identifiers orschema.table. - **Secret masking.
Environment variables whose names look like credentials are masked by default. Generated MySQL clients readDB_URL/DB_USER/DB_PASSWORD`; no password is written into source. - **Advisory diagnostics.
fix_allandfix_maven_dependenciesnever rewrite the project.fix_javafx_headlesswrites only withapply=true. - **Client roots.
When a client provides roots, they replace the environment sandbox. Roots that are notfile://, are not directories, or are filesystem roots (C:`,/) are ignored.
Tests
mvn test runs 146 tests covering the sandbox (traversal, null bytes, sibling-prefix),
directory creation results, glob and content search, CSS conversion, generated UI code, SQL
rejection, dependency false positives, error shapes, tool metadata completeness and
annotations, feature-flag precedence, client-root narrowing/reset, JS translation,
webapp translation with JavaFX CRUD views, scan-only and report-path modes, and Maven
Wrapper generation.
MySQL and JavaFX integration tests require a real database. Canvas export was verified
end-to-end over stdio (200x100 PNG, correct magic bytes). A 26-check stdio scenario also
covers roots negotiation, sandbox narrowing, roots/list_changed, disabled-tool errors,
launcher resolution, and annotations in tools/list.
Agent skills
skills/ holds agent skills that make the tool catalog usable without
reading it:
javabytes-setup— install, configure, troubleshoot.javabytes-tool-routing— which tool to call, in what order, and what counts as done.javabytes-convert— the JavaScript-to-Java pipeline: clone, scope, analyze, translate, report - with an honest manual-work inventory.javabytes-migrate— the evidence-loop migration (plan → port → record → replay → gate → report).javabytes-backend— the data layer and REST backend: schema extraction → normalized DDL → Spring Boot CRUD → verified running app.javabytes-desktop— JavaFX desktop apps: ask-first strategy, javafx target, per-entity CRUD views, headless-safe Prove step.javabytes-ui— design-system-aware UI generation: tokens, UI code, CSS, JavaFX CSS bridge, anti-slop review gate.javabytes-defense— defense-ready documentation compiled from evidence: objectives, scope, features with proof, data dictionary, panel prep.
Install them into an agent with:
npx skills@latest add markymakes-dev/javabytes
They are plain markdown; the server is still required for the tools themselves.
License
MIT — see LICENSE.
You may use, modify, and redistribute JavaBytes commercially. In return, the only obligation is keeping the copyright notice and licence text with copies.
The bundled mysql-connector-j is GPL-2.0 with the Universal FOSS Exception, which
permits redistribution inside an OSI-approved (MIT) program. If this project ever ships a
proprietary build, that dependency must be replaced (for example with
mariadb-java-client, LGPL-2.1) or licensed commercially from Oracle.
Frequently asked questions
What is JavaBytes MCP Server?
80 Java-focused tools for files, MySQL, JavaFX, Spring Boot and JS-to-Java migration, over stdio.
How do I install JavaBytes MCP Server in Claude Desktop, Cursor, or VS Code?
Pick your client in the Install section on this page and copy the generated config into the client's config file. Step-by-step guides: Claude Desktop, Cursor, and VS Code. JavaBytes MCP Server runs locally from the npm package javabytes-mcp with the command npx -y javabytes-mcp@1.5.2.
Is JavaBytes MCP Server free and open source?
Yes. JavaBytes MCP Server is released under the MIT license, an OSI-approved open-source license, so you can use, modify, and self-host it under those terms.
Does JavaBytes MCP Server support remote (HTTP) connections?
No remote endpoint is listed for JavaBytes MCP Server. It runs locally on your machine over stdio, started by your MCP client.
What tools does JavaBytes MCP Server provide?
JavaBytes MCP Server provides 17 tools, including analyze_springboot_project, create_mysql_client, describe_table, and environment_variables. See the full tool list for descriptions and parameters.
How is JavaBytes MCP Server's trust score calculated?
JavaBytes MCP Server scores 68 out of 100 (Good). The score adds six capped public signals: registry status, maintenance, popularity, license, documentation, and security. Nobody can pay for points. Read the methodology for the full formula.
Reviews
No reviews yet—Be the first to review
No published reviews yet. Used it? Tell the next person how it went.
Sign inA verified email is required to review this server.
Add badge to your README
Paste either snippet into the repository README. The image links to this listing.