Skip to main content
Glama
IIT Roorkee Academics MCP

IIT Roorkee Academics MCP

by goyalayus

IIT Roorkee Academics MCP

A local, role-aware Model Context Protocol server for the official IIT Roorkee Academics/AIS portal at https://academics.iitr.ac.in.

The server was built from a production-bundle audit rather than a short student-only menu scrape. Its checked-in catalog contains:

  • 577 backend operations across 23 API domains

  • 192 dashboard screens across student, faculty, advisor, DAPC, AAO, DoSW, department, HOD, library, and shared roles

  • Login, email/SMS OTP, in-memory session setup, forgot-password, reset-token verification, and password-reset support

  • Explicit fee, profile, semester-record, gradesheet, and transcript helpers

  • A safe generic caller covering every recovered endpoint, including operations added to the portal later

  • Catalog, route, coverage, and session resources plus reusable workflow prompts

Portal authorization is not bypassed. The signed-in IITR account can only use the roles and operations allowed by the portal backend.

Install and build

Requirements: Node.js 20 or newer.

npm install
npm run build

The stdio server entry point is:

node /absolute/path/to/iitr-academics-mcp/dist/index.js

For Codex CLI, register that command:

codex mcp add iitr-academics -- node /absolute/path/to/iitr-academics-mcp/dist/index.js

The server is also compatible with MCP hosts that accept a stdio command. Use node as the command and the absolute dist/index.js path as its argument.

Related MCP server: Nettskjema MCP Server

Authentication

The safest setup is to inject an existing portal session through the launch environment:

export IITR_AIS_USERNAME='your-enrollment-or-employee-id'
export IITR_AIS_ACCESS_TOKEN='your-current-AIS-AccessToken'
node dist/index.js

Do not commit these values or place them in a shared MCP configuration. They are intentionally absent from this repository.

Alternatively, call ais_auth_login, then ais_auth_verify_otp when the portal requires the 5-digit email/SMS OTP. The password and OTP are used only for their individual requests; the resulting token is held only in process memory.

Use ais_auth_status to check the session. It returns authentication source and token-expiry metadata, but never returns the token or decoded account claims.

MCP surface

Tool

Purpose

ais_auth_status

Show redacted session status

ais_auth_set_session

Set username and AccessToken in memory

ais_auth_login

Login with username/password

ais_auth_verify_otp

Finish email/SMS OTP login

ais_auth_send_sms_otp

Request the login OTP by SMS with confirmation

ais_auth_logout

Clear the in-memory session

ais_password_reset_request

Send reset email, behind a feature flag and confirmation

ais_password_reset_verify

Verify a reset token

ais_password_reset_complete

Complete reset, behind a feature flag and confirmation

ais_password_change

Change the authenticated account password using the portal cipher

ais_crypto_transform

Encrypt/decrypt AES, DES, TripleDES, or Rabbit portal payloads

ais_list_features

Search endpoints/screens by query, domain, role, or risk

ais_get_feature

Inspect one endpoint or route

ais_get_portal_route

Return a shareable dashboard screen URL

ais_list_external_portals

Return the academic services linked by AIS

ais_call

Invoke any cataloged or API-relative operation

ais_batch_read

Execute up to 20 non-mutating operations

ais_upload

Multipart upload with confirmation, path boundary, and size limit

ais_student_profile

Read and decrypt student profile data

ais_student_fee_status

Read current-semester fee status

ais_student_fee_details

Read and decrypt fee details and total

ais_student_semester_records

Read and decrypt semester history

ais_student_gradesheet

Prepare the portal request and decrypt gradesheet data

ais_student_transcript

Read and decrypt the authenticated student's transcript

Resources:

  • iitr://catalog/endpoints

  • iitr://catalog/routes

  • iitr://catalog/coverage

  • iitr://session/status

  • iitr://catalog/external-portals

Prompts:

  • ais-safe-operation

  • ais-fee-workflow

Calling an operation safely

  1. Call ais_list_features with a focused query.

  2. Inspect the selected operation with ais_get_feature.

  3. For a read, call ais_call with the required query or JSON body.

  4. For a mutation, review the exact endpoint and payload, obtain user confirmation, then set confirmWrite: true.

AIS often uses POST even for reads. The catalog records methods observed in the production client and separately classifies whether an operation mutates state. Seven unused environment constants have an explicit assumed-post method-evidence marker instead of being presented as observed calls.

Example read:

