title: ASP.NET Core 6.0 - Minimal APIs: What parameters are available to Map methods for handling routes?
body: <p>I'm new to Minimal API which is available in ASP.NET Core 6.0 and based on Microsoft's tutorials <a href="https://docs.microsoft.com/en-us/aspnet/core/tutorials/min-web-api?view=aspnetcore-6.0&amp;tabs=visual-studio" rel="nofollow noreferrer">here</a> and <a href="https://docs.microsoft.com/en-us/aspnet/core/fundamentals/minimal-apis?view=aspnetcore-6.0" rel="nofollow noreferrer">here</a>, one can define a sample route for Get method like this:</p>
  <pre><code>app.MapGet(&quot;/&quot;, () =&gt; &quot;Hello World!&quot;);
  </code></pre>
  <p>For the Post method, the following code <a href="https://docs.microsoft.com/en-us/aspnet/core/tutorials/min-web-api?view=aspnetcore-6.0&amp;tabs=visual-studio#add-the-api-code" rel="nofollow noreferrer">is provided</a>:</p>
  <pre><code>...
  app.MapPost(&quot;/todoitems&quot;, async (Todo todo, TodoDb db) =&gt;
  {
      db.Todos.Add(todo);
      await db.SaveChangesAsync();
  
      return Results.Created($&quot;/todoitems/{todo.Id}&quot;, todo);
  });
  ...
  </code></pre>
  <p>In other part of the overview, some <a href="https://docs.microsoft.com/en-us/aspnet/core/fundamentals/minimal-apis?view=aspnetcore-6.0#special-types" rel="nofollow noreferrer">Special types</a> such as: <code>HttpContext</code>, <code>HttpRequest</code>, <code>HttpResponse</code>, ... are introduced and it seems that they are injected as parameters to routing methods (Get, Post, ...); So all these parameters are available:</p>
  <pre><code>app.MapPost(&quot;/test&quot;, (HttpContext context, HttpRequest request, HttpResponse response) =&gt; &quot;Hello world!&quot;);
  </code></pre>
  <p>My questions is: What other parameters are available here:</p>
  <pre><code>app.MapPost(&quot;/test&quot;, (**HERE???**) =&gt; &quot;Hello World!&quot;) {};
  </code></pre>