Files
OneDriveGDrive/server/src/index.ts
MUIS1436 5fa3fb3d15 chore(config): add initial project configuration and setup files
- Add .env.example with Microsoft Azure AD and Google Cloud OAuth client ID placeholders
- Create .gitignore to exclude node_modules, build output, env files, IDE, OS, logs, and test coverage
- Add .prettierrc for consistent code formatting rules
- Add README.md with project overview, features, setup instructions, project structure, and technologies used
- Add components.json with UI framework and alias configuration
- Configure eslint.config.js for linting TypeScript and React code with recommended settings
- Add index.html as application entry point with root div and main script reference
- Add package-lock.json capturing full dependency tree and versions for reproducible installs
2026-01-31 08:59:18 +05:00

26 lines
578 B
TypeScript

import express from 'express';
import cors from 'cors';
import dotenv from 'dotenv';
import authRoutes from './routes/auth';
import transferRoutes from './routes/transfer';
dotenv.config();
const app = express();
const PORT = process.env.PORT || 3001;
app.use(cors());
app.use(express.json());
// Routes
app.use('/api/auth', authRoutes);
app.use('/api/transfer', transferRoutes);
app.get('/health', (req, res) => {
res.json({ status: 'ok', server: 'OneDrive-GoogleDrive-Streamer' });
});
app.listen(PORT, () => {
console.log(`Server running on port ${PORT}`);
});