TPCU MCP Server
This server does not currently have a deployable release on Glama. Follow the repository's setup instructions to install and configure it for your MCP client, including any required credentials and local dependencies.
tpcu-mcp
English | 繁體中文
An MCP server for the student information system of TPCU (Taipei City University of Science and Technology). It exposes the timetable, absences, grades, leave requests and work-study attendance as MCP tools, so an MCP client (Claude Code, Claude Desktop, Codex CLI, Gemini CLI, ...) can query and act on them in a conversation:
"What classes do I have today?" "Any absences lately?" "Request personal leave for my absences on 10/12." "Fill in this month's work-study hours."
TypeScript and the official
@modelcontextprotocol/sdk, stdio transport, no backend of its own.Talks HTTP to
siw.tpcu.edu.twdirectly and parses the HTML.The AI asks you for your student ID and password through the
logintool; they stay in memory only and are never written to disk or logs.
Unofficial. This project is not affiliated with TPCU. Read the security policy and decide for yourself whether to give your credentials to an AI client.
Install
git clone https://github.com/alaner652/tpcu-mcp.git
cd tpcu-mcp
npm install
npm run build # writes dist/Node.js 20 or later is required.
Related MCP server: AnythingBUAA
Connect a client
Replace /absolute/path/to/tpcu-mcp with your clone.
Claude Code
claude mcp add --scope user tpcu -- node /absolute/path/to/tpcu-mcp/dist/index.jsClaude Desktop
~/Library/Application Support/Claude/claude_desktop_config.json:
{
"mcpServers": {
"tpcu": {
"command": "node",
"args": ["/absolute/path/to/tpcu-mcp/dist/index.js"]
}
}
}Codex CLI
~/.codex/config.toml:
[mcp_servers.tpcu]
command = "node"
args = ["/absolute/path/to/tpcu-mcp/dist/index.js"]Gemini CLI
~/.gemini/settings.json: same JSON as Claude Desktop.
After changing src/, run npm run build and reconnect the client.
Example
You: Any absences lately?
AI: (get_session_status -> not signed in -> asks for ID and password -> login -> fetch_absence)
7 periods in the last 30 days: 10/12 (Mon) periods 6-8, 10/14 (Wed) periods 3-6 ...
You: Request personal leave for 10/12, family matters.
AI: (get_leave_form -> lists date, periods, leave type and reason for you to confirm)
You: Confirm.
AI: (apply_leave) Submitted; waiting for your homeroom teacher.Environment variables (all optional)
Variable | Default | Meaning |
|
| School system endpoint |
|
| Timeout per request to the school |
|
|
|
| none | When set, |
An invalid setting stops the server at start-up with the reason (never the value) on stderr.
Tools
Tool | Sign-in | Side effect | Purpose |
| - | - | Sign in; returns name, student ID and current semester |
| - | - | Clear the in-memory session (only when the user asks) |
| - | - | Whether you are signed in, and the current semester |
| - | - | Today in Taipei time, AD and ROC |
| yes | - | Semesters available |
| yes | - | Whole-semester timetable |
| yes | - | Classes on one day (default today) |
| yes | - | The class now or next |
| yes | - | Absences in a date range (default last 30 days) |
| yes | - | Grades for all years |
| yes | - | Leave requests and their approval status |
| yes | - | Periods on a date and which have classes |
| yes | creates | Submit a leave request (official leave needs an attachment) |
| yes | irreversible | Withdraw a pending leave request |
| yes | - | Work-study months, unit and job codes, status |
| yes | - | Existing attendance rows of a month |
| optional | - | Expand a fixed weekly shift pattern into a month, skipping class times |
| yes | overwrites month | Submit a month of work-study attendance |
Every tool carries MCP annotations (readOnlyHint / destructiveHint). Tools with side effects tell the host model to confirm with the user first.
Quick reference
Dates: tool parameters use ROC compact
YYYMMDD, e.g.1150521= 2026-05-21. AD = ROC + 1911.Semester code:
114,2= academic year 114, semester 2.Leave types: 21 personal, 22 sick, 23 official (military service, court, national exams, department; JPEG or PDF attachment), 24 bereavement, 25 marriage, 26 maternity, 27 nursing, 28 epidemic, 29 menstrual, 31 indigenous.
Work-study: at most 7.5 hours a day and one row per day; saving overwrites the whole month, so rows to keep (with
seq) must be sent again.
Errors
A failed tool returns isError: true with:
{ "error": { "code": "SESSION_EXPIRED", "message": "學校系統 session 已過期", "hint": "請重新呼叫 login 工具。" } }code | Meaning |
| Bad parameters (usually caught by the schema first) |
|
|
| Wrong credentials or the school is busy |
| The school ended the session; sign in again |
| Connection or HTTP error from the school |
| Missing prerequisite (e.g. no |
| Leave business errors (in |
| Unexpected; details only on stderr |
Documentation
See docs/: architecture, development, project status.
Credits and license
The business logic (page flows, field names, parsing rules, shift planning) comes from the author's Agora-AI project (Python / FastAPI), reimplemented here in TypeScript as a standalone MCP server.
GNU AGPL v3.0 or later © 2026 small R (alaner652)
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
This server cannot be deployed
Maintenance
Related MCP Connectors
Connect any AI agent to 1,000+ apps and 27,000+ actions through one remote MCP server (OAuth).
Automate 1,000+ services from any MCP-compatible AI agent: build Applets, run actions and queries.
AI から使えるクラウドグループウェア Work Handler の MCP サーバー。組織・メンバーの参照、出退勤の共有、タイムカード、承認フロー等を本人の権限の範囲で操作できる。
AI-native scheduling: check availability, book meetings, cancel and reschedule via MCP
Related MCP Servers
- FlicenseAqualityDmaintenanceEnables interaction with Zhejiang University's learning platform (学在浙大 / 智云课堂) via MCP tools, allowing natural language commands to check todos, view schedules, fetch lecture transcripts, and submit homework.79-
- AlicenseNot gradedqualityBmaintenanceEnables AI assistants to carry out campus services in natural language — booking venues with CAPTCHA solving, selecting and dropping courses, submitting homework, batch-completing teaching evaluations, checking grades and timetables, and fetching cloud-drive download links — by handling the login, signing, encryption, and WebVPN proxying for 11 separate university subsystems behind 26 MCP tools.2MIT
- AlicenseBqualityBmaintenanceEnables AI clients to access a student's class schedule, empty classroom availability, campus card balance, extracurricular activities, library seats, and e-station guides, while keeping credentials local and requiring explicit confirmation for bookings and registrations.25MIT
- AlicenseNot gradedqualityBmaintenanceEnables AI coding assistants to query a student's eLearning assignments and deadlines, timetable, exams, grades, library resources, notices, campus card balance, dorm electricity, and read-only mail, and to download course files.28 npm5MIT