{
  "$schema": "../workflow-recipe.schema.json",
  "format": "revenanas.workflow-recipe/v1",
  "slug": "clay-champion-tracking",
  "title": "How to track customer champion job changes with Clay",
  "job": "Detect credible employer changes among known champions and create a reviewable follow-up signal for the responsible account owner.",
  "tools": ["Clay", "HubSpot"],
  "service": {"name": "Proactive Trigger System", "url": "https://www.revenanas.com/services/proactive-trigger-system"},
  "importability": {"clay": "manual-build", "notes": "This is a workflow specification. Pair it with a public Clay template after a live table has been tested.", "template_url": null},
  "inputs": [
    {"name": "contact_id", "type": "string", "required": true, "description": "CRM contact identifier."},
    {"name": "linkedin_url", "type": "url", "required": true, "description": "Primary identity key for employment checks."},
    {"name": "known_company", "type": "string", "required": true, "description": "Last verified employer."},
    {"name": "account_owner_id", "type": "string", "required": true, "description": "Person responsible for reviewing the signal."}
  ],
  "outputs": [
    {"name": "current_company", "type": "string", "required": false, "description": "Newly verified employer."},
    {"name": "job_change_confidence", "type": "enum", "required": true, "description": "high, review, or none."},
    {"name": "signal_summary", "type": "string", "required": false, "description": "Evidence-backed change summary."},
    {"name": "review_owner_id", "type": "string", "required": false, "description": "CRM owner receiving the task or alert."}
  ],
  "steps": [
    {"id": "01-source", "action": "Load the approved champion cohort", "purpose": "Monitor contacts whose relationship value justifies recurring checks.", "configuration": {"schedule": "weekly"}},
    {"id": "02-check", "action": "Resolve current employment", "purpose": "Compare a fresh employer against the last verified company.", "configuration": {"key": "linkedin_url"}},
    {"id": "03-verify", "action": "Require corroborating evidence", "purpose": "Avoid outreach triggered by stale profiles or ambiguous names.", "configuration": {"high_confidence_requires": ["same person identity", "different current company", "recent supporting evidence"]}},
    {"id": "04-route", "action": "Route high-confidence changes for review", "purpose": "Give the account owner context before any outreach happens.", "configuration": {"automatic_send": false}},
    {"id": "05-writeback", "action": "Update monitoring fields after review", "purpose": "Keep the next comparison anchored to a verified state.", "configuration": {"fields": ["last_verified_company", "last_verified_at", "job_change_status"]}}
  ],
  "guardrails": ["Never send outreach solely from an unverified job-change result.", "Use stable person identifiers to prevent same-name matches.", "Keep a review path for unclear dates or overlapping roles.", "Do not overwrite the historical employer before the signal is reviewed."],
  "test_cases": [{"name": "Stale profile", "input": {"known_company": "Acme", "current_company": "Acme"}, "expected": "none"}]
}
