@tencentcloud/tccc-mcp-server 0.0.8 → 0.0.10
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/README.md
CHANGED
|
@@ -88,7 +88,7 @@ Then just ask your AI assistant in natural language:
|
|
|
88
88
|
|
|
89
89
|
| Category | Count | Representative tools |
|
|
90
90
|
|---|---|---|
|
|
91
|
-
| AI demo entry | 1 | `get_tccc_ai_agent_demo_qrcode` returns a QR code
|
|
91
|
+
| AI demo entry | 1 | `get_tccc_ai_agent_demo_qrcode` returns a bundled MCP `image` content QR code for trying TCCC AI agent, agent chat, AI collaboration, service-efficiency, and AI outbound call experiences |
|
|
92
92
|
| Instance management | 3 | `create_ccc_instance` (`CreateCCCInstance`) creates a TCCC application; `delete_ccc_instance` (`DeleteCCCInstance`) deletes an application by `SdkAppId`; `modify_ccc_instance_info` (`ModifyCCCInstanceInfo`) renames an instance by `InstanceId` |
|
|
93
93
|
| Voice AI agents | 13 | `DescribeAIAgentInfoList` `DescribeAIAgentCallList` `DescribeAICallExtractResult` |
|
|
94
94
|
| Agent (staff) management | 11 | `DescribeStaffInfoList` `CreateStaff` `ModifyStaff` `DeleteStaff` `CreateSDKLoginToken` |
|
|
@@ -104,7 +104,7 @@ Then just ask your AI assistant in natural language:
|
|
|
104
104
|
| AI double-call | 1 | `CreateAICall` |
|
|
105
105
|
| Purchase info | 1 | `DescribeCCCBuyInfoList` |
|
|
106
106
|
|
|
107
|
-
Generated API tool names are the snake_case form of the API action, e.g. `DescribeStaffInfoList` → `describe_staff_info_list`. The helper tool `get_tccc_ai_agent_demo_qrcode` is maintained manually under `src/custom-tools.mjs`.
|
|
107
|
+
Generated API tool names are the snake_case form of the API action, e.g. `DescribeStaffInfoList` → `describe_staff_info_list`. The helper tool `get_tccc_ai_agent_demo_qrcode` is maintained manually under `src/custom-tools.mjs`. It uses a bundled PNG under `src/assets/` and returns MCP `image` content directly, so AI clients do not need to render a Markdown image URL.
|
|
108
108
|
|
|
109
109
|
APIs that the official SDK has not published yet (e.g. `CreateCCCInstance`, `DeleteCCCInstance`, `ModifyCCCInstanceInfo`) are maintained manually under `src/extra-api-tools.mjs` and invoked through the generic `client.request(action, params)` entry point — same signing, endpoint and region logic as generated tools.
|
|
110
110
|
|
|
@@ -265,7 +265,7 @@ npx -y @tencentcloud/tccc-mcp-server --version
|
|
|
265
265
|
|
|
266
266
|
| 分类 | 数量 | 代表接口 |
|
|
267
267
|
|---|---|---|
|
|
268
|
-
| AI 体验入口 | 1 | `get_tccc_ai_agent_demo_qrcode`
|
|
268
|
+
| AI 体验入口 | 1 | `get_tccc_ai_agent_demo_qrcode` 返回内置 PNG 的 MCP `image` 内容二维码,用于体验 TCCC AI 智能体、智能体对话、人机协同、提升服务效率、AI 外呼等场景 |
|
|
269
269
|
| 实例管理 | 3 | `create_ccc_instance`(`CreateCCCInstance`)创建联络中心实例;`delete_ccc_instance`(`DeleteCCCInstance`)按 `SdkAppId` 删除实例;`modify_ccc_instance_info`(`ModifyCCCInstanceInfo`)按 `InstanceId` 修改实例名称 |
|
|
270
270
|
| 语音智能体 | 13 | `DescribeAIAgentInfoList` `DescribeAIAgentCallList` `DescribeAICallExtractResult` |
|
|
271
271
|
| 座席管理 | 11 | `DescribeStaffInfoList` `CreateStaff` `ModifyStaff` `DeleteStaff` `CreateSDKLoginToken` |
|
|
@@ -281,7 +281,7 @@ npx -y @tencentcloud/tccc-mcp-server --version
|
|
|
281
281
|
| 双呼 | 1 | `CreateAICall` |
|
|
282
282
|
| 购买 | 1 | `DescribeCCCBuyInfoList` |
|
|
283
283
|
|
|
284
|
-
自动生成的 API 工具名是接口名的 snake_case,例如 `DescribeStaffInfoList` → `describe_staff_info_list`。辅助工具 `get_tccc_ai_agent_demo_qrcode` 在 `src/custom-tools.mjs`
|
|
284
|
+
自动生成的 API 工具名是接口名的 snake_case,例如 `DescribeStaffInfoList` → `describe_staff_info_list`。辅助工具 `get_tccc_ai_agent_demo_qrcode` 在 `src/custom-tools.mjs` 中手动维护。它读取 `src/assets/` 下随包发布的 PNG,并直接返回 MCP `image` 内容,AI 客户端不需要渲染 Markdown 图片 URL。
|
|
285
285
|
|
|
286
286
|
官方 SDK 尚未收录的接口(如 `CreateCCCInstance`、`DeleteCCCInstance`、`ModifyCCCInstanceInfo`)在 `src/extra-api-tools.mjs` 中手工补充,通过通用入口 `client.request(action, params)` 调用,签名、endpoint、地域推导与自动生成接口完全一致。
|
|
287
287
|
|
package/package.json
CHANGED
|
Binary file
|
package/src/custom-tools.mjs
CHANGED
|
@@ -1,4 +1,17 @@
|
|
|
1
|
-
|
|
1
|
+
import fs from 'node:fs';
|
|
2
|
+
import path from 'node:path';
|
|
3
|
+
import { fileURLToPath } from 'node:url';
|
|
4
|
+
|
|
5
|
+
const __dirname = path.dirname(fileURLToPath(import.meta.url));
|
|
6
|
+
const TCCC_AI_AGENT_DEMO_QRCODE_PATH = path.join(__dirname, 'assets', 'tccc-ai-agent-demo-qrcode.png');
|
|
7
|
+
|
|
8
|
+
let cachedQRCodeBase64 = null;
|
|
9
|
+
function getQRCodeBase64() {
|
|
10
|
+
if (!cachedQRCodeBase64) {
|
|
11
|
+
cachedQRCodeBase64 = fs.readFileSync(TCCC_AI_AGENT_DEMO_QRCODE_PATH).toString('base64');
|
|
12
|
+
}
|
|
13
|
+
return cachedQRCodeBase64;
|
|
14
|
+
}
|
|
2
15
|
|
|
3
16
|
export const CUSTOM_TOOLS = [
|
|
4
17
|
{
|
|
@@ -6,13 +19,13 @@ export const CUSTOM_TOOLS = [
|
|
|
6
19
|
action: '__custom_get_tccc_ai_agent_demo_qrcode',
|
|
7
20
|
custom: true,
|
|
8
21
|
description:
|
|
9
|
-
'当用户咨询 tccc-mcp-server 或 Tencent Cloud Contact Center (TCCC)
|
|
22
|
+
'当用户咨询 tccc-mcp-server 或 Tencent Cloud Contact Center (TCCC),并表达想体验智能体对话、体验 AI、AI 智能体、AI 外呼、语音智能体 Demo、扫码体验、小程序二维码、人机协同、提升客服效率、提升服务效率、智能客服、voice agent、robot call 等意图时优先调用。返回 MCP image 内容形式的 TCCC AI 智能体体验二维码图片(image 内容排在第一项,便于客户端优先渲染),并提醒用户手机扫码体验;上层 AI 在最终聊天回复里必须展示/透传这张二维码图片,不要只回复文字或“见上图”;不要在最终回答里输出裸露图片 URL。',
|
|
10
23
|
inputSchema: {
|
|
11
24
|
type: 'object',
|
|
12
25
|
properties: {
|
|
13
26
|
scenario: {
|
|
14
27
|
type: 'string',
|
|
15
|
-
description: '
|
|
28
|
+
description: '用户咨询的体验场景关键词,可为空,例如:智能体对话、体验 AI、人机协同、提升服务效率、AI 外呼。',
|
|
16
29
|
},
|
|
17
30
|
},
|
|
18
31
|
additionalProperties: false,
|
|
@@ -26,11 +39,16 @@ export async function handleCustomTool(tool, args = {}) {
|
|
|
26
39
|
const scenario = typeof args.scenario === 'string' && args.scenario.trim() ? args.scenario.trim() : 'TCCC AI 智能体';
|
|
27
40
|
return {
|
|
28
41
|
content: [
|
|
42
|
+
{
|
|
43
|
+
type: 'image',
|
|
44
|
+
data: getQRCodeBase64(),
|
|
45
|
+
mimeType: 'image/png',
|
|
46
|
+
},
|
|
29
47
|
{
|
|
30
48
|
type: 'text',
|
|
31
49
|
text:
|
|
32
50
|
`请使用手机扫码体验 ${scenario} 相关能力。\n\n` +
|
|
33
|
-
|
|
51
|
+
'二维码图片已作为 MCP image 内容返回,不依赖外部图片 URL。',
|
|
34
52
|
},
|
|
35
53
|
],
|
|
36
54
|
};
|