{"id":45421690,"url":"https://github.com/acarlson33/firepit","last_synced_at":"2026-04-11T21:49:07.576Z","repository":{"id":323949562,"uuid":"1074442899","full_name":"acarlson33/firepit","owner":"acarlson33","description":"Realtime chat app, powered by appwrite. Easy to setup and deploy. Open source discord alternative","archived":false,"fork":false,"pushed_at":"2026-03-07T23:55:13.000Z","size":2262,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":0,"default_branch":"main","last_synced_at":"2026-03-08T04:51:45.488Z","etag":null,"topics":["appwrite","appwrite-auth","appwrite-database","appwrite-realtime","appwrite-sites","appwrite-storage","bun","chat-application","chatapp","chatapplication","chatroom","discord-clone","nextjs","partial-pre","react","reactjs","server-side-rendering","typescript"],"latest_commit_sha":null,"homepage":"","language":"TypeScript","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":"gpl-3.0","status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/acarlson33.png","metadata":{"files":{"readme":"README.md","changelog":"CHANGELOG.md","contributing":"CONTRIBUTING.md","funding":null,"license":"LICENSE","code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":"ROADMAP.md","authors":null,"dei":null,"publiccode":null,"codemeta":null,"zenodo":null,"notice":null,"maintainers":null,"copyright":null,"agents":null,"dco":null,"cla":null}},"created_at":"2025-10-11T19:53:53.000Z","updated_at":"2026-03-07T23:54:37.000Z","dependencies_parsed_at":null,"dependency_job_id":null,"html_url":"https://github.com/acarlson33/firepit","commit_stats":null,"previous_names":["acarlson33/firepit"],"tags_count":21,"template":false,"template_full_name":null,"purl":"pkg:github/acarlson33/firepit","repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acarlson33%2Ffirepit","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acarlson33%2Ffirepit/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acarlson33%2Ffirepit/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acarlson33%2Ffirepit/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/acarlson33","download_url":"https://codeload.github.com/acarlson33/firepit/tar.gz/refs/heads/main","sbom_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/acarlson33%2Ffirepit/sbom","scorecard":null,"host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":286080680,"owners_count":30348853,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2026-03-10T15:55:29.454Z","status":"ssl_error","status_checked_at":"2026-03-10T15:54:58.440Z","response_time":106,"last_error":"SSL_connect returned=1 errno=0 peeraddr=140.82.121.5:443 state=error: unexpected eof while reading","robots_txt_status":"success","robots_txt_updated_at":"2025-07-24T06:49:26.215Z","robots_txt_url":"https://github.com/robots.txt","online":false,"can_crawl_api":true,"host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["appwrite","appwrite-auth","appwrite-database","appwrite-realtime","appwrite-sites","appwrite-storage","bun","chat-application","chatapp","chatapplication","chatroom","discord-clone","nextjs","partial-pre","react","reactjs","server-side-rendering","typescript"],"created_at":"2026-02-22T01:36:08.820Z","updated_at":"2026-04-11T21:49:07.557Z","avatar_url":"https://github.com/acarlson33.png","language":"TypeScript","funding_links":[],"categories":[],"sub_categories":[],"readme":"# firepit\n\n\u003e **Version 1.7.0** - Production Ready\n\nA modern, open-source chat platform inspired by Discord, built with Next.js 16, Appwrite, and TypeScript. Firepit includes real-time messaging, servers and channels, direct messages, roles and moderation, social features, and a growing parity roadmap for Discord-like workflows.\n\n## Features\n\n- **Servers, channels, and categories** - Discord-style server organization with grouped text channels and in-app category management\n- **Direct messages and group DMs** - Private 1:1 and multi-user conversations\n- **Server invites and discovery** - Invite links, public server listings, and direct join flows\n- **Roles and permissions** - Per-server roles with channel overrides and moderation-aware access control\n- **Messaging parity basics** - Replies, mentions, reactions, threads, pins, search, typing indicators, and file attachments\n- **Profiles, presence, and social** - User profiles, statuses, friend requests, and blocking\n- **Notification controls parity** - Scoped notification levels, quiet hours, mute durations, DM privacy, and bulk override management\n- **Moderation and auditability** - Global and server moderation with audit log support\n- **User reporting** - Report users for inappropriate profile content with admin review dashboard\n- **Profile backgrounds and avatar frames** - Custom background colors, gradients, images, and seasonal/preset avatar frames\n- **Custom emoji support** - Standard emoji picker plus uploaded custom emoji assets\n\n## Codebase Features\n\n- **Real-time chat** - Appwrite-backed realtime messaging with typing indicators and presence updates\n- **Replies, mentions, reactions, threads, and pins** - Core message workflows across channels and DMs\n- **Direct messages and group DMs** - Shared DM infrastructure for 1:1 and multi-user conversations\n- **Search and attachments** - Message search plus image, file, video, audio, and document attachments\n- **Roles, permissions, categories, and moderation** - Server roles, permission overrides, category management, invite management, bans, kicks, mutes, and audit logs\n- **User reporting and admin review** - End-user reporting plus admin triage flows in `src/components/report-user-dialog.tsx`, `src/lib/appwrite-reports.ts`, and `src/app/admin/reports/page.tsx`\n- **Profiles and status** - User profile enrichment, avatars, pronouns, bios, and custom status messages\n- **Profile backgrounds and avatar frames** - Appearance customization in `src/components/profile-appearance-settings.tsx`, rendering support in `src/components/profile-background.tsx`, and preset frame definitions in `src/lib/preset-frames.ts`\n- **Friend system and blocking** - Social graph controls for safer private messaging\n- **Notification settings and mute controls** - Consistent override behavior across servers, channels, and DMs with server-enriched labels and quiet hours\n- **TypeScript** - Full type safety across the entire codebase\n- **Next.js 16** - App Router with React Server Components\n- **Tailwind CSS** - Modern, responsive UI styling\n- **shadcn/ui** - Accessible UI primitives\n- **PWA ready** - Installable web app support for mobile and desktop browsers\n- **Comprehensive tests** - 1913 passing tests with broad API, hook, and integration coverage\n- **Production hardening** - Error boundaries, rate limiting, security validation, and observability\n\n## 📋 Prerequisites\n\nBefore you begin, ensure you have:\n\n- **Node.js 18+** or **Bun 1.2+** (Bun 1.3+ preffered for perf. improvements) installed\n- An **Appwrite instance** (cloud or self-hosted):\n    - Cloud: [appwrite.io](https://appwrite.io) (free tier available)\n    - Self-hosted: [Installation Guide](https://appwrite.io/docs/installation)\n- **Git** for cloning the repository\n\n## 🚀 Quick Start\n\n```bash\n# 1. Clone the repository\ngit clone https://github.com/your-org/firepit.git\ncd firepit\n\n# 2. Install dependencies\nbun install\n\n# 3. Set up environment variables\ncp .env.local.example .env.local\nnano .env.local  # Edit with your Appwrite credentials\n\n# 4. Validate your configuration\nbun run validate-env\n\n# 5. Initialize the database\nbun run setup\n\n# 6. Start the development server\nbun dev  # Uses Turbopack (~700x faster than Webpack)\n```\n\nOpen [http://localhost:3000](http://localhost:3000) in your browser to see the application.\n\n**Development Commands:**\n\n- `bun dev` - Start with Turbopack (recommended, ~1.5s cold start)\n- `bun dev:webpack` - Start with Webpack (fallback, ~12s cold start)\n- `bun build` - Production build with Turbopack\n- `bun build:webpack` - Production build with Webpack (fallback)\n\n## 📚 Documentation\n\nSee the `/docs` folder for detailed guides:\n\n- [Deployment Guide](./DEPLOYMENT.md) - Production deployment instructions\n- [Documentation Index](./docs/README.md) - Durable product and platform documentation map\n- [Product And Onboarding](./docs/PRODUCT_AND_ONBOARDING.md) - Product shell, onboarding, discovery, and profile flows\n- [Chat And Realtime](./docs/CHAT_AND_REALTIME.md) - Messaging, DMs, pins, threads, search, emoji, typing, status, and notifications\n- [Server Administration](./docs/SERVER_ADMINISTRATION.md) - Roles, invites, permissions, moderation, and audit logging\n- [Feature Flags](./docs/FEATURE_FLAGS.md) - Flag behavior and rollout notes\n- [Telemetry Providers](./docs/TELEMETRY.md) - New Relic/PostHog routing, parity, and event mapping matrix\n- [Platform Operations](./docs/PLATFORM_OPERATIONS.md) - Performance, monitoring, releases, and operations\n- [Roadmap](./ROADMAP.md) - Discord parity roadmap and product priorities\n- [Roadmap Implementation Spec](./docs/ROADMAP_IMPLEMENTATION_SPEC.md) - Technical breakdown of roadmap workstreams\n- [Changelog](./CHANGELOG.md) - Version history and release notes\n\n## 🚀 Production Deployment\n\nFirepit is production-ready with:\n\n✅ **Security Hardening**\n\n- Global error boundaries\n- Rate limiting on uploads and API endpoints\n- Secure session management\n- Input validation and sanitization\n\n✅ **Performance Optimization**\n\n- **90%+ improvement in first load times** (from 30+ seconds to 2-3 seconds)\n- **85% faster First Contentful Paint** (8s → 0.8-1.2s)\n- **50% smaller bundle size** (2.5MB → 800KB-1.2MB)\n- Response compression (60-70% bandwidth reduction)\n- Virtual scrolling for large lists\n- Optimized bundle size with code splitting\n- Partial Prerendering (PPR) for instant page loads\n- Aggressive caching for repeat visits (~100ms)\n\n✅ **Monitoring \u0026 Observability**\n\n- New Relic APM integration\n- Comprehensive error tracking\n- Performance metrics\n- Audit logging\n\n✅ **Testing \u0026 Quality**\n\n- 1913 passing tests\n- Comprehensive test coverage\n- Automated CI/CD pipeline\n- Strict ESLint configuration\n\nSee [DEPLOYMENT.md](./DEPLOYMENT.md) for detailed production deployment instructions.\n\n## ⚠️ Known Limitations\n\nFirepit still has meaningful Discord parity gaps in a few areas:\n\n- Richer community/server organization beyond categories, such as server templates, onboarding screens, and announcement-style surfaces, is still in progress\n- Notification-center, unread-management, and digest-style attention flows are still incomplete\n- Voice/video calls and screen sharing are not implemented\n- Bots, slash commands, and webhooks are not implemented\n- Native mobile apps are not implemented, though PWA support exists\n\nSee [ROADMAP.md](./ROADMAP.md) for the complete feature roadmap.\n\n## 🤝 Contributing\n\nWe welcome contributions! See [CONTRIBUTING.md](./CONTRIBUTING.md) for:\n\n- Development workflow\n- Code style guidelines\n- Testing requirements\n- Pull request process\n- Issue reporting templates\n\n## 🗂️ Project Structure\n\n```\nfirepit/\n├── src/\n│   ├── app/              # Next.js app router pages\n│   ├── components/       # React components\n│   ├── lib/              # Utility functions and Appwrite integration\n│   └── __tests__/        # Vitest test suites\n├── scripts/\n│   ├── setup-appwrite.ts    # Database initialization script\n│   └── validate-env.ts      # Environment validation script\n├── public/               # Static assets\n├── DEPLOYMENT.md         # Deployment documentation\n└── .env.local.example    # Environment variable template\n```\n\n## 🛠️ Available Scripts\n\n| Command                 | Description                                  |\n| ----------------------- | -------------------------------------------- |\n| `bun dev`               | Start development server (with Turbopack)    |\n| `bun build`             | Build for production                         |\n| `bun start`             | Start production server                      |\n| `bun run test`          | Run all tests with Vitest                    |\n| `bun run test:coverage` | Run tests with coverage report               |\n| `bun lint`              | Check code with ESLint                       |\n| `bun lint:fix`          | Fix auto-fixable linting issues              |\n| `bun validate-env`      | Validate environment configuration           |\n| `bun setup`             | Initialize Appwrite database and collections |\n\n## 🔧 Configuration\n\n### Environment Variables\n\nThe application requires several environment variables. Copy `.env.local.example` to `.env.local` and configure:\n\n- `APPWRITE_ENDPOINT` - Your Appwrite API endpoint\n- `APPWRITE_PROJECT_ID` - Your Appwrite project ID\n- `APPWRITE_API_KEY` - Server-side API key with full permissions\n\nFor a complete list and detailed explanations, see [DEPLOYMENT.md](./DEPLOYMENT.md#2-environment-configuration).\n\n### First-Time Setup\n\n1. **Create an Appwrite account and project** at [appwrite.io](https://appwrite.io)\n2. **Generate an API key** with required scopes (see DEPLOYMENT.md)\n3. **Configure environment variables** in `.env.local`\n4. **Run validation**: `bun run validate-env`\n5. **Initialize database**: `bun run setup`\n6. **Start the app**: `bun dev`\n7. **Create your account** in the UI\n8. **Make yourself admin** by setting `APPWRITE_ADMIN_USER_IDS` in `.env.local`\n\nFor detailed instructions, see [DEPLOYMENT.md](./DEPLOYMENT.md).\n\n## 🐛 Troubleshooting\n\n### Common Issues\n\n- **\"Appwrite endpoint not configured\"** - Check your `.env.local` file exists and has the correct values\n- **\"Project not found\"** - Verify your `APPWRITE_PROJECT_ID` matches your Appwrite Console\n- **\"Missing scope\" errors** - Regenerate your API key with all required permissions\n- **Setup script fails** - Ensure your API key has databases, collections, attributes, and indexes permissions\n- **Setup script reports an attribute limit on `notification_settings`** - Update to the latest code and rerun `bun run setup`; unread persistence now uses a dedicated `thread_reads` collection instead of adding another notification-settings attribute\n\nFor more solutions, see [DEPLOYMENT.md - Troubleshooting](./DEPLOYMENT.md#troubleshooting).\n\n## 🧪 Testing\n\nThis project maintains a comprehensive test suite with 100% pass rate:\n\n```bash\n# Run all tests\nbun run test\n\n# Run tests with coverage report\nbun run test:coverage\n\n# Run tests in watch mode (during development)\nbun run test --watch\n```\n\nCurrent test coverage: **40.18%** statements (growing)\n\n- 1913 tests passing across 157 test suites\n- Comprehensive API route testing (44 new tests for invite system)\n- Focus on security-critical modules (auth, roles, moderation), and modules critical for function (API routes, hooks, utility files, etc.)\n\n## 📦 Deployment\n\n### Vercel (Recommended)\n\n1. Push your code to GitHub\n2. Import project in [Vercel](https://vercel.com)\n3. Add environment variables from `.env.local`\n4. Deploy!\n\n### Self-Hosted\n\n```bash\n# Build the application\nbun build\n\n# Start production server\nbun start\n```\n\nFor production deployment with Nginx, Docker, or other platforms, see [DEPLOYMENT.md - Production Deployment](./DEPLOYMENT.md#production-deployment).\n\n## 🤝 Contributing\n\nWe welcome contributions! Please see [CONTRIBUTING.md](./CONTRIBUTING.md) for:\n\n- Development workflow\n- Code style guidelines\n- Testing requirements\n- Pull request process\n- Issue reporting templates\n\n## 📄 License\n\nfirepit, a realtime chat app\nCopyright (C) 2026 August (acarlson33)\n\nThis program is free software: you can redistribute it and/or modify\nit under the terms of the GNU General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or\n(at your option) any later version.\n\nThis program is distributed in the hope that it will be useful,\nbut WITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the\nGNU General Public License for more details.\n\nYou should have received a copy of the GNU General Public License\nalong with this program. If not, see \u003chttps://www.gnu.org/licenses/\u003e.\n\nLicensed under the GNU General Public License (GPL) v3.\nYou can find the License here: [License](./LICENSE)\n\n## 🙏 Acknowledgments\n\nBuilt with:\n\n- [Next.js](https://nextjs.org/)\n- [Appwrite](https://appwrite.io/)\n- [TailwindCSS](https://tailwindcss.com/)\n- [shadcn/ui](https://ui.shadcn.com/)\n- [Vitest](https://vitest.dev/)\n\n## 📧 Support\n\n- **Documentation**: [DEPLOYMENT.md](./DEPLOYMENT.md)\n- **Issues**: [GitHub Issues](https://github.com/your-org/firepit/issues)\n- **Discussions**: [GitHub Discussions](https://github.com/your-org/firepit/discussions)\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Facarlson33%2Ffirepit","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Facarlson33%2Ffirepit","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Facarlson33%2Ffirepit/lists"}