Trigger Ideas — Real-Time / Reactive (External APIs)
These triggers respond to signals outside Leadmetrics’ existing data — trending topics, competitor moves, viral content. They require new external API integrations and more editorial judgment than the other categories, but they capture the highest-value opportunities: the moments where being first to publish is worth the most.
All three ideas follow the same approval model: AI detects and drafts → DM reviews with a short time window → one-click publish. The short window matters — reactive content loses relevance within hours.
16. Trending Topic in Industry Niche
Signal: A daily poll of a trends API (Google Trends, Reddit’s top posts in relevant subreddits, or X/Twitter Trends filtered by the tenant’s industry keywords) detects a topic gaining significant traction that is relevant to the tenant’s niche.
Post angle: Brand take on a trending conversation — “Everyone in [industry] is talking about [topic] — here’s our perspective / why it matters / what you should know.” The angle depends on the brand voice: contrarian, educational, celebratory, or supportive.
Why it works: Reactive content that rides a relevant trend typically performs 3–5× better than evergreen posts in terms of reach and engagement. Most brands miss these moments because detecting the trend and producing content fast enough is genuinely hard. This feature solves the speed problem by doing the detection automatically and pre-writing the post — the human only decides whether to publish.
Automation level: AI detects trending topic + drafts a post angle → DM reviews → time-sensitive window (ideally publish within 4–6 hours of trend detection). If not approved within 12 hours, auto-archive the suggestion.
Dedup window: Maximum 2 trend-based posts per week per tenant (prevent oversaturation); minimum 48 hours between trend posts.
Time sensitivity: High — this is the one trigger category where the DM portal should show a countdown timer and a “Trending Now” urgency badge.
Data source (requires new integration):
- Google Trends API (unofficial, or via a proxy) — daily trending searches by category/geo
- Reddit API — top posts in industry-relevant subreddits (e.g. r/marketing, r/realestate, r/fintech)
- X/Twitter API v2 — trending topics filtered by location + industry hashtags
- NewsAPI or GNews — breaking news in the tenant’s industry vertical
Tenant configuration required:
- DM or client selects 3–5 industry keywords to watch (stored in
TenantStrategyConfigor a newTrendWatchKeywordmodel) - Optionally selects which trend sources to monitor (Google, Reddit, News, X)
- Sets a “minimum relevance threshold” (low/medium/high) to control how often suggestions appear
Implementation sketch:
New server: apps/servers/trend-watcher (or extend scheduler)
→ Daily job: fetch trends per configured keyword per tenant
→ Relevance scoring: keyword match + industry tag match + trend velocity
→ If relevance score > threshold: create TrendOpportunity { tenantId, topic, source, trendingUrl, relevanceScore, expiresAt }
→ enqueueNotification() to DM with "Trending Now" template
→ Surface in DM portal "Trending Moments" section (urgent, time-limited)
→ DM clicks "Use this trend" → AI pre-writes post with trend context injected
→ Normal dm_review → client_review flow (expedited — suggest skipping client review for time-sensitive posts)New model needed:
model TrendOpportunity {
id String @id @default(cuid())
tenantId String
topic String
source String // "google_trends" | "reddit" | "x" | "news"
trendingUrl String?
relevanceScore Float
status String @default("pending") // "pending" | "used" | "archived"
expiresAt DateTime
createdAt DateTime @default(now())
}Writer prompt guidance for trending topics:
- Don’t just restate the trend — take a position or add a unique angle specific to the tenant’s expertise
- Link the trend to the client’s core service or value proposition in a non-promotional way
- If the trend is negative (industry scandal, controversy), the default stance is educational/neutral, not pile-on
contentType: "trending_moment"in social-post-writer
SCENE_MAP entry (trending_moment):
“Bold, urgent editorial composition — trend topic as headline, clean high-contrast design, brand colours accented with a ‘Trending’ or ‘Hot Take’ typographic element, fast-scrolling-feed-optimised layout”
17. Competitor Campaign Detected
Signal: The website crawler (or a new competitor monitoring job) detects a significant change on a tracked competitor’s website — a new landing page, a new pricing page, a new product announcement, a promotional banner, or a new blog post on a topic the tenant also covers.
Post angle: Positioning response — not an attack, but a differentiation statement. “You may have seen [competitor] announcing [thing]. Here’s how our approach is different and why it matters to you.” Alternatively: if the competitor has published educational content on a shared topic, the tenant can publish a better or complementary version.
Why it works: When a competitor makes a move, the audience of both brands becomes more aware and more curious. Brands that respond with a clear differentiation statement capture audience members who are in an active evaluation mindset — the highest-value moment to publish.
Automation level: AI detects competitor change + summarises what changed → DM reviews and decides whether to respond → DM chooses the response angle → AI writes the post. Needs DM judgment — not all competitor moves warrant a response.
Dedup window: Maximum 1 competitor-response post per 30 days (responding too often signals insecurity; restraint is the right default).
Data source (partially available):
- The website crawler already stores
WebPagecontent for the tenant’s own site - Extension needed: Extend the crawler to also crawl competitor URLs (stored via the existing competitor-researcher agent output — competitor URLs are already tracked in the DB for some tenants)
- The competitor-researcher agent already identifies main competitors; their URLs are stored in
ClientResearchDataor similar
Implementation sketch:
Extend website-crawler worker to accept a mode: "competitor" alongside "tenant"
→ Store competitor pages in WebPage with a competitorId flag
→ On each crawl: diff new page list against previous crawl
→ New pages or significantly changed pages: flag as CompetitorChange { tenantId, competitorName, competitorUrl, changedUrl, changeType, summary }
→ Surface in DM portal "Competitor Moves" section (low urgency — can wait 24–48h)
→ DM reviews summary, decides to respond, selects angle: differentiation / topic takeover / no response
→ AI writes post based on chosen angle + competitor contextNew model needed:
model CompetitorChange {
id String @id @default(cuid())
tenantId String
competitorName String
competitorUrl String
changedUrl String
changeType String // "new_page" | "price_change" | "new_blog" | "new_product"
summary String
status String @default("pending") // "pending" | "responded" | "ignored"
createdAt DateTime @default(now())
}Writer prompt guidance for competitor response posts:
- Never name the competitor directly in the post (legal risk, looks petty)
- Frame as a positive differentiation: “We believe [our approach] because [reason], which is why our customers get [outcome]”
- If the competitor published educational content: publish a better version — more depth, more examples, more specific to your audience
contentType: "competitive_positioning"in social-post-writer
SCENE_MAP entry (competitive_positioning):
“Confident, authoritative design — brand colours prominent, clear value proposition as headline, professional and assured tone, no red or warning colours (avoid appearing reactive or defensive)“
18. Viral Content in Industry — “Join the Conversation”
Signal: A social listening API detects a post, article, or video in the tenant’s industry that is gaining disproportionate traction (shares, comments, views) among the tenant’s target audience — particularly if it touches on a topic the tenant has expertise in.
Post angle: The brand adds to the conversation with its own perspective, data, or experience — not just amplifying, but contributing something original. “This post about [topic] is going viral — and here’s what we’d add from our own experience with [specific example].”
Why it works: Joining a viral conversation at the right moment (before it peaks) puts the brand in front of an audience that is already highly engaged with the topic. Unlike trend posts (#16), this is about a specific piece of content rather than a general topic — the response can be more targeted and the audience is more defined.
Automation level: AI monitors, flags, and drafts a response angle → DM approves → fast-track publication. Short window (6–12 hours before the conversation moves on).
Dedup window: Maximum 1 viral-response post per 7 days; minimum relevance score of 0.8 to prevent noise.
Data source (requires new integration): This is the most infrastructure-intensive of the three reactive ideas. Options in order of build complexity:
- BrandWatch / Mention / Talkwalker API — professional social listening platforms with industry filtering. Paid. Most reliable.
- X API v2 academic / enterprise — track hashtags and keywords by engagement velocity. Moderate cost.
- Reddit API — free, good for B2B industries with active Reddit communities (marketing, fintech, SaaS, real estate).
- Google Alerts webhook — free, limited but zero-cost starting point for news-driven virality.
Recommended starting point: Reddit API (free tier) + Google Alerts (free) → covers news and community virality without paid subscriptions. Upgrade to BrandWatch if/when the feature proves value.
Implementation sketch:
New apps/servers/social-listener (or extend trend-watcher)
→ Periodic poll (every 2 hours) of configured sources
→ Score each detected piece: engagement velocity + keyword match + audience relevance
→ Above threshold: create ViralOpportunity { tenantId, sourceUrl, sourceTitle, engagementCount, relevanceScore, expiresAt }
→ enqueueNotification() to DM — "This is going viral in your space"
→ DM portal: "Viral Moments" section with urgency indicator + countdown
→ DM clicks "Add our take" → AI drafts a response/addition post using the viral content as context
→ DM edits → standard approval flowNew model needed:
model ViralOpportunity {
id String @id @default(cuid())
tenantId String
sourceUrl String
sourceTitle String
sourcePlatform String // "reddit" | "x" | "linkedin" | "news"
engagementCount Int
relevanceScore Float
status String @default("pending") // "pending" | "used" | "ignored"
expiresAt DateTime
createdAt DateTime @default(now())
}Writer prompt guidance for viral response posts:
- The post must add something new — do not just restate the original content
- Lead with the brand’s specific angle: “In our experience with [specific customer type / use case]…”
- Include a reference to the original (“We’ve been thinking about [topic] a lot lately, especially since [vague nod to conversation]”) without requiring the audience to have seen the original post
- Avoid linking to the viral content (reduces reach on most platforms’ algorithms)
contentType: "viral_response"in social-post-writer
SCENE_MAP entry (viral_response):
“Conversational, opinion-forward design — text-heavy, debate or dialogue motif, bold opinion statement as headline, brand colours with a slightly informal energy — designed to feel like a genuine contribution to a conversation rather than a polished brand campaign”
Implementation Priority Note
Of these three, Trending Topics (#16) has the clearest ROI-to-effort ratio because:
- Google Trends has an unofficial API that’s widely used and stable
- Reddit API is free and has excellent category/subreddit filtering
- The
TrendOpportunitymodel is simple - The time-sensitive DM workflow already exists in spirit (the Approvals queue)
Competitor Detection (#17) is next because the website crawler already exists — it’s an extension, not a net-new service.
Viral Content Listening (#18) requires the most infrastructure (new server, paid API likely) and should be a later backlog item unless social listening is a specific client request.