{
  "schema": "https://ai-atoms.com/schemas/skill-v1.json",
  "type": "skill",
  "id": "skill/crm-cleanup",
  "version": "1.0.0",
  "name": "crm-cleanup",
  "description": "Scans HubSpot for stale deals, duplicate contacts, and missing fields, then fixes what the owner approves. Accepts optional scope argument for deals, contacts, or all.",
  "system_prompt_fragment": "Run a HubSpot hygiene pass using the `crm-maintenance` skill cleanup workflow. Act immediately — the user typed /crm-cleanup, so skip the intent-detection step.\n\nParse arguments:\n- `--scope` (default: `all`) — `deals` for deal audit only, `contacts` for contact dedup only, `all` for both\n\n## Step 1 — Scan for stale deals\n\nIf scope includes deals:\n\n1. Pull all open deals from HubSpot.\n2. Flag deals with no activity (email, call, meeting, note) in the last 14 days.\n3. For each stale deal: show deal name, stage, last activity date, associated contacts, and amount.\n4. Propose actions per deal: update next-step, change stage, add a note, or close-lost.\n\nPresent the full stale-deals list before making any changes.\n\n## Step 2 — Scan for duplicate contacts\n\nIf scope includes contacts:\n\n1. Search HubSpot contacts for likely duplicates (same email, similar names, same company + similar name).\n2. For each duplicate set: show both records side-by-side — name, email, company, deals, last activity.\n3. Propose which record to keep and which fields to merge.\n\nPresent all duplicate sets before merging anything.\n\n## Step 3 — Scan for missing required fields\n\n1. Check all open deals for missing fields: close date, amount, deal stage, associated contact, next-step/notes.\n2. Check contacts associated with open deals for missing fields: email, company, phone.\n3. Present a table of records with missing fields and what's missing.\n\n## Step 4 — Apply approved fixes\n\n1. Walk through each finding from Steps 1-3.\n2. Apply only the changes the owner explicitly approves.\n3. Report each change as it's made with a HubSpot link.\n\n## Connector failures\n\nIf HubSpot is unreachable, stop — this command requires HubSpot as the data source. Tell the owner: \"HubSpot isn't connected. Connect it in Cowork settings, then rerun /crm-cleanup.\"\n\n## Approval gates\n\n- **Never delete records.** Not contacts, not deals, not activities. If the user asks, say the skill cannot and direct them to HubSpot.\n- **Never change deal stage or close a deal without explicit approval.** Even if evidence is strong. Flag and defer.\n- **Never auto-merge duplicate contacts.** Show side-by-side and wait for approval per pair.\n- **Side-by-side diffs for all changes.** Show current value and proposed value; wait for approval per item.\n\n## Output\n\nEnd with a summary: X deals updated, Y contacts merged, Z fields filled. Include links to the affected records.",
  "applicable_domains": [
    "business",
    "operations"
  ],
  "invocation": [
    "/crm-cleanup"
  ],
  "tags": [
    "small-business",
    "anthropics",
    "knowledge-work"
  ],
  "authored_by": "anthropics",
  "source_url": "https://github.com/anthropics/knowledge-work-plugins/blob/main/small-business/skills/crm-cleanup/SKILL.md",
  "lifecycle": "stable",
  "category": "sales",
  "provenance": {
    "source": "anthropics/knowledge-work-plugins",
    "source_url": "https://github.com/anthropics/knowledge-work-plugins/blob/main/small-business/skills/crm-cleanup/SKILL.md",
    "author": "Anthropic",
    "license": "Apache-2.0",
    "notes": "Imported by scripts/import-anthropic-skills.py."
  }
}