{"id":18029057,"url":"https://github.com/abdulrahmanaymann/imdbclone-restfulapi","last_synced_at":"2026-04-19T14:32:10.462Z","repository":{"id":260161791,"uuid":"873281273","full_name":"abdulrahmanaymann/IMDBClone-RESTfulAPI","owner":"abdulrahmanaymann","description":"IMDB Clone RESTful API.","archived":false,"fork":false,"pushed_at":"2024-10-30T11:36:11.000Z","size":2618,"stargazers_count":0,"open_issues_count":0,"forks_count":0,"subscribers_count":1,"default_branch":"master","last_synced_at":"2024-12-18T00:42:24.947Z","etag":null,"topics":["asp-net-core","asp-net-core-web-api","auto-mapper","caching","csharp","dotnet","dtos","ef-core","filtering","identity","jwt-authentication","n-tier-architecture","pagination","refresh-token","repository-pattern","restful-api","sql-server","swagger","tmdb-api","unit-of-work-pattern"],"latest_commit_sha":null,"homepage":"","language":"C#","has_issues":true,"has_wiki":null,"has_pages":null,"mirror_url":null,"source_name":null,"license":null,"status":null,"scm":"git","pull_requests_enabled":true,"icon_url":"https://github.com/abdulrahmanaymann.png","metadata":{"files":{"readme":"README.md","changelog":null,"contributing":null,"funding":null,"license":null,"code_of_conduct":null,"threat_model":null,"audit":null,"citation":null,"codeowners":null,"security":null,"support":null,"governance":null,"roadmap":null,"authors":null,"dei":null,"publiccode":null,"codemeta":null}},"created_at":"2024-10-15T22:43:57.000Z","updated_at":"2024-10-30T11:36:15.000Z","dependencies_parsed_at":"2024-12-18T00:41:32.784Z","dependency_job_id":"554f93b6-3959-4f0a-b3a9-d15c12f74fef","html_url":"https://github.com/abdulrahmanaymann/IMDBClone-RESTfulAPI","commit_stats":{"total_commits":30,"total_committers":1,"mean_commits":30.0,"dds":0.0,"last_synced_commit":"f3393d3c0957fc9e8d5e0ac6283182be01f9f03e"},"previous_names":["abdulrahmanaymann/imdbclone-restfulapi"],"tags_count":0,"template":false,"template_full_name":null,"repository_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abdulrahmanaymann%2FIMDBClone-RESTfulAPI","tags_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abdulrahmanaymann%2FIMDBClone-RESTfulAPI/tags","releases_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abdulrahmanaymann%2FIMDBClone-RESTfulAPI/releases","manifests_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories/abdulrahmanaymann%2FIMDBClone-RESTfulAPI/manifests","owner_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners/abdulrahmanaymann","download_url":"https://codeload.github.com/abdulrahmanaymann/IMDBClone-RESTfulAPI/tar.gz/refs/heads/master","host":{"name":"GitHub","url":"https://github.com","kind":"github","repositories_count":238061221,"owners_count":19410065,"icon_url":"https://github.com/github.png","version":null,"created_at":"2022-05-30T11:31:42.601Z","updated_at":"2022-07-04T15:15:14.044Z","host_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub","repositories_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repositories","repository_names_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/repository_names","owners_url":"https://repos.ecosyste.ms/api/v1/hosts/GitHub/owners"}},"keywords":["asp-net-core","asp-net-core-web-api","auto-mapper","caching","csharp","dotnet","dtos","ef-core","filtering","identity","jwt-authentication","n-tier-architecture","pagination","refresh-token","repository-pattern","restful-api","sql-server","swagger","tmdb-api","unit-of-work-pattern"],"created_at":"2024-10-30T09:07:35.923Z","updated_at":"2026-04-19T14:32:10.425Z","avatar_url":"https://github.com/abdulrahmanaymann.png","language":"C#","funding_links":[],"categories":[],"sub_categories":[],"readme":"![Logo](https://i.imgur.com/srymhmQ.png)\n\n# 🎬 IMDBClone RESTful API\n\n## 📝 Description\n\nThe **IMDBClone RESTful API** is a backend application that replicates key features of IMDb, managing movie-related data, user authentication, ratings, reviews, and watchlists. It supports secure authentication and role-based access controls, allowing for flexible management of users and interactions.\n\n---\n\n## 🚀 Technologies\n\n- **Programming Language**: C#\n- **Framework**: ASP.NET Core\n- **Database**: SQL Server\n- **ORM**: Entity Framework Core\n- **Authentication**: JWT (JSON Web Tokens)\n- **Caching**: IMemoryCache\n- **Web Scraping**: Python\n- **External API**: TMDB API\n\n---\n\n## 🌐 Data Integration\n\n- **Web Scraping**: Uses Python scripts to gather additional movie data from external sources, enhancing the database with up-to-date information.\n- **TMDB API**: Integrates with The Movie Database (TMDB) API for real-time movie data fetching, ensuring users always have access to the latest information.\n\n---\n\n## 🏗 Architecture\n\nThe API follows a layered architecture that promotes modularity and separation of concerns, utilizing Unit of Work and Repository patterns for efficient data handling.\n\n- **Business Layer**: Contains services and mapping profiles for business logic and DTO mappings.\n- **Common Layer**: Stores constants, enums, settings, and utility classes.\n- **Core Layer**: Defines data models, DTOs, and validation attributes.\n- **Data Access Layer**: Manages database operations with Repository and Unit of Work patterns.\n- **Web API Layer**: Exposes RESTful endpoints to handle client interactions.\n\n---\n\n## 📂 Backend Structure\n\n### **Project Modules**\n\n- **IMDbClone.Business**\n  - **Services**: Interfaces and implementations for application functionalities like authentication, caching, and data management.\n  - **Mapper**: Configures mappings between DTOs and models.\n  \n- **IMDbClone.Common**\n  - **Constants**: Defines roles, HTTP status codes, and cache keys.\n  - **Settings**: Manages configurations for caching and other settings.\n  \n- **IMDbClone.Core**\n  - **DTOs**: Data transfer objects for movies, users, ratings, reviews, and watchlists.\n  - **Models**: Entity models defining the application's data structure.\n  - **Utilities**: Provides pagination, expression handling, and validation.\n  \n- **IMDbClone.DataAccess**\n  - **Repository**: Implements data operations using Unit of Work for transactional integrity.\n  \n- **IMDbClone.WebAPI**\n  - **Controllers**: Exposes API endpoints to handle requests and responses.\n\n---\n\n## 🎮 Controllers Overview\n\n\n### 1. **AuthController** 🔒\nHandles user authentication and profile management operations.\n\n| Endpoint                  | Method | Description                                | Auth Required |\n|---------------------------|--------|--------------------------------------------|---------------|\n| `/api/auth/register`      | POST   | Register a new user                        | ❌            |\n| `/api/auth/login`         | POST   | Login and receive JWT tokens               | ❌            |\n| `/api/auth/refresh-token` | POST   | Refresh access tokens                      | ✅            |\n| `/api/auth/profile`       | GET    | Retrieve profile of the logged-in user     | ✅            |\n| `/api/auth/profile`       | PUT    | Update profile of the logged-in user       | ✅            |\n\n### 2. **MovieController** 🎬\nManages movie data, including addition, retrieval, updating, and deletion.\n\n| Endpoint                | Method | Description                                         |\n|-------------------------|--------|-----------------------------------------------------|\n| `/api/movies`           | GET    | Retrieve all movies with optional filters           |\n| `/api/movies/{id}`      | GET    | Retrieve details for a specific movie               |\n| `/api/movies`           | POST   | Add a new movie to the database                     |\n| `/api/movies/{id}`      | PUT    | Update existing movie details                       |\n| `/api/movies/{id}`      | DELETE | Remove a movie from the database                    |\n\n### 3. **RatingController** ⭐\nControls movie ratings, allowing users to add, view, update, and delete ratings.\n\n| Endpoint                | Method | Description                            |\n|-------------------------|--------|----------------------------------------|\n| `/api/ratings`          | GET    | Retrieve all ratings                   |\n| `/api/ratings/{id}`     | GET    | Retrieve a specific rating             |\n| `/api/ratings`          | POST   | Submit a new rating                    |\n| `/api/ratings/{id}`     | PUT    | Update an existing rating              |\n| `/api/ratings/{id}`     | DELETE | Delete a rating                        |\n\n### 4. **ReviewController** 📝\nManages user reviews for movies, including retrieval, creation, updating, and deletion.\n\n| Endpoint                | Method | Description                                         |\n|-------------------------|--------|-----------------------------------------------------|\n| `/api/review`           | GET    | Retrieve all reviews                                |\n| `/api/review/{id}`      | GET    | Retrieve a specific review                          |\n| `/api/review`           | POST   | Create a new review                                 |\n| `/api/review/{id}`      | PUT    | Update an existing review                           |\n| `/api/review/{id}`      | DELETE | Delete a review                                     |\n\n### 5. **WatchlistController** 🎥\nHandles watchlists for users, allowing them to manage their movie collections.\n\n| Endpoint                | Method | Description                                         |\n|-------------------------|--------|-----------------------------------------------------|\n| `/api/watchlist`        | GET    | Retrieve all movies in the user’s watchlist         |\n| `/api/watchlist/{id}`   | GET    | Retrieve details of a specific movie in watchlist   |\n| `/api/watchlist`        | POST   | Add a movie to the user’s watchlist                 |\n| `/api/watchlist/{id}`   | DELETE | Remove a movie from the user’s watchlist            |\n\n### 6. **UserController** 👤  \nManages user profiles, roles, and administrative account operations.\n\n| Endpoint                     | Method | Description                                    | Auth Required |\n|------------------------------|--------|------------------------------------------------|---------------|\n| `/api/users`                 | GET    | Retrieve all registered users with filtering   | ✅ |\n| `/api/users/{userId}`        | GET    | Retrieve a specific user profile by ID         | ✅ |\n| `/api/users/{userId}`        | DELETE | Delete a specific user from the system         | ✅ |\n| `/api/users/{userId}/roles`  | GET    | Retrieve roles assigned to a specific user     | ✅ |\n| `/api/users/{userId}/roles`  | POST   | Assign a role to a specific user               | ✅ |\n| `/api/users/{userId}/roles`  | PUT    | Update roles assigned to a specific user       | ✅ |\n| `/api/users/{userId}/roles`  | DELETE | Remove a role from a specific user             | ✅ |\n| `/api/users/roles`           | GET    | Retrieve all available roles                   | ✅ |\n\n---\n\n## 📁 Project Structure\n\n```\nIMDbClone\n│\n├── IMDbClone.Business\n│   ├── Mapper\n│   │   └── MappingProfile.cs\n│   ├── Services\n│   │   ├── IServices\n│   │   │   └── IUserService.cs       \n│   │   ├── auth\n│   │   ├── cache\n│   │   ├── movie\n│   │   ├── rating\n│   │   ├── review\n│   │   ├── watchlist\n│   │   └── token\n│   │   └── user                     \n│   │       └── UserService.cs       \n│\n├── IMDbClone.Common\n│   ├── Constants\n│   │   ├── Roles.cs\n│   │   ├── HttpStatusCodes.cs\n│   │   └── CacheKeys.cs\n│   └── Settings\n│       └── CacheSettings.cs\n│\n├── IMDbClone.Core\n│   ├── DTOs\n│   │   ├── AuthDTOs\n│   │   │   ├── LoginRequestDTO.cs\n│   │   │   ├── LoginResponseDTO.cs\n│   │   │   ├── RefreshTokenRequestDTO.cs\n│   │   │   └── RegistrationRequestDTO.cs\n│   │   ├── MovieDTOs\n│   │   │   ├── CreateMovieDTO.cs\n│   │   │   ├── MovieDTO.cs\n│   │   │   ├── MovieSummaryDTO.cs\n│   │   │   └── UpdateMovieDTO.cs\n│   │   ├── RatingDTOs\n│   │   │   ├── CreateRatingDTO.cs\n│   │   │   ├── RatingDTO.cs\n│   │   │   └── UpdateRatingDTO.cs\n│   │   ├── ReviewDTOs\n│   │   │   ├── CreateReviewDTO.cs\n│   │   │   ├── ReviewDTO.cs\n│   │   │   └── UpdateReviewDTO.cs\n│   │   ├── UserDTOs\n│   │   │   ├── UserDTO.cs\n│   │   │   └── UserProfileDTO.cs\n│   │   └── WatchlistDTOs\n│   │       ├── CreateWatchlistDTO.cs\n│   │       └── WatchlistDTO.cs\n│   ├── Enums\n│   │   └── Genre.cs\n│   ├── Exceptions\n│   │   └── ApiException.cs\n│   ├── Models\n│   │   ├── ApplicationUser.cs\n│   │   ├── Movie.cs\n│   │   ├── Rating.cs\n│   │   ├── Review.cs\n│   │   └── Watchlist.cs\n│   ├── Responses\n│   │   └── APIResponse.cs\n│   ├── Utilities\n│   │   ├── PaginatedResult.cs\n│   │   └── ExpressionUtilities.cs\n│   └── Validation\n│       ├── FullNameAttribute.cs\n│       └── ValidCastAttribute.cs\n│\n├── IMDbClone.DataAccess\n│   ├── Data\n│   │   └── ApplicationDbContext.cs\n│   ├── DbInitializer\n│   │   └── DBInitializer.cs\n│   ├── Migrations\n│   └── Repository\n│       ├── IRepository\n│       ├── WatchlistRepository.cs\n│       ├── UserRepository.cs\n│       ├── UnitOfWork.cs\n│       ├── ReviewRepository.cs\n│       ├── Repository.cs\n│       ├── RatingRepository.cs\n│       └── MovieRepository.cs\n│\n├── IMDbClone.WebAPI\n│   ├── Controllers\n│   │   ├── AuthController.cs\n│   │   ├── MovieController.cs\n│   │   ├── RatingController.cs\n│   │   ├── ReviewController.cs\n│   │   ├── UserController.cs             \n│   │   └── WatchlistController.cs\n│   ├── Program.cs\n│   └── appsettings.json\n```\n---\n\n## 📌 Getting Started\n\n1. Clone the repository.\n   ```bash\n   git clone https://github.com/yourusername/IMDbClone-API.git\n   ```\n2. Install dependencies and set up the database.\n3. Configure environment variables for database connection, JWT, TMDB API keys, and any other required settings.\n4. Run the application using your preferred IDE or command line.\n\n---\n","project_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabdulrahmanaymann%2Fimdbclone-restfulapi","html_url":"https://awesome.ecosyste.ms/projects/github.com%2Fabdulrahmanaymann%2Fimdbclone-restfulapi","lists_url":"https://awesome.ecosyste.ms/api/v1/projects/github.com%2Fabdulrahmanaymann%2Fimdbclone-restfulapi/lists"}