{
  "identifier": "DIRECT_FEE_BASE_URL_GETSTUDENTCURRENTSEMFEES",
  "body": {
    "EnrollmentNo": "YOUR_ENROLLMENT",
    "StSession": "2026-27",
    "Semester": "Autumn"
  }
}

Example route lookup:

{
  "route": "student-acad-fees-page"
}

Security controls

  • Requests are restricted to the configured Academics API origin and /api/ prefix by default.

  • Authentication follows the portal client exactly: username plus authorization: Bearer <AccessToken>.

  • Passwords, OTPs, tokens, cookies, authorization headers, and JWT-looking strings are recursively redacted from tool output.

  • Token storage is memory-only.

  • Mutating and uncataloged non-GET calls require confirmWrite: true.

  • Password mutation tools are disabled unless IITR_AIS_ENABLE_PASSWORD_TOOLS=1.

  • Response size and timeout limits are enforced.

  • Multipart files must stay under IITR_AIS_UPLOAD_ROOT and the total size limit.

  • Multipart symlinks are resolved before the upload-root check.

  • Authenticated requests and uploads reject redirects so credentials and files cannot be forwarded to another origin.

  • Custom headers are allowlisted; callers cannot replace authorization or cookie headers.

See SECURITY.md for the trust model and configuration controls.

Configuration

Copy .env.example only as a reference; this project does not automatically read .env files.

Variable

Default

Meaning

IITR_AIS_USERNAME

unset

Enrollment/employee/portal username

IITR_AIS_ACCESS_TOKEN

unset

Existing AIS AccessToken

IITR_AIS_API_BASE_URL

official /api/ URL

API base

IITR_AIS_PORTAL_URL

official portal URL

Dashboard URL base

IITR_AIS_TIMEOUT_MS

30000

Request timeout

IITR_AIS_MAX_RESPONSE_BYTES

10485760

Maximum response size

IITR_AIS_UPLOAD_ROOT

process working directory

Only local tree allowed for multipart files

IITR_AIS_MAX_UPLOAD_BYTES

26214400

Maximum total bytes per multipart call

IITR_AIS_ALLOW_UNSAFE_URLS

0

Permit calls outside the official API boundary

IITR_AIS_ENABLE_PASSWORD_TOOLS

0

Enable password-reset mutations

IITR_AIS_DEBUG

0

Write startup diagnostics to stderr

Verification

npm run typecheck
npm test
npm run build
npm audit

The completion audit asserts that every recovered endpoint resolves through ais_call, every recovered screen resolves through ais_get_portal_route, all URLs remain under the official API origin, method evidence is explicit (observed or assumed-post), and all catalog identifiers are unique.

For the domain-by-domain breakdown, see COVERAGE.md.

Scope and portal changes

The catalog is a snapshot of the production Angular client audited on 10 July 2026. ais_call accepts a safe API-relative path as an escape hatch for new backend operations before the catalog is refreshed. The production portal remains the source of truth for accepted payload fields and account permissions.

Available Tools

24 tools
ais_auth_loginLog In to IITR AISA

Submit enrollment/employee username and password to AIS. If OTP is required, finish with ais_auth_verify_otp. Credentials are retained only for the request.

Inputs: password (required), username (required).

ais_auth_logoutClear AIS SessionA
Idempotent

Forget the in-memory AIS session. The current portal has no remote logout endpoint.

Inputs: no named parameters.

ais_auth_send_sms_otpSend AIS Login OTP by SMSA

Ask AIS to send the current login OTP by SMS. This transmits the username and requires explicit confirmation.

Inputs: confirm (required), username.

ais_auth_set_sessionSet Existing AIS SessionA
Idempotent

Set an existing portal username and AccessToken in process memory. Prefer environment variables because MCP tool arguments may be logged by clients.

Inputs: username (required), accessToken (required).

ais_auth_statusAIS Authentication StatusA
Read-only

Show whether this MCP process has an IITR AIS session. Tokens are never returned.

Inputs: no named parameters.

ais_auth_verify_otpVerify AIS Login OTPA

Verify the 5-digit IITR email/SMS OTP and establish an in-memory AIS session.

Inputs: otp (required), username.

ais_batch_readBatch Read IITR AISA
Read-only

Run up to 20 cataloged non-mutating operations sequentially. POST-based reads are supported.

Inputs: requests (required).

ais_callCall Any IITR AIS OperationA
Destructive

