Project Name: Backend Development for YouTube and Twitter
Description:
This project involves the development of a robust backend for a YouTube-like platform, combined with Twitter-inspired features for enhanced user interaction. Key functionalities include:
- User registration, authentication, and management.
- Video management: upload, view, like, comment, and subscribe functionalities.
- Social interactions: commenting, liking, and channel subscriptions.
- Tweet management: create, update, delete, and like tweets.
- Media upload and storage integration using Cloudinary.
- MongoDB serves as the database to manage all application data and relationships.
The project structure and functionality ensure scalability, modularity, and maintainability for future enhancements.
- Registration, login, and logout with JWT-based authentication.
- Password reset functionality.
- Profile management including avatar, cover image, and user details.
- Watch history tracking for videos.
- Upload and publish videos with metadata (title, description, etc.).
- Search, sort, and paginate video content.
- Edit and delete videos.
- Control video visibility (publish/unpublish).
- Create and publish tweets.
- View user tweets.
- Update and delete tweets.
- Subscribe to user channels.
- View subscriber and subscribed channel lists.
- Create, update, and delete playlists.
- Add and remove videos from playlists.
- View user playlists.
- Like and unlike videos, comments, and tweets.
- View all liked videos.
- Add, update, and delete comments on videos.
- View channel statistics such as views, subscribers, videos, and likes.
- Access uploaded videos.
- Endpoint to verify the backend's health status.
The project uses MongoDB as the database, designed to handle relationships between entities such as users, videos, comments, likes, subscriptions, and tweets.
Detailed API documentation has been created using Postman. It outlines all endpoints, request formats, and responses.
Ensure the following are installed on your system:
- Node.js (v14+)
- MongoDB
- npm
- Clone the Repository:
git clone https://github.com/Shravan9393/Youtube-Backend-Including-Twitter.git
2 Navigate to the Project Directory:
cd <project_directory>
3 Set Up Environment Variables: Create a .env file in the root directory and add the following variables:
-PORT =
-MONGODB_URI =
-ACCESS_TOKEN_SECRET =
-ACCESS_TOKEN_EXPIRY =
-REFRESH_TOKEN_SECRET=
-REFRESH_TOKEN_EXPIRY
-CLOUDINARY_CLOUD_NAME =
-CLOUDINARY_API_KEY =
-CLOUDINARY_API_SECRET
-CLOUDINARY_URL
4 Run the Application
npm run dev