TeenFiAllowance

TeenFiAllowance POC

Overview

TeenFiAllowance is a proof-of-concept (POC) decentralized application (dApp) that enables parents to manage weekly allowances for teens using blockchain technology. Built on the Sepolia testnet, it supports two ERC-20 tokens: a custom TST token and PayPal USD (PYUSD). Parents can configure allowances, set spending caps, and transfer tokens, while teens can spend their allowance within approved categories (e.g., Education, Entertainment). For testing, spent tokens are transferred back to the parent.

This repository contains simplified code without demo-specific styling (e.g., Bootstrap) used in the live demo at www.skytiger.tech/TeenFiAllowance/, which includes a styled interface for presentation purposes.

This project was developed for the MetaMask Delegation Toolkit (DTK) Dev Cook-Off, showcasing blockchain-based financial education for teens, with a user-friendly interface. The live demo is non-working, as the Infura API key has been removed for security reasons. To run the dApp, users must provide their own Infura API key and set up SSL locally, as the frontend requires SSL (HTTPS) to run locally due to MetaMask Flask’s security requirements.

Features

Tech Stack

Frontend

Blockchain

Deployment

Contract Details

TeenFiAllowance Contract

TST Token (Custom ERC‑20)

PYUSD Token (PayPal USD)

Setup Instructions

Prerequisites

Installation

  1. Clone the repository:
    git clone https://github.com/your-repo/TeenFiAllowance.git
    cd TeenFiAllowance
  2. Install dependencies:
    npm install lite-server --save-dev
  3. Set up Infura API key and update RPC URLs.
  4. Generate SSL certificates using mkcert.
  5. Configure lite-server with bs-config.js.
  6. Deploy contracts if needed.
  7. Run the frontend:
    npx lite-server --config=bs-config.js

Usage

  1. Visit https://localhost:3000
  2. Configure parent–teen relationship.
  3. Select token page (TST or PYUSD).
  4. Parent configures allowance and transfers tokens.
  5. Teen views balance and spends allowance.
  6. Verify transactions on Etherscan.

Testing

Contributing

  1. Fork the repository.
  2. Create a feature branch.
  3. Commit and push changes.
  4. Open a pull request.

License

MIT License. See LICENSE for details.

Contact