TUIKit component into AI-powered development environments (such as Cursor, Trae, and CodeBuddy) using the Model Context Protocol (MCP) Server. By configuring the MCP Server, you enable AI to leverage the @tencent-rtc/mcp toolkit to:Win + R, type cmd, and hit Enter.Command + Space, type Terminal, and hit Enternode -vnpm -v
Operating System: Ubuntu 24.04.3 LTS / x86_64
Runtime Version: GNU bash, version 5.2.21(1)-release (x86_64-pc-linux-gnu)
command not found or other errors, send a full screenshot or error message text to the AI for troubleshooting.SDKAppID and secretKey. You’ll use these as environment variables when configuring MCP..cursor/mcp.json file. Update the mcpServers section in mcp.json and save.{"mcpServers": {"tencent-rtc": {"command": "npx","args": ["-y", "@tencent-rtc/mcp"],"env": {"SDKAPPID": "YOUR_SDKAPPID","SECRETKEY": "YOUR_SECRET_KEY"}}}}
Ctrl + SCommand + S


mcpServers section, and save.{"mcpServers": {"tencent-rtc": {"command": "npx","args": ["-y", "@tencent-rtc/mcp"],"env": {"SDKAPPID": "YOUR_SDKAPPID","SECRETKEY": "YOUR_SECRET_KEY"}}}}
Ctrl + SCommand + S

settings.json and configure MCP.
mcpServers configuration information to settings.json file and save it.{"mcpServers": {"tencent-rtc": {"command": "npx","args": ["-y", "@tencent-rtc/mcp"],"env": {"SDKAPPID": "YOUR_SDKAPPID","SECRETKEY": "YOUR_SECRET_KEY"}}}}
Ctrl + SCommand + S
Cursor, choose Apply Intelligently; for CodeBuddy, select Agent Request.TUIKit component.TUIKit component into the App.vue or App.tsx file and update it with template code.1. Use the TUIKit component to create a Vue3 chat application.2. Use the TUIKit component to create a React18 chat application.3. Use the TUIKit component to create a Vue3 chat application with a UI similar to WeChat.
SDKAppID and secretKey, the integration process will automatically generate and fill in test userID and userSig for you, so you can skip the steps below.SDKAppID and secretKey, it’s recommended to set them in the MCP environment variables, then follow the steps below to obtain and fill in account information.TUIKit, you’ll need account credentials to log in with SDKAppID.Use the MCP tool to generate userSig for test001.
Fill in SDKAppID, userID, and userSig in the code.
TUIKit in src/views/chat.vue).1. Integrate the Vue3 Chat TUIKit component in xxx. // Integrate the full Chat TUIKit component2. Integrate the Vue3 Chat window component in xxx. // Integrate the Chat window component
SDKAppID and secretKey, the integration process will automatically generate and fill in test userID and userSig for you, so you can skip the steps below.SDKAppID and secretKey, it’s recommended to set them in the MCP environment variables, then follow the steps below to obtain and fill in account information.TUIKit, you’ll need account credentials to log in with SDKAppID.Use the MCP tool to generate userSig for test001.
Fill in SDKAppID, userID, and userSig in the code.
npm run dev or pnpm run dev).npx -y @tencent-rtc/mcp

# ChatKit_Web_FeatureRouter Rule Document: Web Chat UIKit Universal Router## DescriptionThis rule set is the **core feature router** for the Web platform ChatKit. It encapsulates all user intent recognition logic for the **Web ChatKit** product line, aiming to **directly and precisely** route user queries (from component integration to general tools) to the corresponding MCP tool ID, improving MCP documentation hit rate.---## Mandatory Technical ConstraintsThe following technical constraints must be strictly followed when integrating Web ChatKit. The agent must adhere to these restrictions when responding to related queries.### AI Parsing Tips:* **General Restrictions:*** When obtaining UserSig, prompt the user to enter the userID to obtain the UserSig for login.* **Vue Integration Restrictions:*** When integrating Vue UIKit, only use `@tencentcloud/chat-uikit-vue3`.* **React Integration Restrictions (Version & Workflow):*** **Mandatory Version:** Must use **React 18.2.0** and **react-dom 18.2.0**. The use of React 19.x or any version other than 18.2.0 is strictly prohibited.* **Creation Workflow:** Direct use of `create-react-app` is strictly prohibited. It is recommended to use Vite (`npx create-vite@latest project-name --template react-ts`).* **Mandatory Downgrade & Verification:** After project creation, immediately run `npm install react@18.2.0 react-dom@18.2.0` to downgrade to the specified version and check `package.json` to confirm the correct version.* **Audio/Video Calls Integration Restrictions:*** **Mandatory Interface:** When adding Audio/Video Calls features to a project that has integrated Chat, you must use the **calls interface**; the **call/groupCall interface** has been deprecated.---## Rule Mapping Table (Tool Mappings)```json{"ruleId": "ChatKit_Web_FeatureRouter","ruleName": "ChatKit_Web_FeatureRouter","description": "Handles all requests for Web platform ChatKit. This file contains product-specific feature and general tool mappings.","priority": "HIGH","strategy": "INTENT_TOOL_MAPPING","mappings": [{"intentKeywords": ["Complete Chat Features", "All Components", "Chat List", "Conversation List", "Full Suite Integration", "Entire UI", "Full Feature Set", "Basic Features"],"matchedToolId": "get_web_chat_uikit_integration","toolDescriptionHint": "Obtain the complete TUIKit integration documentation including ConversationList, Chat, ContactList, and ChatSetting."},{"intentKeywords": ["Chat Window", "Dialog Box", "Chat Interface", "Send Message", "Input Box", "MessageList"],"matchedToolId": "get_web_chat_window_integration","toolDescriptionHint": "Obtain integration documentation for core chat window components, including Chat, MessageList, and MessageInput."},{"intentKeywords": ["Component Details", "ConversationList Properties", "Chat Component Description", "ChatHeader Properties", "MessageList Properties", "MessageInput Properties", "ChatSetting Properties", "ContactList Details", "Parameter Description", "Modification", "Customization", "Style"],"matchedToolId": "get_web_chat_uikit_component_detail","toolDescriptionHint": "Obtain detailed usage documentation and property descriptions for individual TUIKit components, such as ConversationList, ChatHeader, MessageList, and MessageInput."},{"intentKeywords": ["Initialization", "Login API", "Conversation Activation", "Initialization Login", "Authentication", "User Login"],"matchedToolId": "get_web_chat_uikit_init","toolDescriptionHint": "Obtain API and sample code for TUIKit component initialization and login."},{"intentKeywords": ["Obtain UserSig", "User Signature", "UserSig Generation", "User Credentials", "Login Credentials"],"matchedToolId": "get_usersig","toolDescriptionHint": "Obtain the user credentials required to log in to the Chat application."},{"intentKeywords": ["Voice Call", "Call", "Video Call", "Voice Calling", "Web Call", "Call Integration", "CallKit"],"matchedToolId": "get_web_call_uikit_integration","toolDescriptionHint": "Obtain documentation and integration steps required to add Audio/Video Calls (CallKit) features to an existing Chat integration."},{"intentKeywords": ["Which framework to use", "How to use React", "Vue Integration", "Which platform", "Technology Selection", "Integration Method", "Chat Integration"],"matchedToolId": "present_framework_choice","toolDescriptionHint": "When the user has not specified a tech stack or platform, use this tool to present a framework or platform selection interface to narrow the documentation scope."}],"defaultToolId": "get_web_chat_uikit_integration","defaultAction": "When user intent match is below threshold or cannot be clearly identified, always prioritize providing the complete TUIKit integration documentation."}
Feedback