Overview
Spark is a unique platform that allows fans to support creators with their time instead of money. By engaging with ads and completing surveys, fans can earn Sparks and use them to gift to specific creators, transforming passive attention into active engagement.
We made a new Impact Point system called Sparks that can be earned by:
- Watching ads
- Completing User surveys
Fans can direct these Sparks to creators to show support without spending money. Spark utilises the attention economy to create a new value flow pathway from consumer to creator.
- Support with time: No money required
- Earn levels and titles: Unlocks rewards for supporting creators
- Recognition in community: Badges and emojis for dedicated fans
- Better recommendations Your feedback matters to improving TikTok
- New revenue stream driven by the value of time—your fans’ attention.
- Reinvest Sparks into growing your reach: Boost your content, grow your followers.
- Small creators can use Sparks to increase visibility and accelerate discovery.
- Big creators can either cash out or reinvest for further growth.
- Fan loyalty strengthened through supporter tiers and visible recognition.
- New monetization layer that doesn’t increase user spend.
- Better creator retention with a fairer reward system.
- Rich insights from surveys and ad targeting data.
- A stronger ecosystem where fans, creators, and advertisers are more connected.
- Daily cap on ads/surveys.
- 1-week minimum account age before earning.
- At least 1K followers to unlock the creator dashboard.
- Server-verified ad completions (no client spoofing).
- Bot and self-farming monitoring via IP and device hashing
- Node.js + Express API for backend services.
- Postgres 16 (Dockerized) as the database.
- Prisma ORM for schema definition and migrations.
- User: Different roles (FAN, CREATOR, ADMIN), device-linked, and has a trust score.
- Wallet: Tracks Spark balance for each user.
- Transaction: Logs various actions (EARN_AD, SURVEY, GIFT, BOOST, CASHOUT).
- AdSession: Details of the ad session (brand, token, duration, heartbeat, status).
- Survey + SurveyAnswer: Definitions of surveys and user responses.
- EventLog: A transparent audit trail of all user actions.
- POST /register: Register a new user.
- POST /login: Login using email and password.
- POST /dev-login: Dev login using deviceId.
- GET /whoami: Retrieve current user details.
- GET /balance: Get the user's Spark balance.
- POST /gift: Gift Sparks to a creator.
- POST /boost: Boost a video using Sparks.
- POST /cashout: Cash out Sparks.
- POST /start: Start an ad session.
- POST /heartbeat: Send a heartbeat for the ad session.
- POST /complete: Complete the ad session and earn Sparks.
- GET /: List all active surveys.
- POST /complete: Complete a survey and earn Sparks (with cap checks).
- GET /: Query the personal event log.
- GET /me/stats: Retrieve creator statistics (gifts, boosts).
- GET /: List all active surveys.
- POST /complete: Complete a survey and earn Sparks (with cap checks).
- GET /: Query the personal event log.
- GET /me/stats: Retrieve creator statistics (gifts, boosts).
- Caps: Limits on daily ad and weekly survey participation to prevent abuse.
- Gates: Account age gate (7 days configurable) to prevent early abuse.
- Anti-abuse: JWT authentication, rate-limiting, and a trust score to ensure fair usage.
- AML (Anti-Money Laundering): Sparks can only flow outward (earned → gifted → boosted/cashed), eliminating inbound cash and preventing laundering risks.
- Transparency: Each user has an Event Log and Transaction History for full transparency.
- seed.js: Provisioning tool that creates a demo creator and sets up survey definitions.
- Dev Login: Supports login via deviceId, backdating creation to simulate testing scenarios.
/bin/bash -c "$(curl -fsSL https://raw.githubusercontent.com/Homebrew/install/HEAD/install.sh)"brew update
brew install git
brew install nvmmkdir -p ~/.nvm
cat <<'EOF' >> ~/.zshrc
export NVM_DIR="$HOME/.nvm"
[ -s "/opt/homebrew/opt/nvm/nvm.sh" ] && . "/opt/homebrew/opt/nvm/nvm.sh"
[ -s "/opt/homebrew/opt/nvm/etc/bash_completion.d/nvm" ] && . "/opt/homebrew/opt/nvm/etc/bash_completion.d/nvm"
EOF
source ~/.nvm install --lts
node -v
npm -vbrew install --cask docker
open -a Dockerdocker --version
docker compose versionnpm i -g expo-cli
expo --versionnpm i -D prisma
npx prisma --versioncd spark-backenddocker compose up -dnpx prisma db push
npm run seed # if your repo provides a seed scriptnpm run devnpm installcd mobilenpx expo startThis project was made for TikTok TechJam 2025 by acacia tembusu dining hall
Members:
- Chloe Chua
- Chew Wei Jie
- Cheong Kang Jie
- Kenneth Lee
- Yap Han Keat
This project is licensed under the MIT License.
For setup, usage, and product details, please refer to the full documentation above. Let me know if you need additional information or modifications!