Skip to content

A simple script to read GoFundMe and Chuffed URLs from a Supabase database and scrape info about them.

Notifications You must be signed in to change notification settings

Sneethan/sunbird_scanner

Repository files navigation

Sunbird Scanner

What does this do?

Sunbird Scanner is a custom built tool to scrape GoFundMe campaigns using Puppeteer, and then reports campaign stats to a Supabase table.

Features

  • Uses a loader script to support multiple tables
  • Loads links directly from tables, using Supabase API
  • Performant and fast
  • Cross-platform
  • Supports both Chuffed and GoFundMe

Getting Started

This guide will walk you through the steps needed to set up the project. No prior experience is necessary—just follow the instructions below!


Prerequisites

You'll need the following installed on your computer:

  • Git: A tool to clone and manage the project code.
  • Node.js: A platform for running JavaScript code.
  • Supabase Account: A backend-as-a-service platform where you'll set up your database.

Step 1: Install Git

Git is a tool that helps you download and manage the project code.

  1. Visit git-scm.com.
  2. Download the version for your operating system.
  3. Run the installer and follow the default setup options.
  4. After installation, open a terminal and type git --version to confirm Git is installed.

Step 2: Install Bun

Bun is a fast all-in-one JavaScript runtime and toolkit.

  1. Visit bun.sh
  2. Install Bun using the following command:
    # For Windows (PowerShell):
    powershell -c "irm bun.sh/install.ps1|iex"
    
    # For macOS or Linux:
    curl -fsSL https://bun.sh/install | bash
  3. After installation, open a terminal and type bun --version to confirm installation.

Step 3: Clone the Project Repository

  1. Open a terminal or command prompt.
  2. Navigate to the folder where you'd like to store the project:
    cd path/to/your/folder
  3. Run the following command to clone the project:
    git clone https://github.com/Sneethan/sunbird_scanner
  4. Navigate into the project folder:
    cd sunbird_scanner

Step 4: Install Dependencies

The project dependencies are managed by Bun.

  1. In the project folder, run:
    bun install
    This will download and set up everything needed.

Step 5: Set Up a Supabase Database

Supabase is a service that provides a database and API for your project.

  1. Go to supabase.com and sign up for a free account.
  2. Create a new project:
    • Enter a project name.
    • Choose a database region close to you.
    • Set a database password (keep this safe!).
  3. Once the project is created, go to the "Table Editor" tab.
  4. Create a new table with the following schema:
Column Name Data Type Default Constraints
id int4 auto Primary Key
title text
link text
currency text
target int4
raised int4
donations int4
updated_at timestampz now() Automatically Updated
  1. Save the table.

Step 6: Get Your Supabase API Keys

  1. In your Supabase dashboard, go to Settings > API.
  2. Copy the Project URL and Anon Key.
  3. Leave this page open, and paste the values into your terminal when requested. run.js will ask for them automatically.

You're Ready to Go!

Now, you have everything set up. Run your project using:

bun run.js

Or use the provided batch script:

run.bat

Acknowledgements

Disclaimers

This code may break at any time if GoFundMe updates their site, and may have bugs and instablities. If you find bugs and know how to fix them, pull requests are very much appreciated.

Happy coding! 🎉

About

A simple script to read GoFundMe and Chuffed URLs from a Supabase database and scrape info about them.

Topics

Resources

Stars

Watchers

Forks

Releases

No releases published

Contributors 3

  •  
  •  
  •