handle-complaint — Claude Code skill for customer complaints
Walks a customer complaint end to end: pulls order history, drafts a reply and points at the process fix behind the problem.
npx skills add ilyautov/small-business-ru --skill handle-complaint -a claude-codeWhat handle-complaint does
The skill takes an incoming grievance and works through it in four steps. It pulls the thread by email or ticket ID, or by the word for the most recent unresolved complaint. Then it builds context: past purchases, earlier complaints and deal stage from ~~crm, order and refund status from ~~payments.
The reply is tuned to the situation. A first complaint from a customer with a long purchase history gets a warmer tone; someone who has complained before gets a firmer one. The draft never leaves the skill on its own. Refunds and compensation stay suggestions too, and the owner makes the call.
Step four looks for repetition. When similar complaints have come up before, the skill names how many and proposes a specific change to the process; a one-off case is reported as exactly that. Access matters here: with neither mail nor CRM reachable, you paste the complaint text in by hand. Without ~~payments, order status is out of reach and the skill says so. Wording about returns follows the general consumer-protection framework rather than inventing clauses or deadlines.
Two neighbouring skills do part of the work: ticket-deflector for reading and answering, customer-pulse for spotting repeats.
What it helps with
- read a customer complaint without losing the thread history
- gather purchase and complaint history before replying
- draft a response in a tone that fits the case
- spot a recurring cause behind complaints and propose a fix
- check order and refund status for one customer
Example prompts for the agent
- Work through the complaint on ticket
~~crm 4821and show me the draft reply - Take the latest unresolved complaint and suggest what to fix in the process
- Pull the customer history and draft an answer about a product quality complaint
How to install handle-complaint
1Skills CLI (Vercel)
npx skills add ilyautov/small-business-ru --skill handle-complaint -a claude-code2Manually: put the files in place
~/.claude/skills/handle-complaint/SKILL.mdCopy the whole skill folder; for one project use .claude/skills/handle-complaint/
1Skills CLI (Vercel)
npx skills add ilyautov/small-business-ru --skill handle-complaint -a codex2Manually: put the files in place
.agents/skills/handle-complaint/SKILL.mdFor all projects use ~/.agents/skills/
1Skills CLI (Vercel)
npx skills add ilyautov/small-business-ru --skill handle-complaint -a cursor2Manually: put the files in place
.cursor/skills/handle-complaint/SKILL.mdCursor also reads .agents/skills/ and .claude/skills/
1GitHub CLI
gh skill install ilyautov/small-business-ru handle-complaint2Manually: put the files in place
.github/skills/handle-complaint/SKILL.md1Skills CLI (Vercel)
npx skills add ilyautov/small-business-ru --skill handle-complaint -a gemini-cli2Platform CLI
gemini skills install https://github.com/ilyautov/small-business-ru --path small-business-ru/skills/handle-complaintManually: put the files in place
.devin/skills/handle-complaint/SKILL.mdThe legacy .windsurf/skills/ path still works
Skills CLI (Vercel)
npx skills add ilyautov/small-business-ru --skill handle-complaint -a opencodeClaude.ai
Zip the folder and upload it in Settings → Capabilities → Skills
Step by step, with commands for each platform: How to install skills in Claude Code: five ways
Questions about handle-complaint
How do I install handle-complaint in Claude Code?
Run npx skills add ilyautov/small-business-ru --skill handle-complaint -a claude-code. The skill lands at ~/.claude/skills/handle-complaint/SKILL.md.
What does handle-complaint do?
It runs a complaint through four steps: loading the thread, collecting customer context, drafting a reply and proposing a process fix. Nothing is sent or refunded without the owner's approval.
What does the skill need to work?
Mail or CRM access to read the thread. If both connectors are down, you paste the complaint text yourself and the skill works from that.
Source text
SKILL.md · Apache-2.0
---
name: handle-complaint
description: >
Обрабатывает входящую жалобу клиента от начала до конца — подтягивает контекст, готовит ответ и предлагает операционное исправление. Принимает необязательный аргумент — ID письма или обращения. Командная форма: вызывается по имени.
allowed-tools: Read, WebFetch
---
<!-- Производное от Anthropic knowledge-work-plugins / small-business (Apache-2.0, (c) Anthropic). Локализовано под РФ, файл изменён. См. /NOTICE и /LICENSE. -->
Злой клиент — это ещё спасаемый клиент, если ответить быстро и по делу. Скилл поднимает историю и заказ, готовит ответ под остроту ситуации и заодно подсказывает, что починить, чтобы та же жалоба не пришла снова.
Запустите разбор жалобы, связав два скилла. Прочитайте жалобу, соберите контекст, подготовьте ответ и предложите исправление, чтобы это не повторилось.
Разбор аргументов:
- `EMAIL_OR_TICKET_ID` (необязательно) — ID письма (`~~почта`), ID обращения (`~~crm`) или «последняя», чтобы взять самую свежую нерешённую жалобу. Если не указан — попросите владельца вставить текст жалобы.
## Шаг 1 — Загрузить жалобу (ticket-deflector)
По рабочему процессу скилла `ticket-deflector`:
1. Если дан ID: подтяните полную переписку из `~~почты` или `~~crm`.
2. Если «последняя»: подтяните самое свежее нерешённое обращение из `~~crm` или письмо из `~~почты` с пометкой жалоба/поддержка.
3. Если ничего нет: попросите владельца вставить текст жалобы напрямую.
4. Определите: имя клиента, данные заказа/счёта, чем недоволен, что просит.
## Шаг 2 — Собрать контекст
1. Найдите историю клиента в `~~crm`: прошлые покупки, прежние жалобы, стадия сделки, сумма покупок за всё время.
2. Найдите связанную операцию в `~~платежах`: статус заказа, история возвратов, статус спора.
3. Сведите итог: «Это {новый/постоянный} клиент, покупок на {сумма} ₽, {0/N} прежних жалоб. Текущая проблема — {одно предложение}.»
## Шаг 3 — Подготовить ответ (ticket-deflector)
По рабочему процессу скилла `ticket-deflector` (ответ в подобранном тоне):
1. Подготовьте ответ под остроту ситуации и историю клиента:
- Впервые жалуется, много покупок → с пониманием, щедро
- Жалуется повторно → корректно, твёрдо, по делу
- Хамит → корректно, кратко, с обозначением границ
2. Включите: признание, объяснение (если известно), предложение решения, следующий шаг.
3. ⚠️ Если жалоба про возврат/качество товара — действуйте в общей рамке закона «О защите прав потребителей», не выдумывайте конкретные статьи и сроки. При сомнении — «уточните условия возврата».
4. Покажите черновик владельцу. НЕ отправляйте.
## Шаг 4 — Предложить операционное исправление (customer-pulse)
1. Проверьте, попадает ли жалоба в известную тему (из прошлых запусков `customer-pulse-check` или похожих жалоб в `~~crm`).
2. Если это паттерн: «Это {N}-я жалоба про {проблема} за месяц. Стоит рассмотреть: {конкретное изменение}.»
3. Если единичный случай: «Похоже на разовый случай. Паттерн не обнаружен.»
## Сбои коннекторов
Если `~~почта` и `~~crm` обе недоступны — попросите владельца вставить текст жалобы; скилл работает с ручным вводом. Если нет `~~платежей` — пропустите поиск операции и отметьте «Платежи не подключены — статус заказа недоступен, работаю по тексту жалобы».
## Точки подтверждения (approval gates)
- **Никогда не отправляйте ответ без явного одобрения владельца.** Только черновики.
- **Никогда не оформляйте возвраты или компенсации автоматически.** Покажите вариант — решает владелец.
- **Никогда не закрывайте обращения и не разрешайте споры без подтверждения владельца.**
## Вывод
Покажите сводку контекста по клиенту, черновик ответа и операционное предложение (если есть паттерн). Спросите: «Отправить этот ответ, отредактировать или поступить иначе?»
© ilyautov · Apache-2.0 · ilyautov/small-business-ru