Skip to content

FanFlux helps content creators to reward fans, have an extra income via tokenomics, while fans get access to exclusive content and can sell assets to others.

Notifications You must be signed in to change notification settings

wugalde19/fanflux

Folders and files

NameName
Last commit message
Last commit date

Latest commit

Β 

History

44 Commits
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 
Β 

Repository files navigation

🌟 FanFlux

A decentralized platform for fan engagement and creator monetization on Starknet

Features β€’ Quick Start β€’ Architecture β€’ Development β€’ Contributing β€’ Use Cases

πŸ“– Overview

🎯 FanFlux is an innovative decentralized application (dapp) built on the Starknet blockchain that revolutionizes the way creators and fans interact. It provides a seamless platform for creators to monetize their content and engage with their community while giving fans unique ways to support and connect with their favorite creators.

Why FanFlux?

  • Decentralized Control: No central authority controlling content or revenue
  • Lower Fees: Significantly reduced platform fees compared to traditional platforms
  • True Ownership: Creators maintain full ownership of their content
  • Transparent Economics: All transactions and fee structures are public and immutable
  • Global Access: Available to creators and fans worldwide without traditional banking restrictions

βš™οΈ Built using NextJS, Starknet.js, Scarb, Starknet-React, and Starknet Foundry.

🎯 Key Features

🎨 Creator Features

Profile Management

  • Customizable profiles for creators to showcase their content
  • Portfolio management and content organization
  • Analytics dashboard for tracking engagement and earnings
  • Customizable monetization strategies
  • Content scheduling and automation
  • Multi-platform content synchronization
  • Custom branding options
  • SEO optimization tools

Revenue Streams

  • Direct fan subscriptions
  • Pay-per-view content
  • Virtual merchandise sales
  • Exclusive content access
  • Tokenized membership tiers
  • Automated revenue splitting
  • Sponsorship management
  • Cross-platform monetization

πŸ’« Fan Engagement Features

Community Interaction

  • Interactive features for fans to support creators
  • Token-gated content access
  • Exclusive community spaces
  • Direct messaging between fans and creators
  • Tipping and subscription systems
  • Community polls and voting
  • Fan challenges and rewards
  • Social features and sharing

Rewards System

  • Loyalty points program
  • Achievement badges
  • Exclusive access tokens
  • Referral rewards
  • Community rankings
  • Special event privileges
  • Early access opportunities
  • Custom fan experiences

πŸ” Security Features

Transaction Security

  • Built on Starknet for fast, secure, and scalable transactions
  • Multi-signature wallet support
  • Automated payment distributions
  • Transparent fee structure
  • Fraud prevention systems
  • Dispute resolution mechanism
  • Regular security audits
  • Insurance coverage options

Data Protection

  • End-to-end encryption
  • Privacy-focused design
  • GDPR compliance
  • Data portability
  • Regular backups
  • Access control systems
  • Activity monitoring
  • Security notifications

🌐 Technical Integration

Web3 Features

  • Seamless connection with various wallet providers
  • Cross-chain compatibility (planned)
  • NFT support for exclusive content
  • Token-based governance system
  • Smart contract automation
  • Layer 2 scaling solutions
  • Cross-chain bridges
  • DeFi integrations

API Integration

  • RESTful API
  • GraphQL support
  • Webhook system
  • SDK availability
  • Documentation portal
  • Rate limiting
  • Cache optimization
  • Error handling

πŸ— Architecture

FanFlux is built on a modern, scalable architecture designed for performance and reliability:

Frontend Architecture

  • Next.js 13+ with App Router
  • TailwindCSS for styling
  • Framer Motion for animations
  • TypeScript for type safety
  • Starknet React for blockchain interactions
  • Redux for state management
  • Service Workers for offline support
  • WebSocket for real-time updates

Smart Contract Architecture

  • Cairo smart contracts
  • Starknet blockchain
  • Decentralized storage integration
  • Automated market makers for token swaps
  • Upgradeable contracts
  • Multi-signature governance
  • Event emission system
  • Gas optimization

Backend Services

  • Decentralized content delivery
  • IPFS integration for content storage
  • Real-time notification system
  • Analytics and reporting
  • Load balancing
  • Caching layers
  • Database sharding
  • Microservices architecture

Infrastructure

  • Docker containerization
  • Kubernetes orchestration
  • CI/CD pipelines
  • Automated testing
  • Performance monitoring
  • Error tracking
  • Logging system
  • Backup solutions

πŸ“‹ Requirements

Before you begin, you need to install the following tools:

