marketing
Production sales system. Use when user wants to (1) create product/customer/operator - create records with optional --mock for auto-generation, (2) read/update/delete - manage records, (3) list - view database, (4) call - start sales call with info verification and permission control. Supports cold-start customers. Data stored in .ezagent/database/marketing/.
SKILL.md
| Name | marketing |
| Description | Production sales system. Use when user wants to (1) create product/customer/operator - create records with optional --mock for auto-generation, (2) read/update/delete - manage records, (3) list - view database, (4) call - start sales call with info verification and permission control. Supports cold-start customers. Data stored in .ezagent/database/marketing/. |
name: marketing description: Production sales system. Use when user wants to (1) create product/customer/operator - create records with optional --mock for auto-generation, (2) read/update/delete - manage records, (3) list - view database, (4) call - start sales call with info verification and permission control. Supports cold-start customers. Data stored in .ezagent/database/marketing/.
Marketing & Sales System (Production)
Production-grade sales response system with:
- Information verification: Query systems before making claims
- Permission control: Offers within authority limits
- Cold-start support: Handle unknown prospects, save info after call
Commands
| Command | Description |
|---|---|
create <type> | Create product/customer/operator (use --mock to auto-generate) |
read <type> | Read a specific record by name or ID |
update <type> | Update an existing record |
delete <type> | Delete a record |
list | View current database |
call | Start sales call session |
Types: product, customer, operator
create
Create a record in the database. Use --mock flag to auto-generate realistic data.
Usage
create <type> [--mock]
create product
Required Fields (ask user if not using --mock):
- name: Product name
- description: What the product does
- features: Key features list
- benefits: Customer benefits
- price: Pricing information
- target_audience: Ideal customers
- competitors: Alternative products
- objections: Common objections and rebuttals
- api_interfaces: System API definitions (see below)
- operator_permissions: Permission rules (see below)
API Interface Example:
{
"prospect_info": {
"description": "查询潜在客户信息",
"endpoint": "/api/crm/prospect/{prospect_id}",
"method": "GET",
"params": ["prospect_id"],
"response_fields": ["company", "contacts", "deal_stage"],
"mock_enabled": true
}
}
Permission Rules Example:
{
"can_approve_immediately": ["试用<30天", "折扣<10%"],
"requires_supervisor": ["试用>=30天", "折扣>=10%"],
"requires_process": ["年度框架协议"],
"forbidden": ["虚假承诺", "承诺未发布功能"]
}
create customer
Required Fields (ask user if not using --mock):
- name: Customer name
- phone: Phone number (for lookup)
- role: Job title
- company: Company description
- industry: Industry sector
- pain_points: Challenges they face
- goals: What they want to achieve
- communication_style: How they interact
- decision_authority: Can decide or needs approval
create operator
Required Fields (ask user if not using --mock):
- name: Strategy name
- methodology: SPIN, Challenger, Solution Selling, Value Selling
- approach: Overall selling philosophy
- opening: How to start conversations
- discovery_questions: Questions to understand needs
- objection_handling: How to handle objections
- closing_technique: How to close deals
- key_phrases: Effective phrases to use
For SPIN methodology details, see references/spin-selling.md.
--mock Flag
When --mock is specified, generate realistic data using templates from references/mock-templates.md.
For mock products, MUST include api_interfaces and operator_permissions fields.
Save Command
uv run scripts/save_record.py --type <type> --data '<json>'
read
Read a specific record by name or ID.
uv run scripts/get_record.py --type product --name '云客通智能CRM'
uv run scripts/get_record.py --type customer --id 'abc123'
uv run scripts/get_record.py --type operator --name 'SPIN顾问式销售'
update
Update an existing record. Provide updates as JSON.
uv run scripts/update_record.py --type customer --name '王建华' --updates '{"phone": "13800138001"}'
uv run scripts/update_record.py --type product --name '云客通智能CRM' --updates '{"price": "9999元/年"}'
uv run scripts/update_record.py --type operator --id 'abc123' --updates '{"methodology": "Challenger"}'
delete
Delete a record from the database.
uv run scripts/delete_record.py --type customer --name '王建华'
uv run scripts/delete_record.py --type product --id 'abc123'
uv run scripts/delete_record.py --type operator --name 'SPIN顾问式销售' --force
list
uv run scripts/list_records.py # All records
uv run scripts/list_records.py --type product # Products only
uv run scripts/list_records.py --verbose # Detailed view
call
Start a production sales call session.
Step 1: Session Initialization
Required parameters from user:
- product: Product name to sell
- operator: Sales strategy name
- prospect_phone (optional): Prospect's phone number
If prospect_phone provided, search for existing customer. If not found, create cold-start prospect record.
If no phone provided, ask user to provide customer name OR indicate this is a new prospect.
Step 2: Load Session Data
- Search for product in
.ezagent/database/marketing/products/ - Search for operator in
.ezagent/database/marketing/operators/ - Search/create customer:
- If phone: lookup by phone, create cold-start if not found
- If name: lookup by name
- If new prospect: create cold-start record
If product or operator NOT found: Stop and report error.
Step 3: Start Call
Display session start:
--- 销售通话已开始 ---
联系方式: {phone}
产品: {product_name}
客户: {customer_name} {如果是冷启动: [新潜客]}
策略: {operator_name}
---
You are the sales representative. Use operator strategy to guide your approach.
Step 4: Information Verification (CRITICAL)
Before making claims about pricing, availability, or capabilities, verify first:
-
When discussing pricing or discounts:
【系统查询 - Mock】 接口: GET /api/pricing/{product_id}?customer_tier=enterprise 目的: 确认当前定价和可用折扣 ---Generate mock response, then quote based on result.
-
When customer asks about specific features:
【系统查询 - Mock】 接口: GET /api/product/{product_id}/features 目的: 确认功能是否已发布 --- -
When checking prospect history (for returning prospects):
【系统查询 - Mock】 接口: GET /api/crm/prospect/{phone}/interactions 目的: 查看之前的沟通记录 ---
Step 5: Permission Control (CRITICAL)
Before agreeing to customer requests, check permissions:
When customer requests special terms (extended trial, bigger discount, custom features, etc.):
-
Check against
operator_permissionsin product data -
Display permission check:
【权限检查结果】 操作: 提供15天试用 状态: ✓ 可立即批准 说明: 在权限范围内(试用<30天) --- -
If requires approval:
【权限检查结果】 操作: 提供一年试用 状态: ⚠ 需要主管审批 说明: 超出当前权限(试用>=30天) 流程: 请告知客户需要申请特批,预计1-2个工作日 --- -
Respond appropriately:
- Approved: "好的,我可以为您安排15天的试用..."
- Needs supervisor: "一年的试用需要我向上级申请特批,您看我先帮您安排一个月的试用,同时并行申请?"
- Needs process: "这种年度框架协议需要走正式流程,我帮您对接我们的商务团队..."
- Forbidden: "这个我没办法承诺,不过我可以..."
Step 6: Conversation Guidelines
Response pattern:
- Use discovery questions from operator strategy
- Query relevant system before making specific claims (show mock block)
- Check permission before offering special terms (show permission block)
- Tailor pitch based on customer pain points
Example exchange:
客户: 听起来不错!你们能给我申请一年的免费试用吗?
【权限检查结果】
操作: 一年免费试用
状态: ⚠ 需要主管审批
说明: 超出当前权限(试用>=30天)
---
【系统查询 - Mock】
接口: GET /api/pricing/product001?customer_tier=enterprise
响应: {
"trial_policy": {
"standard": "14天",
"extended": "30天(需审批)",
"enterprise": "可商议"
}
}
---
销售: 一年的试用确实需要特别审批。不过我可以先帮您安排30天的深度试用,让您的团队充分体验。同时,我会向我的主管申请更长的试用期——根据我们的政策,企业客户是可以商议的。您觉得这样可以吗?
Step 7: End Call and Save
When user says "结束通话", "end call", or "exit":
-
Display:
--- 销售通话已结束 --- -
Collect information learned during call (for cold-start prospects):
- Prospect's actual name
- Company information
- Pain points discovered
- Decision-making process
- Budget/timeline indicators
- Next steps agreed
-
Build conversation array:
[ {"role": "salesperson", "content": "..."}, {"role": "customer", "content": "..."} ] -
Generate review:
{ "opening_effectiveness": "...", "discovery_quality": "...", "objection_handling": "...", "value_presentation": "...", "closing_attempt": "...", "next_steps": ["..."], "customer_updates": { "name": "李总", "company": "XX科技", "pain_points": ["效率低", "成本高"], "deal_stage": "demo_scheduled" } } -
Save session (includes customer info update for cold-start):
uv run .claude/skills/marketing/scripts/save_session.py \ --claude-session "<claude_code_session_id>" \ --product "<product_name>" \ --customer "<customer_name>" \ --operator "<operator_name>" \ --conversation '<json_conversation>' \ --review '<json_review>' \ --update-customer '<customer_updates_json>'Session ID Format:
mk_{YYYYMMDD}_{seq}_{claude_session_id}mk: marketing 类型前缀YYYYMMDD: 日期seq: 当天序号(3位数字,如 001)claude_session_id: 当前 Claude Code 对话的 session ID
示例:
mk_20260125_001_abc123 -
Display review to user with actionable feedback.
Database Structure
.ezagent/database/marketing/
├── products/
│ └── <id>_<name>/
│ ├── info.json # Includes api_interfaces, operator_permissions
│ └── README.md
├── customers/
│ └── <id>_<name>/
│ ├── info.json # Includes interaction_history
│ └── README.md
├── operators/
│ └── <id>_<name>/
│ ├── info.json
│ └── README.md
└── history/
└── mk_{YYYYMMDD}_{seq}_{claude_session_id}/
├── session.json # Includes full conversation
└── README.md
Quick Reference
Mock Data Block Format
【系统查询结果 - Mock】
接口: {METHOD} {endpoint}
响应: {json_data}
---
Permission Check Format
【权限检查结果】
操作: {action}
状态: {✓ 可立即批准 | ⚠ 需要主管审批 | ⚠ 需要走流程 | ✗ 禁止操作}
说明: {reason}
---
Sales Methodologies
- SPIN: Situation → Problem → Implication → Need-Payoff
- Challenger: Teach → Tailor → Take Control
- Solution Selling: Pain → Power → Vision → Value → Control
- Value Selling: Discover → Diagnose → Design → Deliver
For detailed guidance, see references/spin-selling.md.