A full-stack application that provides user management capabilities with a C# (.NET 8) backend API and Angular frontend.
This application allows you to:
- View a list of users
- Add new users
- Edit existing users
- Delete users
- .NET 8
- ASP.NET Core Web API
- Entity Framework Core (In-Memory Database)
- C#
- Angular 19
- TypeScript
- .NET 8 SDK
- Node.js and npm (for Angular frontend)
- Angular CLI (
npm install -g @angular/cli)
-
Clone the repository
git clone https://github.com/yechielby/UserManagementApp.git
-
Navigate to the backend project directory
cd UserManagementApp -
Build and run the application
dotnet build dotnet run
-
The API will be accessible at:
- https://localhost:7148/api/Users (HTTPS)
- http://localhost:5148/api/Users (HTTP)
-
Swagger UI is available at:
- https://localhost:7148/swagger (HTTPS)
- http://localhost:5148/swagger (HTTP)
- Clone the repository
git clone https://github.com/yechielby/taxes.git
- Navigate to the Angular project directory
cd taxes - Install dependencies
npm install
- Start the Angular development server
ng serve
- The Angular application will be available at:
http://localhost:4200
| Method | Endpoint | Description |
|---|---|---|
| GET | /api/Users | Get all users |
| GET | /api/Users/{id} | Get user by ID |
| POST | /api/Users | Create a new user |
| PUT | /api/Users/{id} | Update an existing user |
| DELETE | /api/Users/{id} | Delete a user |
The User model includes:
- Id (int)
- Name (string, required)
- Username (string, required)
- Email (string, required, must be valid email)
- Phone (string, required)
- Website (string, required)
- Address (object, contains Street, Suite, City, Zipcode, and Geo coordinates)
- Company (object, contains Name, CatchPhrase, and Bs)
- Data Seeding: On first run, the application seeds user data from JSONPlaceholder's
/usersendpoint. - Validation: Includes validation for required fields (Name, Username, Email, Phone, Website) and email format.
- Error Handling: Comprehensive error handling and logging.
- CORS: Configured to allow requests from the Angular frontend running on localhost:4200.
- The application uses an in-memory database, so data will be reset when the application restarts.
- Initial data is seeded from the JSONPlaceholder API or from fallback data if the API call fails.