Provides an MCP server to generate Xray-core server/client configurations with protocol, transport, and security options.
Configuration
View docs{
"mcpServers": {
"clcc2019-xray-mcp": {
"command": "node",
"args": [
"/path/to/xray-mcp/dist/index.js"
]
}
}
}You can generate, validate, and manage Xray-based server and client configurations through an MCP server that runs locally. This MCP server enables you to specify protocols, transports, and security options, and to automatically create ready-to-use configurations for Xray-core. It also supports key and credential generation to simplify secure deployments.
You connect your MCP client to the local MCP server to generate and validate configurations. Start by ensuring the MCP server is installed and built, then run the MCP with the local command shown here. Use the MCP client to request a server configuration by choosing your desired protocol, transport, and security settings, and to request a matching client configuration to connect to that server. You can generate authentication data such as UUIDs and X25519 keys as needed for REALITY-enabled setups, and you can validate generated configurations before applying them.
Prerequisites: you need Node.js and npm installed on your system.
npm install
npm run buildConfiguration and operational notes come from the built-in tools and templates. You can generate server and client configurations, create keys and credentials, and validate your configurations before use. Real-time examples include creating a VLESS+REALITY setup, generating a UUID, and producing a matching client configuration to connect to the server.
Create an Xray server configuration by selecting protocol, transport, and security options.
Create a client configuration to connect to a server with the chosen options.
Generate a new UUID v4 for authentication.
Generate an X25519 key pair for REALITY authentication.
Create a random short ID for REALITY authentication.
Generate a random password for Trojan or Shadowsocks.
Generate a base64 key for Shadowsocks 2022.
Check an Xray configuration for syntax and semantic correctness.
List all supported proxy protocols with descriptions.
List all supported transport types with descriptions.
List all supported security types with descriptions.
List recommended REALITY target sites.