πŸš€ Development Setup

1. Install Developer Tools

You can set up the development environment in two ways:

Option 1: Native Installation

  1. Install Starkup:
curl --proto '=https' --tlsv1.2 -sSf https://sh.starkup.sh | sh
  1. Clone and set up the project:
git clone  https://github.com/wugalde19/fanflux.git
cd fanflux
yarn install
  1. Install Starknet Devnet:
asdf plugin add starknet-devnet
asdf install

Option 2: Using Dev Containers

  1. Install Docker Desktop
  2. Install VS Code Dev Containers extension
  3. Clone the repository and open in VS Code
  4. Click "Reopen in Container" when prompted

2. Environment Configuration

  1. Copy the example environment files:
cp packages/nextjs/.env.example packages/nextjs/.env
cp packages/snfoundry/.env.example packages/snfoundry/.env
  1. Configure environment variables:

Frontend Environment Variables

NEXT_PUBLIC_CHAIN_ID=
NEXT_PUBLIC_PROVIDER_URL=
NEXT_PUBLIC_IPFS_GATEWAY=
NEXT_PUBLIC_API_URL=

Smart Contract Environment Variables

STARKNET_ACCOUNT=
STARKNET_PRIVATE_KEY=
STARKNET_NETWORK=

API Environment Variables

DATABASE_URL=
REDIS_URL=
JWT_SECRET=

3. Development Workflow

  1. Start the local Starknet network:
yarn chain
  1. Deploy the contracts:
yarn deploy
  1. Start the frontend application:
yarn start

Visit http://localhost:3000 to see the application running.

πŸ§ͺ Testing

FanFlux includes comprehensive testing at all levels:

Smart Contract Testing

# Run all tests
yarn test

# Run specific test file
yarn test:file path/to/test

# Run with coverage
yarn test:coverage

Frontend Testing

# Run all tests
yarn test:nextjs

# Run with watch mode
yarn test:nextjs:watch

# Run with coverage
yarn test:nextjs:coverage

Integration Testing

# Run all integration tests
yarn test:integration

# Run specific suite
yarn test:integration:suite

# Generate test reports
yarn test:report

Performance Testing

# Run lighthouse tests
yarn test:lighthouse

# Run load tests
yarn test:load

πŸ“¦ Deployment

Testnet Deployment

  1. Configure testnet environment:
cp .env.testnet .env
  1. Deploy contracts:
yarn deploy --network sepolia
  1. Deploy frontend:
yarn deploy:frontend

Mainnet Deployment

  1. Configure mainnet environment:
cp .env.mainnet .env
  1. Deploy contracts:
yarn deploy --network mainnet
  1. Deploy frontend:
yarn deploy:frontend:prod

πŸ”’ Security

  • All smart contracts are thoroughly audited

Code Style

  • Follow the project's ESLint configuration
  • Write meaningful commit messages
  • Include tests for new features
  • Update documentation as needed
  • Follow the PR template

πŸ’‘ Use Cases

For Content Creators

  • Musicians releasing exclusive tracks
  • Artists selling digital artwork
  • Writers publishing premium content
  • Streamers offering exclusive streams
  • Educators providing online courses
  • Podcasters sharing bonus episodes
  • Photographers selling photo collections
  • Filmmakers distributing indie films

For Fans

  • Access to exclusive content
  • Direct interaction with creators
  • Community participation
  • Early access to new releases
  • Special event access
  • Merchandise purchases
  • Custom experiences
  • Community governance

🌐 Network Support

Current Networks

  • Starknet Mainnet
  • Starknet Testnet (Sepolia)
  • Local Development Network

Planned Networks

  • Layer 2 Solutions
  • Cross-chain Bridges
  • Alternative L1s

πŸ†˜ Support

If you need help:

Smart Contracts Information:

MyToken Contract (Sepolia)

Contract Address: 0x544f567c2c2ec661faac3e7b568e9fce495eaefd9fc85a1ffabfea883a1f20c Class Hash: 0x016b914f5a73ee4e52879cace7de586abf56e0c745c0cc7275d7773eaaa59b2f

Factory Contract (Sepolia)

Contract Address: 0x7df922fa83125ff77060e079d7210464b3a483096d8108af3153965e8510cd8 Class Hash: 0x03b33627577b841e07b3ad604ca5c0243ee64456544243428f87b67f26abefc3

About

FanFlux helps content creators to reward fans, have an extra income via tokenomics, while fans get access to exclusive content and can sell assets to others.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Contributors 5

Languages