I’m guessing you know what Scalar is if you’ve arrived here so let’s just look at the code to implement it into the default .NET 9 Web Api project:
- Install Scalar.AspNetCore from NuGet
- Reference it and call the middleware in Program.cs

- Optionally set the browser to open and load Scalar automatically at launch:

In my sample demo app on GitHub I’ve added a POST weatherforecast endpoint to the project just to show what Scalar looks like with more than a single GET.
When we run the sample app we’ll see a nice GUI with all our endpoints and models listed on the left:

We can click on any particular endpoint to find out more about its request body, responses etc. and we can then click Test Request on the right hand side to open the UI for actually sending a request.
Click on the image for a larger view in a new window.

And finally here’s what the UI looks like when we actually want to send a request. Click on the image for a larger view in a new window.
