About mainframe-mcp-server
MCP server for IBM z/OS jobs, datasets, USS, and operational diagnostics via Zowe SDK.
Configuration
Local server config is the same for every client. Copy it into your client’s MCP config file.
npx -y @notharshhaa/mainframe-mcp-serverZOSMF_HOSTz/OSMF hostname or IP addressZOSMF_PORTz/OSMF HTTPS port (default 443)ZOSMF_BASE_PATHOptional API gateway or mediation layer prefix for z/OSMFZOSMF_USERz/OS user id (required with ZOSMF_PASSWORD unless ZOSMF_TOKEN is set)ZOSMF_PASSWORDSecretPassword for basic auth (required with ZOSMF_USER unless ZOSMF_TOKEN is set)ZOSMF_TOKENSecretAuth token (alternative to user/password)ZOSMF_TOKEN_TYPESecretToken type when using ZOSMF_TOKEN (e.g. LTPA2)ZOSMF_REJECT_UNAUTHORIZEDSecretVerify TLS certificates (true in production)ZOSMF_CERTPEM client certificate file path for mTLS authZOSMF_CERT_KEYSecretPEM client key file path for mTLS auth (required with ZOSMF_CERT)ZOSMF_TOKEN_FILESecretRead ZOSMF_TOKEN from this file at startup (vault/agent injection)ZOSMF_USER_IDEnd-user id for PassTicket identity propagation (RACF sees this user, not the service account)ZOSMF_PASSTICKET_APPRACF PTKTDATA application name for PassTicket generation (default ZOSMF)ZOWE_TEAM_CONFIGPath to a zowe.config.json to import connection settings from (env vars win)ZOSMF_PROFILEProfile name inside the Zowe team config (defaults to defaults.zosmf)LOG_LEVELLog level: fatal, error, warn, info, debug, trace, silentMCP_TRANSPORTTransport: stdio (IDE) or sse (legacy HTTP+SSE for container/network deployments)MCP_SSE_PORTListen port when MCP_TRANSPORT=sseMAX_JOB_OUTPUT_LINESMax lines returned from a single spool DDMAX_DATASET_READ_LINESMax lines returned from dataset or USS readsMAX_JES_SPOOL_FILESMax spool files fetched during diagnosticsMAX_AUDIT_LINESMax RACF audit log lines per queryCMCI_CONTEXTCICSplex name or region APPLID (required for CICS tools)CMCI_HOSTCMCI hostname (defaults to ZOSMF_HOST)CMCI_PORTCMCI HTTPS port (default 1490)CMCI_BASE_PATHCMCI REST base pathDB2_LOCATIONDb2 subsystem location name (required for Db2 tools)DB2_HOSTDb2 REST hostname (defaults to ZOSMF_HOST)DB2_PORTDb2 REST port (default 50400)DB2_BASE_PATHDb2 REST base pathSMF_SUMMARY_DATASETOptional SMF summary dataset for offline metricsRMF_METRICS_ENABLEDQuery z/OSMF RMF metrics when availableRACF_AUDIT_USS_PATHUSS path to RACF audit log fileRACF_AUDIT_DATASETSequential dataset containing RACF audit recordsSECURITY_READ_ONLYWhen true (default), blocks write tools such as submit_jclSECURITY_ALLOWED_TOOLSComma-separated allowlist of MCP tool namesSECURITY_BLOCKED_TOOLSComma-separated blocklist of MCP tool namesSECURITY_ALLOWED_DATASET_PATTERNSComma-separated dataset patterns (e.g. USERDEV.*,SYS1.*)SECURITY_ALLOWED_USS_PATHSComma-separated USS path prefixesSECURITY_AUDIT_LOGGINGLog every tool invocation to stderr (SIEM-friendly JSON)SECURITY_MAX_JCL_BYTESMaximum inline JCL size for submit_jclSECURITY_WRITE_APPROVALHuman-in-the-loop: submit_jcl returns a one-time token and approve_write executes (default false)SECURITY_JCL_SCANPre-flight scan JCL before submission: IDCAMS DELETE, IEFBR14 DISP DELETE, blocked utilities (default true)SECURITY_JCL_SCAN_STRICTStrict scan mode: WARN findings also block submissions (default false)SECURITY_BLOCKED_PROGRAMSComma-separated EXEC programs that may never run (extends ADRDSSU,ICKDSF,IEHINITT)SECURITY_BLOCKED_JOB_CLASSESComma-separated JES job classes that may never be usedSECURITY_CHANGE_TICKET_PATTERNRegex a changeTicket argument must match on writes, e.g. CHG[0-9]{6}SECURITY_WRITE_WINDOWAllowed write window, 24h HH:MM-HH:MM (overnight ranges allowed), e.g. 08:00-18:00SECURITY_WRITE_DAYSWeekdays writes are allowed: 0=Sun..6=Sat, e.g. 1-5SECURITY_WRITE_WINDOW_TZIANA timezone for the write window (default UTC)Local servers need a runtime on your machine (e.g. Node.js 18+). Config file locations differ by client; see your client’s docs.
Tools
Local servers expose tools only once running on your machine, and the maintainer has not provided a tool list.
Details
The maintainer has not added details yet. Check the README in the repository.
Comments
New to MCP?
From what the protocol is to installing your first server, these answers cover most first questions.
An open protocol that defines how AI applications connect to external tools and data in a uniform way. Clients talk to the model; MCP servers provide tools, resources and prompt templates. They exchange standard messages, so one server can be reused by many clients.