ASP.NET Core Integration

Complete guide for integrating EasyMessages with ASP.NET Core web applications.


In This Section


Quick Start

1. Install the Package

dotnet add package RecurPixel.EasyMessages --version 1.0.0

2. Use in Controllers

No DI registration is needed. Use the package directly in your controllers:

[HttpPost]
public IActionResult Create(CreateUserDto dto)
{
    var user = _userService.Create(dto);
    var msg = Msg.Crud.Created("User").WithData(user);
    return StatusCode(msg.HttpStatusCode ?? 200, msg.ToJsonObject());
}

Get started with the Overview guide!


Table of contents