Flag high-intent website visitors to sales
Identify promising accounts on your site, enrich them, and tell the right owner with useful context.
high-intent-visitors.md
Flag high-intent website visitors to sales
Set up the tools below, then run the steps in order for the user.
Inputs
Ask the user for these before you start.
pricing_path: the page that signals intent, e.g. /pricingalerts_channel: where to post, e.g. #sales-signals
Set up
Run a SQL query (PostHog, tool:posthog/run-sql-query)
Use the first option your agent supports.
MCP (official, remote)
Add this server to your agent's MCP settings, then sign in when asked.
{ "mcpServers": { "posthog": { "url": "https://mcp.posthog.com/mcp" } } }
Call the MCP tool execute-sql.
CLI (official)
Install the command, then confirm it runs.
npm install -g @posthog/cli@latest
posthog-cli --version
Run posthog-cli api call execute-sql.
Set $POSTHOG_CLI_API_KEY in your environment first (get a key: https://app.posthog.com/settings/user-api-keys?preset=mcp_server).
Run a routine (Clay, tool:clay/run-routine)
Use the first option your agent supports.
CLI (official)
Install the command, then confirm it runs.
npm install --global @clay-run/cli
clay --version
Run clay routines runs start.
API (official)
- Base URL: https://api.clay.com/public/v0
- Endpoint:
POST /routines/{routine_id}/run - Auth: send the header
clay-api-key: $CLAY_PUBLIC_API_KEY - Get a key: https://app.clay.com/workspaces/~/settings/account?accountTab=api-keys-beta
Post a message (Slack, tool:slack/post-message)
Use the first option your agent supports.
MCP (official, remote)
Add this server to your agent's MCP settings, then sign in when asked.
{ "mcpServers": { "slack": { "url": "https://mcp.slack.com/mcp" } } }
Call the MCP tool slack_send_message.
CLI (official)
Install the command, then confirm it runs.
curl -fsSL https://downloads.slack-edge.com/slack-cli/install.sh | bash
slack --version
Run slack api chat.postMessage.
Set $SLACK_BOT_TOKEN in your environment first (get a key: https://api.slack.com/apps).
Make one read-only call to each tool to confirm access.
Steps
- Find repeat visitors with Run a SQL query (PostHog). List identified accounts that viewed
pricing_pathat least twice in the last 7 days. - Enrich with Run a routine (Clay). For each account domain, add company size, industry and any open hiring for sales or marketing.
- Alert with Post a message (Slack). Post one message per account to
alerts_channelwith the enrichment and a suggested owner. Ask the user before posting the first one.
Done when
- Every qualifying account was posted once, with no duplicates.
- The user has the list of accounts and suggested owners.
Rules
- Only use the tools listed above.
- Ask the user before anything that sends messages, costs money, or changes data.
- Never print API keys.
Built from these files in the repository
- workflows/high-intent-visitors.md
- companies/posthog/tools/run-sql-query.md
- companies/posthog/company.md
- companies/clay/tools/run-routine.md
- companies/clay/company.md
- companies/slack/tools/post-message.md
- companies/slack/company.md
The layout and the rules come from lib/catalog/render-markdown.ts, the set-up wording from lib/catalog/render-access.ts.
