Monday, August 25, 2025

๐Ÿ’ป Hashtag Rotator Service ReadMe

Hashtag Rotator Service – Audit-Ready README

๐ŸŒ Hashtag Rotator Service

A public-facing, region-aware microservice that fetches live trending hashtags from verified sources and rotates them in civic dashboards. Built for transparency, diagnostics, and real-time civic engagement.

๐Ÿš€ Live Deployment

Production URL

๐Ÿงฑ Modules Deployed

ModuleStatusTimestampCommit ID
.gitignore✅ Deployed2 hours ago84284d29
fallbackHashtags.js✅ Deployed14 hours ago31b106dc
constants.js✅ Deployed14 hours ago3b46b570
diagnostics.js✅ Deployed15 hours ago92e809ed
rotator.js (Kenya)✅ Deployed15 hours ago209e1983
script.js✅ Deployed17 hours ago517b6d79
index.html✅ Deployed18 hours ago38b7174f
server.js✅ Deployed18 hours agof3fd893e
scrape-trends24.js✅ Deployed18 hours ago01cff475
webhook-diagnostics.js✅ Deployed19 hours ago39e15623
webhook-listener.js✅ Deployed19 hours ago3423140f
cron.js✅ Deployed20 hours ago2eae4d5a
trends24-cache.js✅ Deployed20 hours ago4f78c1f3

๐Ÿ“ก Features

  • ✅ Live hashtag scraping from Trends24 and CyberKendra
  • ๐ŸŒ Region toggles: Kenya, Nigeria, USA, UK, India
  • ๐Ÿงช Diagnostics panel with fallback detection
  • ๐Ÿฆ Tweet CTA generator with civic messaging
  • ๐Ÿ“Š Rotator module with refresh intervals
  • ๐Ÿ” Webhook listeners for real-time updates
  • ๐Ÿงพ Audit-ready fallback logic and timestamping

๐Ÿง  How It Works

// Fetch hashtags from live endpoint
const res = await fetch('/api/rotator?region=kenya');
const data = await res.json();
const hashtags = data.hashtags || [];
<a href="https://twitter.com/intent/tweet?text=#JusticeforJuliaNjoki%20%23OccupyCBDTuesday%20%23AuditReady" target="_blank">
  Tweet This Civic Signal ๐Ÿ“ข
</a>

๐Ÿ› ️ Setup

  1. Clone the repo:
    git clone https://github.com/pmmutiti/hashtag-rotator-service.git
  2. Install dependencies:
    npm install
  3. Set environment variables:
    cp .env.example .env
  4. Run locally:
    npm run dev

๐Ÿงช Diagnostics Endpoint

GET /api/diagnostics
{
  "status": "๐Ÿงช Diagnostics OK",
  "fallbackEnabled": false,
  "timestamp": "2025-08-25T11:58:00Z",
  "regionsSupported": ["kenya", "nigeria", "usa", "uk", "india"]
}

๐Ÿ“ File Structure

├── api/
│   ├── rotator.js
│   ├── diagnostics.js
│   ├── scrape-trends24.js
│   ├── webhook-listener.js
│   └── cron.js
├── public/
│   └── index.html
├── utils/
│   ├── constants.js
│   ├── fallbackHashtags.js
│   └── trends24-cache.js
├── .vercelignore
├── .gitignore
├── vercel.json
└── README.md

๐Ÿ“ข Civic Hashtags Used

HashtagContext
#JusticeforJuliaNjokiCivic protest signal from Kenya
#ShootFirstSirPolice accountability
#WeAreAllKikuyusAnti-tribalism solidarity
#OccupyCBDTuesdayUrban protest movement
#DigitalKenyaCivic tech and transparency
#CivicInfraInfrastructure for public oversight
#AuditReadyVerified, traceable civic modules

๐Ÿงพ License

MIT — Built for civic clarity, not corporate opacity.

๐Ÿง  Author

Peter M. Mutiti
Civic watchdog, dashboard architect, rotator reformer.
๐Ÿ“ Nairobi, Kenya
๐Ÿ› ️ View Live Service

No comments:

Post a Comment

๐Ÿ“Š The immortal Executive Dashboard That Gives You "God" Level Visibility: From Data Overload to Clarity: How This Dashboard Simplifies Your Decisions

Executive Dashboard | HealthTrend Cognitive Platform ๐Ÿง  HEALTHTREND COGNITIVE ...