A mini AI agent that generates customer health summaries using Claude and the Plain support platform.
Given a company name, the agent queries Plain via MCP to retrieve support threads, identifies risk signals, and returns a structured JSON summary of customer health.
- Node.js 18+
- A Plain account with an API token
- An Anthropic API key
-
Install dependencies:
npm install
-
Create a
.envfile in the project root:ANTHROPIC_API_KEY=your_anthropic_api_key PLAIN_MCP_TOKEN=your_plain_mcp_token
npm start "hot customer overview for Acme Corp"The agent returns a JSON object with the customer health summary.
agent.ts— entry point; loads skill metadata, calls Claude with MCP access to Plain and a bash tool.claude/skills/hot-customer/— skill definition that instructs Claude how to analyze customer data and format output