Saju MCP Server
Integrates with VS Code (GitHub Copilot) to provide Saju astrology tools for calculating and interpreting charts, compatibility, and daily fortune within the editor.
Click on "Install 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., "@Saju MCP ServerCalculate my four pillars for May 15, 1990 at 2pm"
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.
Saju MCP — Korean Four Pillars & BaZi Astrology
An MCP (Model Context Protocol) server that wraps the Saju API — Korean Four Pillars of Destiny (사주팔자 / BaZi / 八字) — so any MCP-capable AI client (Claude Desktop, Cursor, VS Code, Windsurf, and custom agents) can compute, interpret, and compare Korean Saju charts directly in a conversation.
SAJU_API_KEY="sajuapi_free_xxx" npx saju-mcp30-second path: get a free key → add the config → ask your AI client "calculate the saju for someone born 1990-05-15 14:00, male."
Why this MCP?
The only production-grade Korean Saju engine available as an MCP server.
KASI-validated lunar conversion (47,000+ days cross-checked, zero failures).
Ten Gods (十神) + Yongshin (用神) + Daeun (大運) — interpretive features absent from generic Western astrology APIs that only return sun/moon signs.
10 output languages: Korean, English, Japanese, Chinese, Spanish, Portuguese, Vietnamese, Indonesian, Hindi, Thai.
Free tier: 100 requests/day, no credit card. Freemium — start building today and upgrade only when your app needs production volume.
Backed by the live API at https://saju-api.pages.dev.
Related MCP server: Chinese Fortune Analysis System (BaZi)
What it looks like in practice
Ask your AI client a natural-language question; it calls saju_calculate and gets
back structured data it can reason over. This is a real, unedited response from
the live API for { year: 1990, month: 5, day: 15, hour: 14, gender: "M", lang: "en" }:
{
"pillars": {
"year": { "stem": "경", "branch": "오", "stem_hanja": "庚", "branch_hanja": "午" },
"month": { "stem": "신", "branch": "사", "stem_hanja": "辛", "branch_hanja": "巳" },
"day": { "stem": "경", "branch": "진", "stem_hanja": "庚", "branch_hanja": "辰" },
"hour": { "stem": "계", "branch": "미", "stem_hanja": "癸", "branch_hanja": "未" }
},
"elements": { "wood": 0, "fire": 2, "earth": 2, "metal": 3, "water": 1 },
"day_master": { "stem": "경", "element": "metal", "polarity": "yang" },
"zodiac": "horse",
"tier": "free",
"remaining": 99
}Every response is returned to the model as both human-readable text and
structuredContent, so agents can branch on day_master.element, elements, a
compatibility score, etc. without re-parsing prose.
Tools
Tool | Upstream endpoint | What it does |
|
| Four Pillars (stem+branch+hanja), five-element distribution, Day Master, zodiac, from a solar birthdate. |
|
| Full reading: Ten Gods (십신), hidden stems, Yongshin (용신), Daeun (대운), localized summaries. |
|
| Two-person 궁합 score (0–100) with breakdown (element balance, Day Master relation, branch harmony/clash). |
|
| Daily fortune snapshot (score + advice) for a Day Master and date. |
Quickstart
1. Get a free API key (no card)
The free tier is 100 requests/day, no credit card:
curl -X POST https://saju-api.pages.dev/api/v1/keys/create \
-H "Content-Type: application/json" \
-d '{"email":"dev@yourcompany.com"}'The response contains an api_key of the form sajuapi_free_...:
{
"api_key": "sajuapi_free_XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
"tier": "free",
"daily_limit": 100,
"rps": 1,
"monthly_price_usd": 0,
"note": "Store this key safely — it is shown only once. Send with header `X-API-Key: <key>`."
}The key is shown only once — store it now. It is passed to the server via the
SAJU_API_KEYenvironment variable, never hardcoded. (Disposable /example.comemail domains are rejected — use a real address.)
2. (Optional) Smoke-test without an MCP client
npx runs the server straight from npm — no clone, no local build:
SAJU_API_KEY="sajuapi_free_xxx" npx -y saju-mcpIt speaks MCP over stdio and exposes the four saju_* tools. Press Ctrl-C to exit.
3. Register in your MCP client
The server is stdio-based, so every MCP client uses the same three pieces:
command: npx, args: ["-y", "saju-mcp"], and an env with your SAJU_API_KEY.
Edit your config file, then restart Claude Desktop:
macOS:
~/Library/Application Support/Claude/claude_desktop_config.jsonWindows:
%APPDATA%\Claude\claude_desktop_config.json
{
"mcpServers": {
"saju": {
"command": "npx",
"args": ["-y", "saju-mcp"],
"env": { "SAJU_API_KEY": "sajuapi_free_your_key_here" }
}
}
}Add to ~/.cursor/mcp.json (global) or .cursor/mcp.json (per-project), then
reload:
{
"mcpServers": {
"saju": {
"command": "npx",
"args": ["-y", "saju-mcp"],
"env": { "SAJU_API_KEY": "sajuapi_free_your_key_here" }
}
}
}Add to .vscode/mcp.json in your workspace:
{
"servers": {
"saju": {
"command": "npx",
"args": ["-y", "saju-mcp"],
"env": { "SAJU_API_KEY": "sajuapi_free_your_key_here" }
}
}
}Add to ~/.codeium/windsurf/mcp_config.json, then refresh MCP servers:
{
"mcpServers": {
"saju": {
"command": "npx",
"args": ["-y", "saju-mcp"],
"env": { "SAJU_API_KEY": "sajuapi_free_your_key_here" }
}
}
}Restart / reload your client. The four saju_* tools appear in its tool list.
Example tool inputs
saju_calculate / saju_interpret:
{ "year": 1990, "month": 5, "day": 15, "hour": 14, "gender": "M", "lang": "en" }(hour: -1 if the birth hour is unknown.)
saju_compatibility:
{
"person_a": { "year": 1990, "month": 5, "day": 15, "hour": 14, "gender": "M" },
"person_b": { "year": 1992, "month": 8, "day": 3, "hour": 9, "gender": "F" },
"lang": "en"
}saju_daily (Day Master from a prior calculate/interpret call):
{ "day_master": "갑", "date": "2026-06-17", "lang": "en" }Input bounds (validated server-side, mirrors the API): year 1920–2050,
month 1–12, day 1–31, hour -1–23, gender "M"|"F", lang one of the 10
supported codes (default ko).
Environment variables
Variable | Required | Default | Notes |
| yes (for real calls) | (empty) | Your |
| no |
| Override the upstream base URL (e.g. a staging deploy). |
Errors & troubleshooting
When an upstream call fails, the tool returns an MCP error result (isError: true)
whose text is Saju API error <status>: <body> plus a hint. Common cases:
Symptom | HTTP status | Cause | Fix |
| 401 |
| Set the env var to a valid |
| 429 | Free tier is 100 req/day, 1 rps. | Wait for the daily reset, or upgrade to a paid tier for production volume. |
| 400 | A field is out of bounds (e.g. | Check the input bounds above; the |
Tools don't appear in the client | — | Client not restarted, or | Restart the client; run |
| any | Upstream returned non-JSON (rare; network/proxy). | Retry; if persistent, check |
Keys never appear in tool output or logs. If a key leaks, mint a new one — the old one keeps its own quota and can be abandoned.
Develop / build from source
git clone https://github.com/ghdejr11-beep/saju-mcp.git
cd saju-mcp
npm install
npm run build # compiles src/index.ts -> dist/index.js
npm run typecheck # tsc --noEmitRun the local build directly:
{
"mcpServers": {
"saju": {
"command": "node",
"args": ["/absolute/path/to/saju-mcp/dist/index.js"],
"env": { "SAJU_API_KEY": "sajuapi_free_your_key_here" }
}
}
}Requires Node.js 18+ (uses the built-in global fetch).
Upgrading to production
The free tier (100 req/day, 1 rps) is for building and evaluation. When your app ships, higher-volume tiers are available on the same API — see https://saju-api.pages.dev for current plans and the key endpoint. Your code and config don't change; only the key does.
Related
Korea Calendar API — Korean public holidays, lunar↔solar conversion, the gapja (간지) pillars and the 24 solar terms over REST. Pairs naturally with this server when you need the raw calendar facts behind a saju reading: https://korea-calendar-api.kunstudio.workers.dev
License
Proprietary — KunStudio. Wraps the Saju API; subject to that API's terms.
Available Tools
4 toolssaju_calculateCalculate Saju (Four Pillars)A
Compute the Korean Four Pillars of Destiny (사주팔자 / Bazi) from a solar birthdate. Returns the year/month/day/hour pillars (heavenly stem + earthly branch, with hanja), the five-element distribution (wood/fire/earth/metal/water), the Day Master, and the zodiac animal.
| Name | Required | Description | Default |
|---|---|---|---|
| day | Yes | Birth day, 1–31 | |
| hour | Yes | Birth hour in 24h time (0–23). Use -1 if the hour is unknown. | |
| lang | No | Output language (default ko). One of: ko, en, ja, zh, es, pt-br, vi, id, hi, th | |
| year | Yes | Solar (Gregorian) birth year, 1920–2050 | |
| month | Yes | Birth month, 1–12 | |
| gender | Yes | Gender: 'M' or 'F' (affects Daeun / luck-pillar direction). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
With no annotations, the description fully describes the output: pillars (with hanja), element distribution, Day Master, and zodiac animal. It also notes that input must be a solar birthdate, a key behavioral constraint. The description is transparent about what the tool returns, though it omits details like required permissions or rate limits (likely irrelevant).
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 consists of two succinct sentences: the first states the action and input, the second lists the outputs. Every word serves a purpose, and the structure is front-loaded with the key verb and resource.
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 6 parameters and no output schema, the description adequately covers the return values and the critical 'solar birthdate' requirement. It lacks information about error handling or edge cases (e.g., invalid date), but for a calculation tool that's acceptable. The completeness is high for the complexity level.
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 100%, so the description does not need to add parameter details. It mentions output components but does not clarify parameter semantics beyond the schema. For instance, the effect of gender on 'luck-pillar direction' is noted in the schema but not reinforced in the description. Baseline 3 is appropriate.
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 verb 'Compute' and the resource 'Korean Four Pillars of Destiny' from a solar birthdate. It lists the outputs, making the purpose unambiguous. However, it does not explicitly differentiate from sibling tools like saju_compatibility or saju_interpret, which would require an additional sentence to achieve a 5.
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 provides no guidance on when to use this tool versus its siblings (saju_compatibility, saju_daily, saju_interpret). It does not mention prerequisites, contexts, or exclusions. The agent must infer usage from the name alone.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
saju_compatibilitySaju Compatibility (궁합)A
Score two-person compatibility (궁합) from 0–100 based on both people's Saju. Returns the overall score and a breakdown (element balance, Day Master relation, branch harmony, branch clash) plus each person's Day Master and zodiac.
| Name | Required | Description | Default |
|---|---|---|---|
| lang | No | ||
| person_a | Yes | First person (birth details). | |
| person_b | Yes | Second person (birth details). |
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 the return structure (overall score, breakdown components) but does not mention any side effects, authentication needs, or limitations. Since it is a computational tool with no destructive actions, this is adequate but minimal.
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 a single, front-loaded sentence that conveys purpose, output range, and breakdown components without any unnecessary words.
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 complex input (two nested objects) and no output schema, the description fully explains the return value: overall score and a breakdown of four components plus each person's Day Master and zodiac. This is complete for an agent to understand what the tool provides.
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 schema already provides descriptions for parameters (lang, person_a, person_b with full details). The description adds no new parameter-specific information beyond 'based on both people's Saju'. With high schema coverage (67%+), a baseline of 3 is appropriate.
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 computes a two-person compatibility score from 0-100, and specifies the return includes overall score and breakdown. It distinguishes from siblings that are about individual saju calculation or daily interpretation.
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 indicates the tool is for scoring two-person compatibility, implying use when needing compatibility between two individuals. It does not explicitly state when not to use or name alternatives, but context from sibling tools makes it evident.
Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.
saju_dailyDaily Fortune SnapshotA
Daily fortune snapshot (0–100 score + advice) for a given Day Master and date. Provide the Day Master either as a Korean stem character (갑, 을, 병, 정, 무, 기, 경, 신, 임, 계) or an English alias (e.g. wood_yang, water_yin). The Day Master comes from a prior saju_calculate / saju_interpret call (day_master.stem).
| Name | Required | Description | Default |
|---|---|---|---|
| date | No | Target date in YYYY-MM-DD. Defaults to today (UTC). | |
| lang | No | Output language (default ko). One of: ko, en, ja, zh, es, pt-br, vi, id, hi, th | |
| day_master | Yes | Day Master: Korean stem (갑..계) or English alias (wood_yang, wood_yin, fire_yang, ... water_yin). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations provided. Description mentions output is a score (0-100) and advice, implying a read-only operation. Does not disclose details like rate limits, authentication, or side effects, but the tool's purpose is non-destructive.
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 sentences, front-loaded with purpose, followed by concise input guidance. No redundant words; every sentence is necessary.
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 three parameters and no output schema, the description covers purpose, input source, and output type (score + advice). Could optionally mention response structure or error handling, but current level suffices for selection and use.
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 100% and schema descriptions are adequate. The description adds value by clarifying the origin of the day_master parameter (from saju_calculate/interpret) and listing valid Korean stems and English aliases, which aids correct invocation.
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?
Title and description clearly state the tool returns a daily fortune score and advice based on Day Master and date. It is distinct from sibling tools (saju_calculate, saju_interpret, saju_compatibility) which handle calculation, interpretation, or compatibility.
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?
Explicitly instructs users to obtain the Day Master from prior saju_calculate or saju_interpret calls and provides valid input formats (Korean stem or English alias). Missing explicit when-not-to-use instructions but 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.
saju_interpretInterpret Saju (Ten Gods, Yongshin, Daeun)A
Full Saju interpretation from a solar birthdate: the Four Pillars plus Ten Gods (십신), hidden stems, life stages, interactions, Yongshin (용신 / useful god), Daeun (대운 / luck pillars), and human-readable summaries in the requested language.
| Name | Required | Description | Default |
|---|---|---|---|
| day | Yes | Birth day, 1–31 | |
| hour | Yes | Birth hour in 24h time (0–23). Use -1 if the hour is unknown. | |
| lang | No | Output language (default ko). One of: ko, en, ja, zh, es, pt-br, vi, id, hi, th | |
| year | Yes | Solar (Gregorian) birth year, 1920–2050 | |
| month | Yes | Birth month, 1–12 | |
| gender | Yes | Gender: 'M' or 'F' (affects Daeun / luck-pillar direction). |
TDQS
Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?
No annotations are provided, so the description carries full burden. It discloses the tool produces a full interpretation with human-readable summaries but does not mention any performance, determinism, or other behavioral traits. However, it is not misleading.
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 a single sentence that front-loads the main purpose ('Full Saju interpretation') and lists components. It is somewhat lengthy but efficient for the information conveyed.
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 lack of an output schema, the description compensates by detailing output components (Ten Gods, life stages, luck pillars, etc.) and language support. This provides sufficient context for an agent to understand what the tool returns.
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 100%, so the description adds no extra meaning beyond the well-documented parameters (year, month, day, hour, gender, lang). Baseline of 3 is appropriate.
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 it performs a full Saju interpretation from a solar birthdate, listing specific components like Four Pillars, Ten Gods, hidden stems, etc. This distinguishes it from sibling tools such as saju_calculate (basic pillars) and saju_compatibility (pair analysis).
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 it is the comprehensive interpretation tool. While not explicitly stating when to use alternatives, the tool name and sibling names provide clear context that this is for full readings vs. calculated pillars or compatibility.
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. Dates show when Glama detected each change.
4 tool updates
v0.1.0- First observed
saju_calculate - First observed
saju_compatibility - First observed
saju_daily - First observed
saju_interpret
TDQS
Each tool has a clearly distinct purpose: calculation, compatibility, daily fortune, and full interpretation. No overlap or ambiguity.
All tools follow the consistent prefix 'saju_' with descriptive verbs/adjectives in snake_case, creating a predictable pattern.
Four tools is perfectly scoped for a niche domain like saju, covering core functionalities without excess or deficiency.
The set provides a complete lifecycle: calculation, interpretation, compatibility, and daily fortune. No obvious gaps.
Maintenance
Resources
Unclaimed servers have limited discoverability.
Looking for Admin?
If you are the server author, to access and configure the admin panel.
Related MCP Connectors
Korean saju fortune MCP: natal chart, today/daily/yearly luck, compatibility, and saved profiles.
Deterministic Korean Saju / BaZi Four Pillars MCP. Day Master, five elements, compatibility.
Korean Four Pillars (Saju/BaZi) calculator: pillars, elements, ten gods, sinsal, luck cycles.
BaZi (八字) MCP gateway + 玄学社区. 12 tools (4 fortune + 5 forum + 3 meta). x-api-key required.
Related MCP Servers
- FlicenseCqualityFmaintenanceProvides Korean traditional Saju (Four Pillars of Destiny) fortune-telling analysis including birth chart calculations, compatibility checks, daily/yearly fortunes, calendar conversions, and personalized life advice based on ancient Eastern astrology.741-
- AlicenseNot gradedqualityDmaintenanceEnables traditional Chinese fortune-telling through BaZi (Four Pillars) analysis, including solar/lunar date conversion, Five Element balance calculations, Ten Gods deduction, and destiny interpretation for metaphysics applications.34MIT
- AlicenseAqualityDmaintenanceEnables Korean Saju (Four Pillars of Destiny) calculation and myeongni-hak glossary lookup via MCP, allowing AI clients to compute accurate saju analysis and look up fortune-telling terms.459MIT
- FlicenseNot gradedqualityBmaintenanceEnables traditional Chinese metaphysics tools like Bazi, Ziwei, and Qimen via MCP, integrating AI analysis for divination and fortune-telling.516-
Latest Blog Posts
- Who's Calling? MCP Hosts Are an Identity Blind Spot (And the Spec Knows It)By Om-Shree-0709 on .mcpAgent IdentityOAuth 2.1
- Your AI Chatbot Just Exposed Your CEO's Salary to an InternBy Om-Shree-0709 on .Agent IdentityMCP SecurityOAuth Delegation
- Why MCP Servers Need Execution Sandboxing (And Why Your Current Stack Isn't Enough)By Om-Shree-0709 on .Agentic AiPrompt InjectionWebAssembly
MCP directory API
We provide all the information about MCP servers via our MCP API.
curl -X GET 'https://glama.ai/api/mcp/v1/servers/ghdejr11-beep/saju-mcp'
If you have feedback or need assistance with the MCP directory API, please join our Discord server