Open-source, self-hosted push notification service built with Nuxt 4 & Nitro.
Self-hosted push notification service built with Nuxt 4 & Nitro
Take control of your push notifications with an open-source, developer-friendly platform
|
undefinedπ Multi-Platformundefined
|
undefinedποΈ Modern Stackundefined
|
undefinedπ Self-Hostedundefined
|
|
undefinedπ Analyticsundefined
|
undefinedπ‘οΈ Secureundefined
|
undefinedπ³ DevOps Readyundefined
|
undefinedTake control of your push notifications with an open-source, developer-friendly platformundefined
NitroPing is built with a modern, scalable architecture:
graph TB
Client[Client Apps] --> API[GraphQL API]
API --> Auth[JWT Auth]
API --> DB[(PostgreSQL)]
API --> Providers[Push Providers]
Providers --> APNs[Apple APNs]
Providers --> FCM[Firebase FCM]
Providers --> WebPush[Web Push]
DB --> Apps[Apps]
DB --> Devices[Devices]
DB --> Notifications[Notifications]
DB --> Logs[Delivery Logs]
undefinedCopy environment fileundefined
cp .env.example .env
undefinedGenerate required secretsundefined
undefinedJWT Secret (for API authentication):
# Option 1: Using Node.js
node -e "console.log(require('crypto').randomBytes(64).toString('hex'))"
# Option 2: Using OpenSSL
openssl rand -hex 64
# Option 3: Using online generator
# Visit: https://generate-secret.vercel.app/64
undefinedWebhook Secret (for delivery callbacks):
# Option 1: Using Node.js
node -e "console.log(require('crypto').randomBytes(32).toString('hex'))"
# Option 2: Using OpenSSL
openssl rand -hex 32
undefinedSet up databaseundefined
# Start PostgreSQL (using Docker)
docker run --name nitroping-db -e POSTGRES_PASSWORD=postgres -e POSTGRES_DB=nitroping -p 5432:5432 -d postgres:18
# Generate and run migrations
bun run db:generate
bun run db:migrate
undefinedStart development serverundefined
bun run dev --host # Allows access from mobile devices on same network
If you prefer Docker, you can run NitroPing in a containerized environment. Make sure to set up the .env file with the necessary secrets and database connection details.
If running Docker compose for the first time, migration is needed. Run the docker compose with migrate profile to set up the database schema.
docker compose up --profile migrate --profile dev -d
For subsequent runs, you can use the dev profile to start the application without migrating again.
docker compose up --profile dev -d
For production deployments, you can use the prod profile to run the application in production mode.
docker compose up --profile prod -d
Pull the latest image from Docker Hub:
# Pull latest version
docker pull productdevbook/nitroping:latest
# Or specific version
docker pull productdevbook/nitroping:v0.0.1
undefinedUsing with docker-compose.yaml:undefined
services:
server:
image: productdevbook/nitroping:latest
environment:
DATABASE_URL: postgres://user:password@db:5432/nitroping
ports:
- "3000:3000"
undefinedCreate an app via GraphQLundefined
mutation CreateApp {
createApp(input: {
name: "My App"
slug: "my-app"
description: "My awesome app"
}) {
id
apiKey
}
}
undefinedConfigure push providers through the dashboard at http://localhost:3000
undefinedRegister a deviceundefined
mutation RegisterDevice {
registerDevice(input: {
appId: "your-app-id"
token: "device-token"
platform: IOS
}) {
id
}
}
undefinedSend your first notificationundefined
mutation SendNotification {
sendNotification(input: {
appId: "your-app-id"
title: "Hello World!"
body: "Your first push notification"
targetDevices: ["device-id"]
}) {
id
status
}
}
|
π iOS Swift Package Native iOS integration |
π€ Android Kotlin SDK Native Android support |
βοΈ React Native Coming Soon Cross-platform mobile |
π― Flutter Coming Soon Google's framework |
import NitroPingClient
// Configure in AppDelegate
NitroPingClient.configure(
appId: "your-app-id",
apiKey: "your-api-key",
baseURL: "https://your-nitroping-instance.com"
)
// Register for push notifications
NitroPingClient.shared.registerForPushNotifications()
# Development
bun run dev --host # Start dev server (accessible from mobile devices)
bun run typecheck # Type checking
bun run lint # Run linter
# Database
bun run db:generate # Generate migrations
bun run db:migrate # Run migrations
bun run db:studio # Open Drizzle Studio
# Testing
bun run test # Run tests
bun run test:ui # Test with UI
We welcome all contributions! Whether youβre fixing bugs, adding features, or improving documentation.
|
undefinedπ Found a Bug?undefined
|
undefinedπ‘ Have an idea?undefined
|
undefinedπ§βπ» Want to code?undefined
|
# Clone and setup
git clone https://github.com/productdevbook/nitroping.git
cd nitroping
bun install
# Setup environment
cp .env.example .env
# Edit .env with your configuration
# Setup database
docker run -d --name nitroping-db \
-e POSTGRES_PASSWORD=postgres \
-e POSTGRES_DB=nitroping \
-p 5432:5432 postgres:18
bun run db:generate && bun run db:migrate
# Start development
bun run dev --host
undefinedSDKs & Integrationsundefined
undefinedPlatform Featuresundefined
MIT Licensed - see the LICENSE file for details.
Built with β€οΈ by the open source community
π Visit Website β’ β Star us on GitHub β’ π¬ Join the discussion
Take control of your push notifications today!
We use cookies
We use cookies to analyze traffic and improve your experience. You can accept or reject analytics cookies.