title: Why does not working version in asp.net core controller
body: <p>I want to use api version in my .net core project.Then search web and find that's solution.
  Even though do exactly all solutions,but I can't get desired result.
  So if any can help me,Please show me..
  I add Microsoft.AspNetCore.Mvc.Versioning 4.0.0 Package in my project and ..</p>
  <p><strong>StartUp.cs</strong>
  <a href="https://i.stack.imgur.com/oOQsV.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/oOQsV.png" alt="enter image description here" /></a></p>
  <p><a href="https://i.stack.imgur.com/5Cx9K.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/5Cx9K.png" alt="enter image description here" /></a></p>
  <p>Then in my Controller Add Rout Attribute as Shown :</p>
  <pre><code>[ApiController]
  [Authorize]
  [Route(&quot;v{version:apiVersion}/[Controller]&quot;)]
  [ApiVersion(&quot;1.0&quot;)]
  public class SellerController : Controller
  {
      private readonly IBus _client;
      private readonly string AppBaseUrl = MyHttpContext.AppBaseUrl;
      //private readonly IGetUrl _globalUrl;
  
      public SellerController(IBus client/*, IGetUrl globalUrl*/)
      {
          _client = client;
          //_globalUrl = globalUrl;
      }
  
      
      [HttpGet(&quot;/Sellers/{SellerId}&quot;)] // Dashboard   
      public async Task&lt;IActionResult&gt; Info(long SellerId)
      {
             ...
      }
  }
  </code></pre>
  <p>With these code I expected that I can send request to 'Info' method by this url :
  <a href="https://i.stack.imgur.com/fI6UJ.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/fI6UJ.png" alt="enter image description here" /></a></p>
  <p>But that's not working and get 404 error code status.. when I delete &quot;/v1.0&quot; from url and send request, that's working. I will be glad to help me .. Thanks</p>