
design and implement a multi-layer .NET Core 3.1 web API from scratch, covering data, business, and presentation layers, with authentication and security integration.
Install and update Visual Studio 2019 community, and install .NET Core 3.1. Download and run MongoDB community server, then start MongoDB and verify connectivity to the web API.
To continue this course, you need net core knowledge, mvc concepts, and c sharp object-oriented fundamentals, establishing the foundation for the n-tier architecture with a net core 3.1 web api.
Explore how web api centralizes business logic and serves any client—from mobile to web—using rest full api, open source json transport, and language flexibility like C# or Java.
Create a solution for a music app using n-tier architecture with a .NET Core 3.1 web API backend and MVC frontend. Define API, core, services, and data layers with tests.
Download the project.zip to explore the n-tier architecture within the .NET Core 3.1 web api course. Access the project to view its contents.
Explore n-tier architecture by creating models and classes, defining a repository interface, and understanding the repository pattern within the core, api, and business layers.
Create the two models, class music and class artist, with properties like id, name, and artistId, and establish a musics collection for each artist using a constructor and system collection.
Learn to centralize data operations with the repository pattern and unit of work in an n-tier .NET core web api, creating reusable music and artist interfaces and persistence-agnostic data access.
Explore interface services that connect the Web API to data through the business layer, defining music and artist service interfaces and their operations.
Download the project.zip now to Dr. C. The caption indicates you can download the project for this course.
This introduction covers setting up a .NET Core 3.1 web api project with n-tier architecture, including DbContext, repositories, and dependency injection for configuration and database creation.
Learn to configure the SQL Server data layer with EF Core, map tables to C# objects, and set up Mongo DP connections using NuGet packages for tooling and secret management.
Configure entity type mappings for music and artist, defining identity keys, required names (max 50), and a one-to-many relation linking music to artist with table names music and artist.
Create the DbContext by defining DbSet properties for music and artist tables, implement its constructor and OnModelCreating to apply music and artist configurations, and prepare for dependency injection.
Implement music and artist repositories using the repository pattern and unit of work, inject the DbContext, and implement add, remove, and find operations with get all and get by id.
Apply dependency injection in a .NET Core 3.1 web API by configuring startup services, setting a database connection string, and outlining transient, scoped, and singleton lifetimes.
Create the database by adding a migration for the my music api project, define artist and music tables with foreign keys, and initialize and verify the database on the server.
Initialize the database by creating the initial schema, seeding artist and music data, and validating seeded records via the API and data view steps, with MongoDB for the next section.
Download the project.zip to Dr. C, making the project ready for study within this course.
Explore setting up the data access layer, integrating MongoDB, adding necessary packages, creating the repository, and configuring dependency injection during startup for an n-tier .NET Core Web API.
Explore MongoDB, an open-source document database that supports cross-platform deployment, high performance, and the core concepts of databases, collections, and documents.
Update the data layer core by adding a composite entity with an object id, installing MongoDB, and creating the ICompositeRepository and ICompositeService with create, get by id, and delete methods.
Install the MongoDB driver and configure a settings class with connection and database. Define a public database settings interface for the composer collection and inject the MongoDB client.
Integrate MongoDB dependency injection in the startup of a .NET Core 3.1 web api by configuring the connection string, database name, and a repository for per request data operations.
Add the composer repository in the Mongo project and implement create, read, update, and delete operations on the composers collection, and integrate it with the MyMusic API.
Download the project zip for the n-tier architecture .NET Core 3.1 Web API course, enabling Dr. C to access the project and explore the web API structure.
Discover how the api uses the business layer to connect to the data layer in an n-tier .net core 3.1 web api, with mongodb and domain music and artist.
Create the layer services in a .NET Core 3.1 web api. Implement music, artist, and composer services using a unit-of-work and repository pattern, wired via dependency injection.
Download the project.zip to access the NET Core 3.1 Web API files for the n-tier architecture course. Share the project with Dr. C for review.
Create and expose the API layer with a RESTful interface that enables stateless, uniform client–server communication for resources using get, post, put, and delete.
Explore how to add swagger to a .NET Core 3.1 Web API, configure services in startup, and run on localhost to view the swagger in the browser.
Create music, artist, and composer api controllers in a .NET Core 3.1 web api project, after deleting the default controller and scaffolding empty controllers.
Create the GetAllMusic method by injecting the music service into the constructor and returning all music with artist data.
Explore using AutoMapper in a .NET Core 3.1 web API to map domain models to music resources, configure a mapping profile, and inject IMapper in the controller.
Create the api for getting music by id in an n-tier .net core 3.1 web api, implement the music repository and service, and return music details or not found responses.
Create music via post in a .NET Core 3.1 web api, validate save music data (name nonempty, max 50, id nonempty, artist required), map to the domain model, and persist.
Implement the update music API by validating input, retrieving music by id, and applying updates via the service layer, with proper error handling for not found and bad request.
This lecture demonstrates creating the API delete music method in a .NET Core 3.1 Web API, handling delete by id, checking for music existence, and returning the appropriate response.
Develop a net core 3.1 web api endpoint to get all music by a specific artist id, inject the artist service, map results, and verify by example artist id.
Create a GetAllArtist endpoint in a .NET Core 3.1 Web API by configuring the artist controller and wiring dependency injection; map artist data and test the endpoint.
Create the api endpoint get artist by id in a .NET Core 3.1 web api project, implement the GetArtistById method, map the result, and test with existing and missing artists.
Create the artist api flow in the n-tier .net core 3.1 web api by saving to the data source, mapping, and validating the artist name (not empty, max 50 characters).
Develop and test the update artist api in a .NET core 3.1 web api, validating input, saving the artist, retrieving by id, handling not found, and applying updates.
Delete the lead artist by id via the api, test the deletion, and confirm the lead artist is deleted from the project data.
Implement the get all composer API in the .NET core 3.1 web API by wiring dependency injection, defining the composer model and mapping, and connecting to Mongo DB.
Implement the application programming interface create composer method, validate first and last names (not empty, max 50), map the composer, and store in MongoDB; enable retrieval by id.
Learn to get a composer by ID in a .NET Core 3.1 web API using MongoDB, wire up the project, and return first name and last name.
Recap building the backend with a .NET Core 3.1 Web API, outlining layered data, resources, objects, and validation, and introducing authentication workflows.
Download the project.zip for the n-tier architecture .NET Core 3.1 Web API course, enabling you to download the project to Dr. C.
Explore authentication with JWT in a .NET Core Web API, detailing front-end and back-end interactions, token issuance, header transmission, and server-side validation.
Integrate JWT authentication by updating the core layer, adding identity models user and app settings, and defining a user repository and user service for authentication and CRUD operations.
Update data layer in n-tier .net core 3.1 web api by adding a user configuration with identity, first name, username, and last name, and implement repository and unit of work.
Update the data layer by adding a public service class, inject a unit of work, implement authentication and user management methods, and prepare the music api controller.
Set up a .NET Core 3.1 web API for user management by configuring JWT authentication, dependency injection, and a user service, then implement register, login, and CRUD operations.
Download the project.zip for the n-tier architecture .NET Core 3.1 Web API course to access the project for Dr. C.
Explore how mvc and web api enable a full stack, build the backend, and then craft the frontend to consume the different endpoints using asp.net mvc.
Create an ASP.NET Core MVC client project in .NET Core 3.1 to consume a backend Web API, linking the frontend MVC with the backend API in an N-tier architecture.
Configure the Web API address, fetch the music list from the backend, define music and artist classes, deserialize JSON with Newtonsoft.Json, and display music and artist in the index view.
Learn to add music to the database by building a music model and a post API call that serializes JSON and handles responses with artist data.
Display the list of composers by configuring an MVC flow with a composer model (first name, last name), a MongoDB database, a controller, and a view to render the index.
Implement and consume authentication in an ASP.NET Core MVC app for a Web API, setting up a login form and JWT token-based authentication via the account controller's Authenticate action.
create a new user registration flow in a .NET Core 3.1 web API by building a register view and account controller, validating input, and saving the user with authentication token.
Implement authorization for the API, validate tokens on the backend, include the token in request headers, and restrict adding new music to authorized users.
Add a new composer in an n-tier .NET Core 3.1 web API by building the UI form, validating first and last names, securing creation with authentication, and persisting to MongoDB.
Learn how to get the current user in a .NET Core 3.1 Web API using identity. Implement login checks, capture user IP, and ensure user context is available for processing.
Download the project.zip for the n-tier architecture .NET Core 3.1 Web API course and deliver it to Dr. C.
Hello every one,
I decided to create this course because I actually couldn’t find many courses explaining on how to separate your application in multiple layers with ASP.NET Core 3.1 Web API.
Here we are building a nice API with basic CRUD (Create, Read, Update, Delete) operations. It will be an API for an app that stores which musics you like with its artists.
I will show you how to:
· Create an application in separated projects to make it decoupled from each module.
· Implement Repository and Unit of Work pattern.
· Use Entity Framework Core for persistence with SQL server.
· Use MongoDB Database for NoSQL
· Add AutoMapper for mapping models into API resources.
· Add Swagger to have a friendly API interface.
· Integrate the Authentication & Authorization with JWT (JSON Web Token)
· Application Client with ASP.NET CORE MVC to consume the APIs
And on top of all these, you'll get:
Download the source code