This project scaffolds a TypeScript React frontend using Vite and Visx, as well as a TypeScript Express backend that implements Yahoo OAuth and proxies Yahoo Fantasy API calls.
IP-Based (No Domain Required):
- 📄 Follow DEPLOYMENT_STEPS.md
- Uses
docker-compose.ip.ymlwith self-signed SSL - Perfect for personal home server deployment
Domain-Based (Custom Domain):
- 📄 Follow HOME_SERVER_DEPLOYMENT.md
- Uses
docker-compose.ymlwith Let's Encrypt SSL - Includes automatic certificate renewal
Not sure which to use? See DOCKER_COMPOSE_FILES.md for a detailed comparison.
See DEPLOYMENT.md for Render.com deployment (not recommended due to performance issues).
To use Yahoo OAuth, you first need to register an application:
- Go to the Yahoo Developer Network.
- Click on 'Create an App'.
- Fill in the required fields, including:
- Name of the Application
- Application URL (can be a placeholder for local development)
- Callback Domain (set this to your local development URL, e.g., http://localhost:3000)
- After creating the app, you will receive a
client_idandclient_secret. Keep these safe.
Create a .env file in the server directory with the following variables:
YAHOO_CLIENT_ID=your_client_id_here
YAHOO_CLIENT_SECRET=your_client_secret_here
BASE_URL=http://localhost:5000
FRONTEND_URL=http://localhost:3000
SESSION_SECRET=random_session_secret
PORT=5000
- Clone the repository and navigate to the project directory.
- Install dependencies for both client and server:
npm install cd client npm install cd ../server npm install
- Start the server:
npm run dev
- Open a new terminal for the client:
cd client npm run dev - Visit
http://localhost:3000to view the application.
- Implement OAuth by clicking the Connect Yahoo button in the app.
- To test OAuth locally without a Yahoo app, you can stub tokens in memory or a JSON file until your app is set up.
Enjoy building your Fantasy Viz app!