[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-11543":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":8,"htmlUrl":8,"language":9,"languages":8,"totalLinesOfCode":8,"stars":10,"forks":11,"watchers":12,"openIssues":13,"contributorsCount":14,"subscribersCount":14,"size":14,"stars1d":14,"stars7d":13,"stars30d":15,"stars90d":14,"forks30d":14,"starsTrendScore":14,"compositeScore":16,"rankGlobal":8,"rankLanguage":8,"license":17,"archived":18,"fork":18,"defaultBranch":19,"hasWiki":20,"hasPages":18,"topics":21,"createdAt":8,"pushedAt":8,"updatedAt":22,"readmeContent":23,"aiSummary":24,"trendingCount":14,"starSnapshotCount":14,"syncStatus":25,"lastSyncTime":26,"discoverSource":27},11543,"validly","Nova-Designs-Creative\u002Fvalidly","Nova-Designs-Creative",null,"TypeScript",114,39,38,1,0,65,4.81,"MIT License",false,"main",true,[],"2026-06-12 02:02:32","# Validly 🎯\n\n> Turn Reddit discussions into validated SaaS opportunities with AI-powered market research\n\nValidly is a Next.js application that scrapes weekly Reddit discussions from any subreddit and uses AI to identify genuine SaaS opportunities, market gaps, and user pain points.\n\n![TypeScript](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FTypeScript-007ACC?style=flat&logo=typescript&logoColor=white)\n![Next.js](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FNext.js-000000?style=flat&logo=next.js&logoColor=white)\n![Tailwind CSS](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002FTailwind_CSS-38B2AC?style=flat&logo=tailwind-css&logoColor=white)\n\n## ✨ Features\n\n- 🔍 **Smart Reddit Scraping** - Fetches top posts and comments from any subreddit\n- 🤖 **AI-Powered Analysis** - Uses Insforge AI to identify actionable SaaS ideas\n- 📊 **Opportunity Scoring** - Rates each idea with market viability and urgency scores\n- 💡 **Market Intelligence** - Extracts target customers, pricing insights, and competitors\n- 🎨 **Clean UI** - Beautiful, responsive interface built with Tailwind CSS v4\n- ⚡ **Fast & Type-Safe** - Built with Next.js App Router and TypeScript\n\n## 🚀 How It Works\n\n1. **Scrape** - Uses Decodo API to fetch Reddit HTML from top weekly posts\n2. **Structure** - Parses titles and top comments with Cheerio\n3. **Analyze** - Sends structured data to Insforge AI for market analysis\n4. **Score** - Returns validated SaaS ideas with viability scores and market insights\n\n## 📋 Prerequisites\n\n- Node.js 20+ installed\n- A [Decodo](https:\u002F\u002Fvisit.decodo.com\u002FoNza7b) API key (for Reddit scraping)\n- An [Insforge](https:\u002F\u002Finsforge.dev) API key (for AI analysis)\n\n## 🛠️ Installation\n\n1. **Clone the repository**\n   ```bash\n   git clone https:\u002F\u002Fgithub.com\u002Fyourusername\u002Fvalidly.git\n   cd validly\n   ```\n\n2. **Install dependencies**\n   ```bash\n   npm install\n   ```\n\n3. **Set up environment variables**\n   \n   Create a `.env.local` file in the root directory:\n   ```bash\n   # Required\n   DECODO_API_KEY=your_decodo_api_key_here\n   INSFORGE_API_KEY=your_insforge_api_key_here\n\n   # Optional - Customize Insforge configuration\n   INSFORGE_URL=https:\u002F\u002Fapi.insforge.dev\n   INSFORGE_MODEL=openai\u002Fgpt-4o-mini\n   INSFORGE_RESULTS_TABLE=validated_saas_ideas\n\n   # Optional - Customize Decodo scraping behavior\n   DECODO_PROXY_POOL=residential\n   DECODO_HEADLESS_MODE=true\n   DECODO_TIMEOUT_MS=30000\n   INSFORGE_TIMEOUT_MS=60000\n   ```\n\n4. **Run the development server**\n   ```bash\n   npm run dev\n   ```\n\n5. **Open your browser**\n   \n   Navigate to [http:\u002F\u002Flocalhost:3000](http:\u002F\u002Flocalhost:3000)\n\n## 🔑 Getting API Keys\n\n### Decodo API Key\n1. Visit [Decodo](https:\u002F\u002Fvisit.decodo.com\u002FoNza7b)\n2. Sign up for an account\n3. Navigate to your dashboard\n4. Copy your API key\n\n### Insforge API Key\n1. Visit [insforge.dev](https:\u002F\u002Finsforge.dev)\n2. Create an account\n3. Go to your project settings\n4. Generate and copy your API key\n\n## 📁 Project Structure\n\n```\nvalidly\u002F\n├── app\u002F\n│   ├── api\u002F\n│   │   └── analyze\u002F\n│   │       └── route.ts          # API endpoint for Reddit analysis\n│   ├── globals.css               # Global styles\n│   ├── layout.tsx                # Root layout\n│   └── page.tsx                  # Main UI page\n├── lib\u002F\n│   ├── env.ts                    # Environment variable validation\n│   ├── insforge.ts               # Insforge AI integration\n│   ├── reddit.ts                 # Reddit scraping & parsing\n│   └── types.ts                  # TypeScript type definitions\n├── public\u002F                       # Static assets\n├── .env.local                    # Environment variables (create this)\n├── next.config.ts                # Next.js configuration\n├── package.json                  # Dependencies\n└── tsconfig.json                 # TypeScript configuration\n```\n\n## 🔌 API Endpoint\n\n### `POST \u002Fapi\u002Fanalyze`\n\nAnalyzes a subreddit for SaaS opportunities.\n\n**Request Body:**\n```json\n{\n  \"subreddit\": \"saas\"\n}\n```\n\n**Response:**\n```json\n{\n  \"ideas\": [\n    {\n      \"title\": \"AI-Powered Email Automation for SMBs\",\n      \"description\": \"...\",\n      \"target_customers\": [\"Small businesses\", \"Marketing agencies\"],\n      \"estimated_pricing\": \"$29-99\u002Fmonth\",\n      \"market_score\": 8,\n      \"urgency_score\": 7,\n      \"competitors\": [\"Mailchimp\", \"ActiveCampaign\"],\n      \"source_threads\": [\n        {\n          \"title\": \"Struggling with email automation...\",\n          \"thread_url\": \"https:\u002F\u002Freddit.com\u002Fr\u002Fsaas\u002F...\"\n        }\n      ]\n    }\n  ],\n  \"posts\": [...],\n  \"metadata\": {\n    \"subreddit\": \"saas\",\n    \"analyzedAt\": \"2026-05-02T...\"\n  }\n}\n```\n\n## 🏗️ Tech Stack\n\n- **Framework:** Next.js 16 (App Router)\n- **Language:** TypeScript\n- **Styling:** Tailwind CSS v4\n- **Web Scraping:** Cheerio + Decodo API\n- **AI Analysis:** Insforge SDK\n- **Validation:** Zod\n- **JSON Repair:** jsonrepair\n\n## 🎨 Environment Variables Reference\n\n| Variable | Required | Default | Description |\n|----------|----------|---------|-------------|\n| `DECODO_API_KEY` | ✅ Yes | - | Your Decodo API key for Reddit scraping |\n| `INSFORGE_API_KEY` | ✅ Yes | - | Your Insforge API key for AI analysis |\n| `INSFORGE_URL` | ❌ No | `https:\u002F\u002Fapi.insforge.dev` | Insforge API base URL |\n| `INSFORGE_MODEL` | ❌ No | `openai\u002Fgpt-4o-mini` | AI model to use |\n| `INSFORGE_RESULTS_TABLE` | ❌ No | - | Optional database table name |\n| `DECODO_PROXY_POOL` | ❌ No | `residential` | Proxy pool type for scraping |\n| `DECODO_HEADLESS_MODE` | ❌ No | `true` | Headless browser mode |\n| `DECODO_TIMEOUT_MS` | ❌ No | `30000` | Scraping timeout in milliseconds |\n| `INSFORGE_TIMEOUT_MS` | ❌ No | `60000` | AI analysis timeout in milliseconds |\n\n## 📝 Available Scripts\n\n```bash\nnpm run dev      # Start development server\nnpm run build    # Build for production\nnpm run start    # Start production server\nnpm run lint     # Run ESLint\n```\n\n## 🤝 Contributing\n\nContributions are welcome! Please feel free to submit a Pull Request.\n\n1. Fork the repository\n2. Create your feature branch (`git checkout -b feature\u002FAmazingFeature`)\n3. Commit your changes (`git commit -m 'Add some AmazingFeature'`)\n4. Push to the branch (`git push origin feature\u002FAmazingFeature`)\n5. Open a Pull Request\n\n## 📄 License\n\nThis project is open source and available under the [MIT License](LICENSE).\n\n## 🙏 Acknowledgments\n\n- [Decodo](https:\u002F\u002Fvisit.decodo.com\u002FoNza7b) for powerful web scraping API\n- [Insforge](https:\u002F\u002Finsforge.dev) for AI infrastructure\n- [Next.js](https:\u002F\u002Fnextjs.org) team for the amazing framework\n\n---\n\n**Built with ❤️ using Next.js, TypeScript, and AI**\n\n`POST \u002Fapi\u002Fanalyze`\n\nRequest body:\n\n```json\n{\n\t\"subreddit\": \"saas\"\n}\n```\n\nResponse shape:\n\n```json\n{\n\t\"subreddit\": \"saas\",\n\t\"source\": {\n\t\t\"subreddit\": \"saas\",\n\t\t\"scrapedAt\": \"2026-04-13T00:00:00.000Z\",\n\t\t\"posts\": [\n\t\t\t{\n\t\t\t\t\"title\": \"...\",\n\t\t\t\t\"comments\": [\"...\", \"...\"],\n\t\t\t\t\"permalink\": \"\u002Fr\u002Fsaas\u002Fcomments\u002F...\"\n\t\t\t}\n\t\t]\n\t},\n\t\"ideas\": [\n\t\t{\n\t\t\t\"idea_name\": \"...\",\n\t\t\t\"problem\": \"...\",\n\t\t\t\"demand_level\": \"High\",\n\t\t\t\"existing_solutions\": [\"...\"],\n\t\t\t\"user_complaints\": [\"...\"],\n\t\t\t\"opportunity\": \"...\",\n\t\t\t\"score\": 8,\n\t\t\t\"verdict\": \"Strong\"\n\t\t}\n\t]\n}\n```\n\n## Notes\n\n- The Decodo integration is intentionally resilient and tries multiple auth and payload conventions because Decodo account setups can differ.\n- Optional Insforge persistence is disabled unless `INSFORGE_RESULTS_TABLE` is set and the target table already exists.\n- The route validates both request input and AI output before returning data to the UI.\n","Validly 是一个用于从Reddit讨论中挖掘潜在SaaS商业机会的Next.js应用程序。它通过智能抓取任何子版块的每周热门帖子和评论，并利用Insforge AI分析技术来识别真实的SaaS商机、市场缺口及用户痛点。此外，Validly还提供了市场机会评分功能，帮助评估每个想法的市场可行性和紧迫性；同时，提取目标客户、定价洞察以及竞争对手信息以支持决策。该应用采用TypeScript编写，确保了代码的安全性与高效执行，且界面美观响应式设计得益于Tailwind CSS的支持。适用于初创公司或产品团队寻找新的业务增长点时使用。",2,"2026-06-11 03:32:04","CREATED_QUERY"]