TianGong-LCA-MCP Server
TianGong-LCA-MCP enables LCA data search, OpenLCA impact assessment, calculation guidance, and authenticated Study workflows over STDIO or Streamable HTTP.
Search LCA flows, processes, and life cycle models by query.
Calculate life cycle impact assessment with OpenLCA using a product system and impact method.
List OpenLCA system processes and LCIA methods.
Retrieve the recommended workflow for LCA calculations and obtaining LCIA results.
Use authenticated
Study_API_Toolworkflows to create projects, prepare models, submit runs, and read results; V2 is explicit, V3–V6 supported with V5/V6 off by default.Run as a local STDIO server or an OAuth 2.1-protected remote Streamable HTTP server.
Allows containerized deployment of the MCP server using Docker, with configuration through environment variables and port publishing.
Enables configuration of the MCP server through environment variables loaded from .env files.
Provides the runtime environment for the MCP server with version management support.
Handles package installation, dependency management, and publishing for the MCP server.
Manages Node.js versions for development and execution of the MCP server.
Click on "Deploy 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., "@TianGong-LCA-MCP Server calculate the carbon footprint of producing 1kg of steel"
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.
title: TianGong LCA MCP README EN docType: guide scope: repo status: active authoritative: false owner: mcp language: en whenToUse:
when you need English user-facing MCP package setup, Docker usage, local startup, or inspector examples whenToUpdate:
when English startup commands, Docker usage, package invocation, or user-facing MCP examples change checkPaths:
README.md
README_CN.md
package.json
Dockerfile
mcp_config.json
src/index.ts
src/index_server.ts
src/index_server_local.ts
src/http_app.ts
src/http_app_local.ts lastReviewedAt: 2026-11-04 lastReviewedCommit: e141b4108eb864e99e185c81f6fb32b1278ba1c8 lastReviewedNote: 'MCP #104: reviewed explicit actor-authenticated V2-V5 Study consumer, exact Edge artifacts, bounded downloads, source refusal and sticky same-key mutation recovery. Canonical source/packed/clean gates, independent review and installed runtime qualification are recorded separately; no publication or P5 enablement.' related:
AGENTS.md
.docpact/config.yaml
DEV_EN.md
README_CN.md
TianGong-LCA-MCP
TianGong LCA Model Context Protocol (MCP) Server supports STDIO and Streamable Http protocols.
Environment
Copy .env.example and populate its Supabase issuer, publishable key, exact admitted public OAuth client IDs, and allowed browser origins. OAuth authentication requires no Redis, confidential client secret, or server-side session encryption key.
GLAD dataset search tools additionally require a GLAD API key:
GLAD_API_KEY=your-glad-api-key
GLAD_API_BASE_URL=https://www.globallcadataaccess.org/api/v1Related MCP server: Example MCP SSE Server
Remote OAuth
Remote Streamable HTTP is an OAuth 2.1 protected resource. A compatible MCP host discovers /.well-known/oauth-protected-resource/mcp, follows its Supabase Auth authorization server, opens the user's browser, and completes Authorization Code with S256 PKCE. The user signs in and consents in Next; usernames and passwords are never entered into the AI or MCP host.
Supabase issues the access and rotating refresh tokens directly to the public MCP client. The client stores its refresh token locally and sends the short-lived Supabase ES256 access JWT on every MCP request. The server verifies signature, issuer, audience, expiry, role/session, and exact client_id; Edge/PostgREST then re-verify the same user/client context and enforce RLS capabilities.
Dynamic Client Registration remains disabled. Operators register exact public clients and loopback callbacks in Supabase, then list those UUID client IDs in MCP_OAUTH_ALLOWED_CLIENT_IDS_JSON. Unknown, malformed, expired, Cognito, and password/API-key bearers fail the canonical OAuth challenge without fallback I/O.
The MCP origin exposes no authorization, token, refresh, revoke, callback, registration, demo, or authorization-code display endpoint. Supabase Auth owns those protocol operations and Next owns /oauth/consent.
Starting MCP Server
Client STDIO Server
Set SUPABASE_BASE_URL explicitly to your own backend before using Supabase search tools. There is no default production backend. Missing or invalid backend configuration fails locally before a request; STDIO initialization, tool listing, and local guidance remain available. Database operations also require your backend's SUPABASE_PUBLISHABLE_KEY. Authenticated HTTP continues to require the full OAuth configuration above.
corepack install --global pnpm@11.24.0
pnpm add --global @tiangong-lca/mcp-server
pnpm dlx dotenv-cli -e .env -- tiangong-lca-mcp-stdioUsing Docker
The checked-in Dockerfile installs published @tiangong-lca/mcp-server@0.2.1, rather than building this checkout. Source changes apply to a checkout build; existing npm packages and images need a separately reviewed release to receive them.
# Build the MCP server image locally using Dockerfile
docker build -t linancn/tiangong-lca-mcp-server:0.2.1 .
# Start MCP server using Docker
docker run -d \
--name tiangong-lca-mcp-server \
--publish 9278:9278 \
--env-file .env \
linancn/tiangong-lca-mcp-server:0.2.1Local Testing
STDIO Server
# Launch the STDIO Server using MCP Inspector
pnpm startStreamable Http Server
pnpm start:serverStreamable Http Local Server
pnpm start:server-localThe HTTP start commands launch MCP Inspector through a cross-platform Node argv wrapper and inject the development-only Inspector environment without POSIX shell syntax.
LCA calculation
Use Study_API_Tool over authenticated HTTP to create a calculation project, prepare a model, submit a run and read its results with an explicit V2 request. Read the selected family’s request schema and call capability.read to see what your server and OAuth context allow.
The source also supports V3–V6 for optional analysis, reporting, review, sharing and method assessment. V5 and V6 require separate runtime admission and are off by default. The server reauthorizes every call. Keep the original mutation request and key for recovery; the tool does not disclose raw source packets. The Study consumer contract explains download integrity and qualification. Package publication and hosted activation are separate from source support.
Available Tools
7 toolsLCA_Calculation_Guidance_ToolC
Get the workflow, which should be followed for Life Cycle Assessment (LCA) Calculations to Obtain Life Cycle Impact Assessment (LCIA) Results
Inputs: no named parameters.
OpenLCA_Impact_Assessment_ToolC
Calculate life cycle impact assessment using OpenLCA.
Inputs: productSystem (required), impactMethod (required), serverUrl.
OpenLCA_List_LCIA_Methods_ToolC
List all LCIA methods using OpenLCA.
Inputs: serverUrl.
OpenLCA_List_System_Processes_ToolC
List all system processes using OpenLCA.
Inputs: serverUrl.
Search_Flows_ToolC
Search LCA flows data.
Inputs: query (required).
Search_Life_Cycle_Models_ToolC
Search LCA life cycle models data.
Inputs: query (required).
Search_Processes_ToolC
Search LCA processes data.
Inputs: query (required).
Tool Schema Changelog
Recent tool additions, removals, and schema changes observed during successful MCP inspections.
Loading tool schema changelog…
TDQS
Scored across 7 tools
The tools have mostly distinct purposes with clear boundaries: guidance, calculation, listing methods/processes, and searching different data types (flows, models, processes). However, 'Search_Processes_Tool' and 'OpenLCA_List_System_Processes_Tool' could cause some confusion as both relate to processes, though one searches and the other lists from OpenLCA specifically.
The naming follows a consistent pattern with a clear prefix structure (e.g., 'OpenLCA_' for OpenLCA-related tools, 'Search_' for search tools) and uses snake_case throughout. The only minor deviation is 'LCA_Calculation_Guidance_Tool' which doesn't fit the prefix pattern as neatly as others.
With 7 tools, this is well-scoped for an LCA-focused server. It covers key operations like guidance, calculation, listing, and searching across different data types, making each tool earn its place without being overwhelming or insufficient.
The server covers core LCA operations such as guidance, calculation, listing, and searching, but has notable gaps. For example, there are no tools for creating, updating, or deleting LCA data (e.g., processes, models), which limits full lifecycle management and could cause agent failures in more complex workflows.
Maintenance
Related MCP Connectors
Model Context Protocol server for Studex tools, notifications, and profile integrations
A Model Context Protocol server for Wix AI tools
Model Context Protocol server for todo.vu task management and time tracking.
A comprehensive Model Context Protocol (MCP) server that enables AI assistants to interact with yo…
Related MCP Servers
- AlicenseNot gradedqualityDmaintenanceA server that implements the Model Context Protocol, providing a standardized way to connect AI models to different data sources and tools.10 npm12MIT
- FlicenseNot gradedqualityDmaintenanceA Model Context Protocol server that enables real-time communication using Server-Sent Events (SSE), providing standardized model management and resource templating capabilities.-
- AlicenseNot gradedqualityDmaintenanceA server that implements the Model Context Protocol (MCP) with StreamableHTTP transport, enabling standardized interaction with model services through a RESTful API interface.376 npm2MIT
- AlicenseNot gradedqualityDmaintenanceA Model Context Protocol (MCP) server that supports STDIO, SSE and Streamable HTTP protocols for AI model interactions.10 npm1MIT