Created
June 12, 2020 05:34
-
-
Save smaglio81/3f15064012de7ebfcb45ff87772ea000 to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
using System.Threading.Tasks; | |
using Microsoft.AspNetCore.Mvc; | |
using Microsoft.Extensions.Logging; | |
namespace YourNamespace | |
{ | |
[ApiController] | |
[Route("[controller]")] | |
public class YourController : ControllerBase | |
{ | |
private readonly ILogger<YourController> _logger; | |
public PullRequestUpdatedController( | |
ILogger<YourController> logger | |
) | |
{ | |
_logger = logger; | |
} | |
[TrackRequestBody] | |
public async Task<IActionResult> PostAsync([FromBody] YourObjectModel model) | |
{ | |
// do stuff | |
return Ok(); | |
} | |
} | |
} |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment