This repository contains the backend server implementation for BrowsePing, an open-source real-time social presence platform that transforms web browsing into a shared social experience. The server handles user authentication, real-time WebSocket connections, friend management, messaging, analytics tracking, and leaderboard functionality.
git clone https://github.com/browseping/server.git
cd servernpm installStart MySQL:
docker run --name browseping-mysql -e MYSQL_ROOT_PASSWORD=yourpassword -e MYSQL_DATABASE=browseping -p 3306:3306 -d mysql:8Start Redis:
docker run --name browseping-redis -p 6379:6379 -d redisMake sure MySQL and Redis services are running on your system:
# Check MySQL status
mysql --version
sudo systemctl status mysql # Linux
brew services list | grep mysql # macOS
# Check Redis status
redis-cli ping # Should return PONG
sudo systemctl status redis # Linux
brew services list | grep redis # macOSCopy the example environment file:
cp .env.example .envEdit the .env file with your configuration.
Generate Prisma Client:
npm run prisma:generateRun database migrations:
npm run prisma:migratenpm run devThe server will start on http://localhost:3000 (or the port specified in your .env file).
npm run dev- Start development server with hot reload (using nodemon)npm run build- Compile TypeScript to JavaScriptnpm start- Run production server (requires build first)npm run prisma:generate- Generate Prisma Clientnpm run prisma:migrate- Run database migrations
-
Start the development server:
npm run dev
-
Make changes to the code in the
src/directory -
Test your changes using API clients like Postman or Thunder Client
-
Create database migrations when changing the schema:
npx prisma migrate dev --name your_migration_name
-
Follow our Contributing Guidelines when submitting changes
This project supports local development using Docker and Docker Compose.
Copy the environment file:
cp .env.example .env
Edit .env and set your credentials (except
DATABASE_URLandREDIS_URL— those are hardcoded in docker-compose.yml).
Start the application:
docker compose up --build
The server will be available at:
http://localhost:3000
We welcome contributions to the BrowsePing server! Whether it's fixing bugs, improving documentation, or adding new features, your help is appreciated.
Please read our Contributing Guidelines for details on how to get started.
Join our community on Discord to discuss ideas and collaborate with other contributors.
- Website: browseping.com
- Discord: Join our community
- Twitter/X: @BrowsePing
- LinkedIn: BrowsePing Company
- GitHub: github.com/browseping
- Browser Extension: browseping/browser-extension
- Website: browseping/web
- Contact Us: browseping.com/contact
- Email: support@browseping.com
This project is licensed under the MIT License - see the LICENSE file for details.
Thanks to all the wonderful people who have contributed to this project.