RailWise KB已发布
MCP Server Overview
Overview of RAILWISE MCP (Model Context Protocol) Server, covering architecture, capabilities, integration methods, and use cases.
learning-path
MCP Server Overview
Section titled “MCP Server Overview”1. What is MCP?
Section titled “1. What is MCP?”MCP (Model Context Protocol) is an open protocol developed by Anthropic for connecting AI assistants with external data sources and tools. RAILWISE MCP Server allows AI assistants to access monitoring data, execute commands, and generate reports.
2. Architecture
Section titled “2. Architecture”┌─────────────┐ ┌─────────────┐ ┌─────────────┐│ AI Client │ ←→ │ MCP Server │ ←→ │ RailWise API ││ (Claude/ │ │ (RailWise) │ │ (Backend) ││ Cursor) │ │ │ │ │└─────────────┘ └─────────────┘ └─────────────┘3. Capabilities
Section titled “3. Capabilities”3.1 Tools
Section titled “3.1 Tools”| Tool Name | Description | Parameters |
|---|---|---|
query_data |
Query monitoring data | project_id, point_id, date_range |
generate_report |
Generate monitoring report | project_id, report_type, date_range |
analyze_trend |
Analyze data trend | project_id, point_id, period |
check_alert |
Check warning status | project_id, level |
export_data |
Export monitoring data | project_id, format, date_range |
3.2 Resources
Section titled “3.2 Resources”| Resource | Description | Access Method |
|---|---|---|
project://{id} |
Project information | Read |
data://{project_id}/{point_id} |
Monitoring data | Read |
report://{project_id}/{report_id} |
Monitoring report | Read |
standard://{code} |
Standard document | Read |
4. Integration Methods
Section titled “4. Integration Methods”4.1 Claude Desktop Integration
Section titled “4.1 Claude Desktop Integration”- Install RAILWISE MCP Server
- Configure Claude Desktop settings
- Add MCP server configuration
{ "mcpServers": { "railwise": { "command": "npx", "args": ["@railwise/mcp-server"], "env": { "RAILWISE_API_KEY": "your_api_key" } } }}4.2 Cursor Integration
Section titled “4.2 Cursor Integration”- Open Cursor Settings
- Go to
Features > MCP - Add MCP server
4.3 Custom Client Integration
Section titled “4.3 Custom Client Integration”import { Client } from "@modelcontextprotocol/sdk/client/index.js";
const client = new Client({ name: "my-client", version: "1.0.0"});
await client.connect(transport);
// List available toolsconst tools = await client.listTools();
// Call toolconst result = await client.callTool({ name: "query_data", arguments: { project_id: "proj-001", point_id: "JC-01", date_range: "2024-01-01,2024-01-31" }});5. Use Cases
Section titled “5. Use Cases”5.1 Natural Language Data Query
Section titled “5.1 Natural Language Data Query”User: "Query the settlement data of point JC-01 in the last 7 days"AI: Calls query_data tool → Returns data → Displays results5.2 Intelligent Report Generation
Section titled “5.2 Intelligent Report Generation”User: "Generate a weekly report for project proj-001"AI: Calls generate_report tool → Returns report → Displays report5.3 Trend Analysis
Section titled “5.3 Trend Analysis”User: "Analyze the settlement trend of point JC-01"AI: Calls analyze_trend tool → Returns analysis → Displays trend chart6. Security
Section titled “6. Security”6.1 Authentication
Section titled “6.1 Authentication”MCP Server uses API Key authentication. All requests must include a valid API Key.
6.2 Permission Control
Section titled “6.2 Permission Control”MCP Server inherits the permissions of the API Key. Only authorized data and operations can be accessed.
6.3 Data Privacy
Section titled “6.3 Data Privacy”- MCP Server does not store conversation content
- All data access is through the RailWise API
- Data transmission uses HTTPS encryption
7. Related Documents
Section titled “7. Related Documents”RailWise · Smart Monitoring — Engineering Surveying and Safety Monitoring Digital Solutions
