Skip to main content
Glama

聊天数据查询

pdd_chat_data

Query Pinduoduo customer service chat records by agent, order, or product ID within allowed date ranges. Returns JSON data with message previews and statistics.

Instructions

按客服账号/订单号/商品ID 查询聊天记录(纯数据 JSON;时间跨度限制与后台一致:按客服/订单 ≤31 天、按商品 ≤7 天)。如需导出 Excel 文件,用 pdd-chat-export skill。

Input Schema

TableJSON Schema
NameRequiredDescriptionDefault
modeYescs=按客服/时间查全部会话;order=按订单号;goods=按商品ID
shopNo店铺名(多店铺时指定,对应 config/shops.json 的键名;省略=默认店铺)
mmsIdNo客服账号 mmsId(mode=cs 可选,来自 pdd_chat_users)
endDateYes结束日期 YYYY-MM-DD
goodsIdNo商品ID(mode=goods 必填)
orderSnNo订单号(mode=order 必填)
startDateYes开始日期 YYYY-MM-DD
previewLimitNo返回消息预览条数(0=只返回统计)
maxConversationsNo最多查询多少个会话(防止失控)
maxMessagesPerConvNo每个会话最多查询多少条消息,0=不限制

Schema Changelog

Changes observed during successful MCP inspections.

  1. First observedv0.1.0

TDQS

A4.2/5.0
Behavior3/5

Does the description disclose side effects, auth requirements, rate limits, or destructive behavior?

No annotations are present, so the description carries the full burden of behavioral disclosure. It usefully discloses that the result is pure data JSON and that time-span limits match the backend, but it does not describe the JSON structure, auth/error behavior, or rate-limit considerations. For a 10-parameter tool with no output schema, these are notable gaps.

Agents need to know what a tool does to the world before calling it. Descriptions should go beyond structured annotations to explain consequences.

Conciseness5/5

Is the description appropriately sized, front-loaded, and free of redundancy?

Two dense sentences: the first front-loads the core query scope, modes, and JSON output type, and the second gives a single explicit routing instruction to the export skill. There is no filler or redundancy.

Shorter descriptions cost fewer tokens and are easier for agents to parse. Every sentence should earn its place.

Completeness4/5

Given the tool's complexity, does the description cover enough for an agent to succeed on first attempt?

Despite no output schema and no annotations, the description covers the essential decision points: what is queried, in which modes, in what format, under what time limits, and where to go for Excel export. The remaining return-structure detail is largely inferable from the rich parameter schema (previewLimit, maxConversations, mode-specific required fields), so the definition is complete enough for correct invocation.

Complex tools with many parameters or behaviors need more documentation. Simple tools need less. This dimension scales expectations accordingly.

Parameters3/5

Does the description clarify parameter syntax, constraints, interactions, or defaults beyond what the schema provides?

Schema description coverage is 100%, so the baseline is 3. The description adds a cross-parameter validity constraint (31/7-day limits) that sharpens the meaning of startDate and endDate, but it does not need to restate per-parameter details already present in the schema.

Input schemas describe structure but not intent. Descriptions should explain non-obvious parameter relationships and valid value ranges.

Purpose5/5

Does the description clearly state what the tool does and how it differs from similar tools?

The description names a precise action and resource ('查询聊天记录' = query chat records) and enumerates three query dimensions: customer-service account, order number, and product ID. It also marks the output as pure JSON, which distinguishes it from the Excel-export skill and from sibling tools such as pdd_chat_users or pdd_reviews_list.

Agents choose between tools based on descriptions. A clear purpose with a specific verb and resource helps agents select the right tool.

Usage Guidelines5/5

Does the description explain when to use this tool, when not to, or what alternatives exist?

The description explicitly routes Excel-export needs to the pdd-chat-export skill, making the alternative and the condition for choosing it explicit. It also encodes backend validity windows (≤31 days for customer-service/order queries, ≤7 days for product queries), so an agent can reject invalid date ranges before invoking the tool.

Agents often have multiple tools that could apply. Explicit usage guidance like "use X instead of Y when Z" prevents misuse.