Skip to content

tanmayyenpure/BloodSync

Repository files navigation

🩸 BloodSync

Intelligent Blood Bank Data Automation Platform

Real-Time Blood Data β€’ Automated Collection β€’ Google Sheets Integration β€’ Smart Healthcare Automation

Node.js Playwright Google Sheets JavaScript MIT


Automating Blood Bank Data for Smarter Healthcare Decisions

Reliable Automation β€’ Structured Data β€’ Real-World Impact


πŸ“– Overview

BloodSync is an Intelligent Blood Bank Data Automation Platform designed to automate the collection, processing, and synchronization of real-time blood availability data from the eRaktKosh portal.

Built using Node.js, Playwright, and Google Sheets API, the platform eliminates repetitive manual data collection by transforming unstructured web information into organized, reliable, and continuously updated datasets.

Developed in collaboration with Love Care Share Foundation, BloodSync demonstrates how intelligent automation can improve operational efficiency, increase data accessibility, and support healthcare initiatives through modern software engineering.


🎯 Problem Statement

Blood banks continuously update inventory information, making manual data collection inefficient, repetitive, and prone to human error.

Organizations and volunteers require accurate and timely blood availability information to make informed decisions and improve operational workflows.

BloodSync addresses these challenges by creating an automated pipeline that collects, structures, validates, and synchronizes blood inventory data with minimal human intervention.


✨ Key Features

🩸 Automated Blood Data Collection

  • Intelligent multi-page web scraping
  • Automatic pagination handling
  • Structured data extraction
  • Reliable information processing

πŸ“Š Real-Time Blood Inventory

  • Blood group availability tracking
  • Blood component monitoring
  • Live inventory synchronization
  • Timestamp-based data freshness

πŸ”„ Google Sheets Integration

  • OAuth 2.0 authentication
  • Automatic spreadsheet synchronization
  • Centralized data management
  • Cloud-based accessibility

⚑ Smart Automation

  • Scheduled execution
  • Daily automated updates
  • Minimal manual intervention
  • Reliable data pipeline

πŸ—οΈ Scalable Architecture

  • Modular automation workflow
  • Configurable deployment
  • Easy maintenance
  • Extensible project structure

πŸ—οΈ System Architecture

                     eRaktKosh Portal

                             β”‚

                             β–Ό

                  Playwright Automation Engine

                             β”‚

                     Intelligent Data Extraction

                             β”‚

                             β–Ό

                   Data Processing & Validation

                             β”‚

                             β–Ό

                  Google Sheets API Integration

                             β”‚

                             β–Ό

                    Structured Healthcare Data

                             β”‚

                             β–Ό

                 Love Care Share Foundation

πŸ› οΈ Technology Stack

Category Technology
Runtime Environment Node.js
Automation Framework Playwright
Programming Language JavaScript
Data Integration Google Sheets API
Authentication OAuth 2.0
Environment Management dotenv
Scheduling Windows Task Scheduler
Version Control Git & GitHub

πŸ“Š Project Statistics

Property Details
Project Type Data Automation Platform
Domain Healthcare
Architecture Automation Pipeline
Data Source eRaktKosh Portal
Integration Google Sheets API
Automation Playwright
License MIT
Status Active Development

πŸ“‚ Project Structure

BloodSync/

β”œβ”€β”€ auth_setup.js
β”œβ”€β”€ scraper.js
β”œβ”€β”€ run_scraper.bat
β”œβ”€β”€ package.json
β”œβ”€β”€ package-lock.json
β”œβ”€β”€ credentials.json          # User Generated
β”œβ”€β”€ token.json                # Auto Generated
β”œβ”€β”€ .env                      # User Configuration
β”œβ”€β”€ .gitignore
β”œβ”€β”€ README.md
└── LICENSE

πŸš€ Getting Started

Clone Repository

git clone https://github.com/tanmayyenpure/BloodSync.git
cd BloodSync

βš™οΈ Installation

Install project dependencies.

npm install

Install Playwright Chromium browser.

npx playwright install chromium

πŸ” Configuration

Create a .env file in the project root and configure the following variables.

STATE=Your State
DISTRICT=Your District
GOOGLE_SHEET_ID=Your Google Sheet ID

