BumpAlert is a mobile-first road hazard detection application that uses device motion sensors and GPS telemetry to identify bumps, potholes, and other road anomalies. It records the event location and impact data, presents the results on a map and telemetry dashboard, and creates shareable grievance cards for civic reporting.
- Detects road impacts from accelerometer and motion sensor data.
- Supports separate Bike and Car detection profiles.
- Uses GPS speed, location accuracy, and elevation changes to improve detection confidence.
- Continues detection through the native Android background detection service.
- Displays live acceleration, gyroscope, compass, GPS, speed, and elevation telemetry.
- Stores detected events locally for review and syncs user-scoped reports to the API.
- Adds secure login, registration, forgot password, and Google sign-in.
- Keeps anomaly records attached to the logged-in user and stores the payload in PostgreSQL.
- Shows detected hazards and nearby reports on Google Maps.
- Creates shareable anomaly cards with Google Street View imagery when available.
- Falls back to Google satellite imagery when Street View coverage is unavailable.
- Provides a Google Maps location link with each shared anomaly.
- Supports light and dark display modes.
- Includes a service worker and Cloudflare Pages deployment configuration.
The current hosted PWA is transitional. The planned release model is native Android and iOS apps that call the API directly. In the future, bumpalert.thepixelwriter.com will become a landing page linking to Google Play and the Apple App Store rather than hosting the app. Until that transition is complete, keep the existing web app and its API CORS origin available.
Client
- TypeScript
- Angular 20
- Ionic Angular 8
- Capacitor 8
- RxJS
- Google Maps JavaScript API
- Google Maps Static API
- Street View Static API
- Angular Service Worker
Native platforms
- Android
- iOS
- Capacitor Motion
- Capacitor Geolocation
- Capacitor Share
- Capacitor Status Bar
Deployment and tooling
- Cloudflare Pages and Wrangler
- Angular CLI
- ESLint
bumpAlert/
src/ Ionic Angular client source
android/ Capacitor Android project
ios/ Capacitor iOS project
public/ Static public assets
scripts/ Build and environment scripts
wrangler.jsonc Cloudflare deployment configuration
Install the following before starting development:
- Node.js 20 or newer
- npm
- Git
- Xcode and CocoaPods for iOS development
- Android Studio and a configured JDK for Android development
A Google Cloud project with billing enabled is required for Google Maps features.
git clone https://github.com/thepixelwriter/BumpAlert.git
cd BumpAlertCreate a .env file in the client repository root:
GOOGLE_MAPS_API_KEY=your_google_maps_api_key
GOOGLE_CLIENT_ID=your_google_oauth_client_idThe build script reads these values and generates the local runtime environment file. GOOGLE_CLIENT_ID is used by Google sign-in; configure the same OAuth client ID as the GOOGLE_CLIENT_ID secret for the API Worker so it can verify sign-in tokens. For GitHub Actions deployment, add GOOGLE_MAPS_API_KEY and GOOGLE_CLIENT_ID as repository Actions secrets. Do not commit .env or generated runtime credentials.
Enable the following Google Maps Platform APIs for the key:
- Maps JavaScript API
- Directions API
- Geocoding API
- Places API
- Places API (New)
- Telemetry API
- Maps Static API
- Street View Static API
Billing must be enabled. For browser builds, restrict the key to approved HTTP referrers. For native Capacitor builds, use an appropriate native application restriction or a separate key that is restricted according to the platform configuration. The Maps Static and Street View Static requests must also be allowed by the key restrictions.
cd BumpAlert
npm install
npm startThe local development app normally runs at http://localhost:4200.
The app now starts on the auth screen and redirects to the secured dashboard after successful login or registration.
To create a production build:
npm run buildTo run the client tests:
npm testTo run linting:
npm run lintAfter installing client dependencies, sync the web application with Capacitor:
cd BumpAlert
npm run build
npx cap syncOpen the native project in its platform IDE:
npx cap open android
npx cap open iosNative builds require the relevant platform SDK, signing configuration, and device permissions for motion and location access.
Contributions are welcome. Start by reviewing the open issues and existing discussions to understand current priorities.
All contributor work should be based on the
contributorsbranch, notmain. Fork the repository and create your feature or fix branch fromcontributors, then open a pull request targeting thecontributorsbranch.
- Fork the repository from the
contributorsbranch. - Clone your fork locally.
- Create a focused branch from
contributors. - Install the required app dependencies.
- Make the change and add or update tests where appropriate.
- Run the relevant build, test, and lint commands.
- Push your branch to your fork.
- Submit a pull request with a clear description of the change and its validation.
Please keep pull requests focused, avoid committing credentials or generated build output, and document any platform-specific setup requirements.
This project is licensed under the MIT License.