Call a cataloged endpoint by symbol/alias/URL, or an API-relative path. Cataloged mutations and uncataloged non-GET calls require confirmWrite=true.

Inputs: identifier (required), body, query, method, +3 more.

ais_crypto_transformTransform AIS Encrypted PayloadC
Read-only

Encrypt or decrypt an AIS payload with CryptoJS-compatible AES, DES, TripleDES, or Rabbit. Session-key mode derives the portal key from the active AccessToken.

Inputs: value (required), operation (required), key, algorithm, +1 more.

ais_get_featureGet IITR AIS FeatureA
Read-only

Resolve one endpoint symbol/alias/URL or one dashboard route.

Inputs: identifier (required).

ais_get_portal_routeGet AIS Screen URLA
Read-only

Return the shareable dashboard URL for a cataloged AIS screen. The recipient must log in with their own permissions.

Inputs: route (required).

ais_list_external_portalsList IITR Academic PortalsA
Read-only

Return the external academic services linked by the production AIS login/dashboard.

Inputs: no named parameters.

ais_list_featuresList IITR AIS FeaturesB
Read-only

Search the production-derived endpoint and screen catalog by text, API domain, portal role, or mutation status.

Inputs: kind, role, limit, query, +3 more.

ais_password_changeChange Authenticated AIS PasswordC
Destructive

Change the current account password using the portal's encrypted changeAuthPass protocol.

Inputs: confirm (required), newPassword (required), currentPassword (required).

ais_password_reset_completeComplete AIS Password ResetA
Destructive

Submit the reset token and new-password payload to AIS. Requires explicit confirmation and the password-tools feature flag.

Inputs: confirm (required), payload (required).

ais_password_reset_requestRequest AIS Password ResetA

Send an AIS password-reset email. Requires explicit confirmation and the password-tools feature flag.

Inputs: email (required), confirm (required).

ais_password_reset_verifyVerify AIS Password Reset TokenA
Read-only

Verify a password-reset token without changing the password.

Inputs: payload (required).

ais_student_fee_detailsGet Student Fee DetailsC
Read-only

Read and decrypt current-semester fee details and the total returned by AIS.

Inputs: payload.

ais_student_fee_statusGet Student Fee StatusB
Read-only

Read the current-semester fee status from the official AIS fees service.

Inputs: payload.

ais_student_gradesheetGet Student GradesheetB
Read-only

Read and decrypt semester gradesheet data. Pass EnrollmentNo, semRecrdid, SemesterID, StSession, and Semester from a semester record.

Inputs: payload.

ais_student_profileGet Student ProfileA
Read-only

Read and decrypt student personal/profile information; pass the fields required by the portal, usually Enrollment.

Inputs: payload.

ais_student_semester_recordsGet Semester RecordsC
Read-only

Read and decrypt a student's semester records from the endpoint used by the student screens.

Inputs: payload.

ais_student_transcriptGet Student TranscriptC
Read-only

Read and decrypt the authenticated student's transcript data from the endpoint used by the student transcript screen.

Inputs: payload.

ais_uploadUpload a File to IITR AISC

Call a cataloged multipart upload operation. Every file must be inside IITR_AIS_UPLOAD_ROOT and the total must fit IITR_AIS_MAX_UPLOAD_BYTES.

Inputs: files (required), identifier (required), confirmWrite (required), query, +3 more.

Tool Schema Changelog

Recent tool additions, removals, and schema changes observed during successful MCP inspections.

Loading tool schema changelog…

    TDQS

    A3.5/5.0

    Scored across 24 tools

    Disambiguation5/5

    Each tool has a clearly distinct purpose, covering authentication steps, batch operations, cataloged calls, crypto, feature retrieval, password management, and various student data endpoints. No overlapping tool functions; descriptions are precise.

    Naming Consistency5/5

    All tools follow a consistent 'ais_verb_noun' pattern in snake_case, making it easy to predict functionality from the name. No mixing of conventions or odd abbreviations.

    Tool Count4/5

    With 24 tools, the count is slightly high but still reasonable for a comprehensive academic portal. Each tool serves a specific function, and the scope justifies the number.

    Completeness4/5

    The tool surface covers core workflows: authentication, password management, student data retrieval (fees, grades, transcript, profile, semester records), feature catalog browsing, and file upload. Minor gaps exist (e.g., no course registration or direct profile update), but the essential operations are present.

    Related MCP Connectors

    Related MCP Servers