Finally, view the logs that were generated with the code you added to the ValuesController by following the steps below.
You should see log entries covering the lifetime of requests to the API, similar to the below. Because the logging in appsettings.json is configured to “information”, many events were logged. Look for the messages logged from the code you added, for the GET and POST requests.
Request starting HTTP/1.1 GET http://webapichallenge-test.us-east-2.elasticbeanstalk.com/api/values
Executing action method WebApiChallenge.Controllers.ValuesController.Get (WebApiChallenge) with arguments ((null)) - ModelState is Valid
ValuesController Get() Request from 126.96.36.199
Executing ObjectResult, writing value Microsoft.AspNetCore.Mvc.ControllerContext
Executed action WebApiChallenge.Controllers.ValuesController.Get (WebApiChallenge)
Request finished in 193.22ms 200 application/json; charset=utf-8
Request starting HTTP/1.1 POST http://webapichallenge-test.us-east-2.elasticbeanstalk.com/api/values
Executing action method WebApiChallenge.Controllers.ValuesController.Post (WebApiChallenge) with arguments () - ModelState is Invalid
ValuesController Post() Request from 188.8.131.52
Executed action WebApiChallenge.Controllers.ValuesController.Post (WebApiChallenge)
Request finished in 47.133ms 200
Congratulations, you have created and deployed an ASP.NET Web API application using AWS Elastic Beanstalk, created and configured API Gateway as a proxy in front of your API with throttling, and then confirmed that the throttling is enforced using a PowerShell script or Postman.