Place your Google Cloud API credentials file in the project root.

credentials.json

πŸ”‘ Authentication

Run the authentication setup once to authorize Google Sheets access.

node auth_setup.js

A browser window will open requesting Google account authorization.

After successful authentication, a token.json file will be generated automatically.


▢️ Running the Automation

Start the data automation pipeline.

node scraper.js

The application will:

  • Connect to the eRaktKosh portal
  • Extract blood availability information
  • Process and validate collected data
  • Synchronize records with Google Sheets
  • Generate updated timestamps

βš™οΈ Automation Workflow

The project is designed for unattended execution.

Execute the following file manually:

run_scraper.bat

or configure it with Windows Task Scheduler for fully automated daily synchronization.


πŸ”„ Data Pipeline

eRaktKosh Portal

        β”‚

        β–Ό

Playwright Browser Automation

        β”‚

        β–Ό

Multi-Page Data Extraction

        β”‚

        β–Ό

Data Processing & Validation

        β”‚

        β–Ό

Google Sheets Synchronization

        β”‚

        β–Ό

Updated Blood Availability Records

🀝 Collaboration

BloodSync was developed as a real-world automation initiative in collaboration with Love Care Share Foundation.

The project demonstrates how intelligent automation can reduce repetitive manual processes, improve healthcare data accessibility, and provide reliable information through structured and continuously synchronized datasets.


🌟 Why BloodSync?

BloodSync is more than a web scraper.

It is an automation platform designed to transform repetitive healthcare data collection into a reliable, scalable, and intelligent workflow.

Key Benefits

  • Real-Time Blood Availability Monitoring
  • Automated Multi-Page Data Collection
  • Centralized Google Sheets Integration
  • Reliable & Structured Healthcare Data
  • Minimal Manual Intervention
  • Scalable Automation Pipeline

πŸ“ˆ Future Roadmap

BloodSync is designed as a scalable healthcare automation platform with a vision of transforming blood inventory management through intelligent automation and modern data engineering.

πŸš€ Automation Enhancements

  • Intelligent Retry Mechanism
  • Automatic Error Recovery
  • Advanced Data Validation
  • Smart Duplicate Detection

πŸ“Š Analytics & Reporting

  • Blood Availability Dashboard
  • Historical Data Analysis
  • Automated Report Generation
  • Interactive Data Visualization

☁️ Cloud Integration

  • Cloud Database Support
  • Multi-State Data Synchronization
  • REST API Integration
  • Real-Time Notifications

πŸ€– AI-Powered Features

  • Blood Demand Prediction
  • Smart Inventory Forecasting
  • AI-Based Data Insights
  • Intelligent Healthcare Analytics

🎯 Real-World Impact

BloodSync demonstrates how automation can simplify repetitive healthcare workflows by transforming manual data collection into an intelligent and reliable process.

By integrating browser automation, structured data processing, and cloud synchronization, the platform improves operational efficiency while ensuring timely access to critical blood availability information.


🀝 Contributing

Contributions, ideas, and improvements are always welcome.

1. Fork the Repository

Create your own copy of the project.

2. Create a Feature Branch

git checkout -b feature/new-feature

3. Commit Your Changes

git commit -m "feat: add new feature"

4. Push Your Branch

git push origin feature/new-feature

5. Open a Pull Request

Submit your changes for review and help improve BloodSync.


πŸ“œ License

This project is licensed under the MIT License.

You are free to use, modify, and distribute this project in accordance with the license terms.


πŸ‘¨β€πŸ’» Developer

Tanmay Yenpure

AI/ML Engineer


πŸ”— GitHub

https://github.com/tanmayyenpure


⭐ Support the Project

If you found BloodSync useful or interesting, consider giving this repository a Star ⭐ on GitHub.

Your support encourages continuous improvements and future open-source contributions.


🩸 BloodSync

Intelligent Blood Bank Data Automation Platform

Building reliable healthcare automation through modern software engineering.

Engineered by Tanmay Yenpure

About

BloodSync : Intelligent Blood Bank Data Automation Platform is an automated web scraping pipeline for the eRaktKosh portal designed to extract Real-time blood stock data and sync it with Google Sheets.

Topics

Resources

License

Stars

Watchers

Forks

Contributors