query-customer-service-record
查询霍小钉客户服务记录。使用场景:用户需要查询某个客户的服务小计记录时,自动解析客户名称、调用搜索接口确认客户、处理多客户选择、查询服务记录并展示总结。
Best use case
query-customer-service-record is best used when you need a repeatable AI agent workflow instead of a one-off prompt.
查询霍小钉客户服务记录。使用场景:用户需要查询某个客户的服务小计记录时,自动解析客户名称、调用搜索接口确认客户、处理多客户选择、查询服务记录并展示总结。
Teams using query-customer-service-record should expect a more consistent output, faster repeated execution, less prompt rewriting.
When to use this skill
- You want a reusable workflow that can be run more than once with consistent structure.
When not to use this skill
- You only need a quick one-off answer and do not need a reusable workflow.
- You cannot install or maintain the underlying files, dependencies, or repository context.
Installation
Claude Code / Cursor / Codex
Manual Installation
- Download SKILL.md from GitHub
- Place it in
.claude/skills/query-customer-service-record/SKILL.mdinside your project - Restart your AI agent — it will auto-discover the skill
How query-customer-service-record Compares
| Feature / Agent | query-customer-service-record | Standard Approach |
|---|---|---|
| Platform Support | Not specified | Limited / Varies |
| Context Awareness | High | Baseline |
| Installation Complexity | Unknown | N/A |
Frequently Asked Questions
What does this skill do?
查询霍小钉客户服务记录。使用场景:用户需要查询某个客户的服务小计记录时,自动解析客户名称、调用搜索接口确认客户、处理多客户选择、查询服务记录并展示总结。
Where can I find the source code?
You can find the source code on GitHub using the link provided at the top of the page.
Related Guides
AI Agents for Startups
Explore AI agent skills for startup validation, product research, growth experiments, documentation, and fast execution with small teams.
AI Agent for Product Research
Browse AI agent skills for product research, competitive analysis, customer discovery, and structured product decision support.
AI Agent for SaaS Idea Validation
Use AI agent skills for SaaS idea validation, market research, customer discovery, competitor analysis, and documenting startup hypotheses.
SKILL.md Source
# 霍小钉客户服务记录查询
## 触发条件
当用户表达以下意图时触发此技能:
- "查询 XXX 客户的服务记录"
- "XXX 客户的服务小计"
- "看看 XXX 客户最近的服务情况"
- "帮我查一下 XXX 的服务记录"
- 任何包含客户名称 + 服务记录/服务小计的查询
## 工作流程
### 1. 解析客户名称和时间范围
从用户输入中提取:
- **客户名称**:必须提取(如"霍迹寻踪")
- **时间范围**:可选,如果用户未提供,默认查询当天
- 开始时间:`YYYY-MM-DD` 格式
- 结束时间:`YYYY-MM-DD` 格式
### 2. 调用客户搜索接口
使用脚本 `scripts/query_service.py` 搜索客户:
```bash
python scripts/query_service.py search <base_url> <customer_name>
```
**参数说明**:
- `base_url`: API 基础地址(如 `https://hxd.ahdingtalk.com:8843`)
- `customer_name`: 用户提供的客户名称
**返回处理**:
- 成功:`{"success": true, "data": ["客户 1", "客户 2", ...]}`
- 失败:`{"success": false, "error": "错误信息"}`
### 3. 处理搜索结果
根据返回的客户列表长度决定下一步:
#### 情况 A:列表为空
告知用户未找到匹配的客户,建议检查名称或提供更多关键词。
#### 情况 B:列表只有 1 个客户
直接使用该客户名称,继续步骤 4。
#### 情况 C:列表有多个客户
向用户展示客户列表,让用户选择:
```
找到多个匹配的客户,请选择:
1. 霍迹寻踪科技有限公司
2. 霍迹寻踪软件有限公司
3. 霍迹寻踪北京分公司
请回复数字或客户名称进行选择。
```
等待用户选择后,使用选中的客户名称继续步骤 4。
### 4. 查询服务记录
使用脚本查询服务小计:
```bash
python scripts/query_service.py records <base_url> <customer_name> [start_time] [end_time]
```
**参数说明**:
- `base_url`: API 基础地址
- `customer_name`: 确定的客户名称
- `start_time`: 开始时间(可选,默认当天)
- `end_time`: 结束时间(可选,默认当天)
### 5. 展示结果
将查询结果格式化展示:
```
📋 霍迹寻踪科技有限公司 服务记录 (2026-03-01 ~ 2026-03-04)
共找到 3 条服务记录:
• 2026-03-01 - 张三 [上门拜访]:去客户现场沟通内容
• 2026-03-02 - 李四 [电话沟通]:电话回访,确认需求
• 2026-03-04 - 张三 [钉钉联系]:发送报价单
📊 总结:
- 服务次数:3 次
- 参与销售:张三 (2 次)、李四 (1 次)
- 服务方式:上门拜访 (1 次)、电话沟通 (1 次)、钉钉联系 (1 次)
- 时间跨度:4 天
**注意**:展示时会为每条记录标注服务方式(如 `[上门拜访]`),便于快速识别服务类型。
```
**服务方式说明**:
接口返回的 `serverType` 字段表示服务方式,包括:
- 上门拜访
- 顺道上门
- 客户到公司
- 电话沟通
- 钉钉联系
- 无效联系
- 微信联系
- 视频会议
- 沙龙会销
## 配置说明
### API 地址配置
在调用脚本前,需要配置 `base_url`。默认值:
```
https://hxd.ahdingtalk.com:8843
```
如需修改,在调用脚本时传入正确的地址。
### 认证配置
当前接口无需认证。如未来需要添加认证,可在脚本中扩展 headers 参数。
## 错误处理
### 常见错误及应对
1. **网络请求失败**
- 检查服务器是否可达
- 检查 base_url 是否正确
2. **客户搜索无结果**
- 建议用户提供更完整的客户名称
- 或提供部分关键词重新搜索
3. **服务记录为空**
- 告知用户在指定时间范围内暂无记录
- 建议扩大时间范围查询
4. **接口返回错误码**
- 显示接口返回的错误信息
- 建议联系系统管理员
## 脚本说明
### scripts/query_service.py
**依赖**:`requests` 库
**功能**:
- `search` 操作:调用客户搜索接口
- `records` 操作:调用服务记录查询接口
**输出**:JSON 格式,便于程序解析
## 使用示例
### 示例 1:简单查询(当天记录)
用户:查询霍迹寻踪的服务记录
执行:
```bash
python scripts/query_service.py search https://hxd.ahdingtalk.com:8843 霍迹寻踪
# 返回:["霍迹寻踪科技有限公司"]
python scripts/query_service.py records https://hxd.ahdingtalk.com:8843 霍迹寻踪科技有限公司
# 返回服务记录
```
### 示例 2:指定时间范围
用户:查一下霍迹寻踪 3 月 1 日到 3 月 10 日的服务小计
执行:
```bash
python scripts/query_service.py search https://hxd.ahdingtalk.com:8843 霍迹寻踪
python scripts/query_service.py records https://hxd.ahdingtalk.com:8843 霍迹寻踪科技有限公司 2026-03-01 2026-03-10
```
### 示例 3:多客户选择
用户:查询霍迹寻踪的服务记录
执行:
```bash
python scripts/query_service.py search https://hxd.ahdingtalk.com:8843 霍迹寻踪
# 返回:["霍迹寻踪科技有限公司", "霍迹寻踪软件有限公司"]
# 等待用户选择...
用户:1
python scripts/query_service.py records https://hxd.ahdingtalk.com:8843 霍迹寻踪科技有限公司
```Related Skills
search-for-service
Search and browse the x402 bazaar marketplace for paid API services. Use when you or the user want to find available services, see what's available, discover APIs, or need an external service to accomplish a task. Also use as a fallback when no other skill clearly matches — search the bazaar to see if a paid service exists. Covers "what can I do?", "find me an API for...", "what services are available?", "search for...", "browse the bazaar".
pay-for-service
Make paid requests to x402-enabled APIs using USDC. Use when you or the user want to call a paid API, make an x402 payment, use a bazaar service, or pay for an API request. Covers phrases like "call this API", "use this service", "pay for the request", "make a paid call", "fetch from x402 endpoint".
Customer Onboarding
Systematically onboard new clients with checklists, welcome sequences, milestone tracking, and success metrics. Reduce churn by nailing the first 90 days.
Customer Support Command Center
Enterprise-grade customer support system: ticket triage, response templates, escalation workflows, CSAT tracking, knowledge base management, and churn prevention. Turns your AI agent into a support team lead.
Customer Success Playbook
Build and run a customer success operation for B2B SaaS. Covers the full lifecycle: onboarding, health scoring, QBRs, churn prevention, and expansion revenue.
Customer Journey Mapping
Map every touchpoint from first click to loyal advocate. Identify drop-off points, emotional peaks, and automation opportunities across your entire customer lifecycle.
Customer Acquisition Cost (CAC) Optimizer
Analyze, benchmark, and reduce your customer acquisition cost across every channel.
gold-price-query
This skill retrieves real-time precious metal prices (gold, silver, platinum, palladium, etc.) from https://i.jzj9999.com/quoteh5. It provides bid/ask prices, daily high/low prices, and price trends for 20+ metal types.
monetize-service
Build and deploy a paid API that other agents can pay to use via x402. Use when you or the user want to monetize an API, make money, earn money, offer a service, sell a service to other agents, charge for endpoints, create a paid endpoint, or set up a paid service. Covers "make money by offering an endpoint", "sell a service", "monetize your data", "create a paid API".
tdx-stock-query
基于TDX API的股票数据查询技能,提供全面的A股市场数据查询功能,包括实时行情、K线数据、分时数据、分时成交、股票搜索、指数数据、ETF数据、市场统计、个股新闻、股票公告等31个API接口。当用户询问股票相关信息时调用。
caixu-query-assets
Search Personal Asset Library. Use when the user wants to search or filter an existing 材序 asset library at the query stage, including “查我有哪些材料”“看哪些可复用”“按类型筛资产”“用自然语言找相关材料”. Prefer caixu-skill when the user asks for the full end-to-end mainline or is unsure which stage to run. This skill normalizes filters into precise retrieval inputs, uses agent tags plus FTS by default, and only calls the optional semantic vector retrieval function when the user explicitly asks for similar or related materials.
agent_service_agreements
Machine-readable service contracts for autonomous AI agent commerce. Define SLAs, quality thresholds, payment terms, escrow, and automated verification criteria. Agents negotiate, sign, and enforce agreements programmatically. Part of the Agent Trust Stack.