asp.net mvc – How do I send a bunch of curl commands after publishing in Visual Studio 2017?

I am working on an ASP.net MVC project and noticed that when the web application is published, IIS does not build a cache or anything for the views until a controller is hit. In other words, a visitor can take a long time to load the page if they are the first person to visit the page after the entire project is republished.

To counter this, you would have to manually hit each endpoint with a view in the project once. When the project started, this was a simple task, but as you can imagine now, this can not be maintained.

My question is how do I execute a batch of curl commands in the endpoints with views in the project? I'm not sure where to start. Is there a programmatic way to create the batch command and add it to the AfterPublish event?