title: Swagger documentation not importing to Postman as expected
body: <p>I am trying to document an API developed in <code>.NET Core API</code>.</p>
  
  <p>This is the result view in Swagger UI.</p>
  
  <p><a href="https://i.stack.imgur.com/qT9N8.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/qT9N8.png" alt="enter image description here"></a></p>
  
  <p>This is the result view when I import the <code>Swagger.json</code> to PostMan.</p>
  
  <p><a href="https://i.stack.imgur.com/i0xli.png" rel="nofollow noreferrer"><img src="https://i.stack.imgur.com/i0xli.png" alt="enter image description here"></a></p>
  
  <p>As you can see they are not grouped into a <code>FueLogs</code> collection.</p>
  
  <p>This is how I configure the Swagger Doc in Startup.cs</p>
  
  <pre><code>// Swagger API Explorer - You can browse and test the API: /swagger/ui/index.html
  services.AddSwaggerGen(c =&gt;
  {
      c.SwaggerDoc("v1", new Info
      {
          Version = "v1",
          Title = "API",
          Description = "Documentation for API",
          Contact = new Contact { Name = "Dawood Awan", Email = "m.dawood@gmail.com" },
  
      });
      c.DocInclusionPredicate((_, api) =&gt; !string.IsNullOrWhiteSpace(api.GroupName));
  
      c.TagActionsBy(api =&gt; api.GroupName);
  
      // Set the comments path for the Swagger JSON and UI.
      var xmlFile = $"xPT.MyProj.xml";
      var xmlPath = Path.Combine(AppContext.BaseDirectory, xmlFile);
      c.IncludeXmlComments(xmlPath);
  
      c.EnableAnnotations();
  
  });
  </code></pre>
  
  <p>and this is how I document the API Controller.</p>
  
  <pre><code>[Authorize]
  [Route("/api/[controller]")]
  [ApiExplorerSettings(GroupName = "FuelLogs")]
  public class FuelLogsController : BaseController
  {
      /// &lt;summary&gt;
      /// Get fuel log details
      /// &lt;/summary&gt;
      /// &lt;param name="companyId"&gt;The company ID of the asset.&lt;/param&gt;
      /// &lt;param name="fuelLogId"&gt;The fuel Log ID.&lt;/param&gt;
      /// &lt;returns&gt;Fuel log details&lt;/returns&gt;
      /// &lt;response code="200"&gt;The fuel log details `FuelLogDTO`&lt;/response&gt;
      /// &lt;response code="400"&gt;If an error occurs.&lt;/response&gt;
      /// &lt;response code="401"&gt;If user doesn't have permission to perform the action.&lt;/response&gt;
      /// &lt;response code="403"&gt;If the user doesn't have access to this resource.&lt;/response&gt;
      [SwaggerOperation(OperationId = "GetFuelLog")]
      [ProducesResponseType(typeof(FuelLogDTO), 200)]
      [HttpGet("{companyId}/{fuelLogId}")]
      [Authorize(Policy = "View Fuel Logs")]
      public async Task&lt;IActionResult&gt; Get(int companyId, int fuelLogId)
  </code></pre>
  
  <p>What am I doing wrong? How do I get to import into Postman where each controller is grouped into a Collection?</p>
  
  <p>Swagger.json </p>
  
  <pre><code>{"swagger":"2.0","info":{"version":"v1","title":"API","description":"Documentation for API","contact":{"name":"Dawood Awan","email":"m.dawood@gmail.com"}},"paths":{"/api/FuelLogs/{companyId}/{fuelLogId}":{"get":{"tags":["FuelLogs"],"summary":"Get fuel log details","operationId":"GetFuelLog","consumes":[],"produces":["text/plain","application/json","text/json"],"parameters":[{"name":"companyId","in":"path","description":"The company ID of the asset.","required":true,"type":"integer","format":"int32"},{"name":"fuelLogId","in":"path","description":"The fuel Log ID.","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"The fuel log details `FuelLogDTO`","schema":{"$ref":"#/definitions/FuelLogDTO"}},"400":{"description":"If an error occurs."},"401":{"description":"If user doesn't have permission to perform the action."},"403":{"description":"If the user doesn't have access to this resource."}}},"put":{"tags":["FuelLogs"],"summary":"Update an existing fuel Log","operationId":"UpdateFuelLog","consumes":["application/json-patch+json","application/json","text/json","application/*+json"],"produces":[],"parameters":[{"name":"companyId","in":"path","description":"The company ID.","required":true,"type":"integer","format":"int32"},{"name":"fuelLogId","in":"path","description":"The fuel log ID","required":true,"type":"integer","format":"int32"},{"name":"model","in":"body","description":"The details of the fuel Log","required":false,"schema":{"$ref":"#/definitions/FuelLogDTO"}}],"responses":{"200":{"description":"If update is success"},"400":{"description":"If an error occurs."},"401":{"description":"If user doesn't have permission to perform the action."},"403":{"description":"If the user doesn't have access to this resource."}}},"delete":{"tags":["FuelLogs"],"summary":"Delete an existing fuel Log","operationId":"DeleteFuelLog","consumes":[],"produces":[],"parameters":[{"name":"companyId","in":"path","description":"The company ID.","required":true,"type":"integer","format":"int32"},{"name":"fuelLogId","in":"path","description":"The fuel log ID","required":true,"type":"integer","format":"int32"}],"responses":{"200":{"description":"If delete is a success"},"400":{"description":"If an error occurs."},"401":{"description":"If user doesn't have permission to perform the action."},"403":{"description":"If the user doesn't have access to this resource."}}}},"/api/FuelLogs/fuelTypes":{"get":{"tags":["FuelLogs"],"summary":"Get fuel types supported by the system.","operationId":"GetFuelTypes","consumes":[],"produces":["text/plain","application/json","text/json"],"parameters":[],"responses":{"200":{"description":"List of fuel types supported by the system","schema":{"uniqueItems":false,"type":"array","items":{"$ref":"#/definitions/Dropdown"}}},"400":{"description":"If an error occurs."},"401":{"description":"If user doesn't have permission to perform the action."},"403":{"description":"If the user doesn't have access to this resource."}}}},"/api/FuelLogs/detailedList/{companyId}":{"get":{"tags":["FuelLogs"],"summary":"Get a list fuel log. Will return fuel logs filtered by AssetIds, start and end date.\r\nWill only return the number of fuel logs mentioned in pageSize parameter.","operationId":"GetFuelLogs","consumes":[],"produces":["text/plain","application/json","text/json"],"parameters":[{"name":"companyId","in":"path","description":"The company ID of the asset.","required":true,"type":"integer","format":"int32"},{"name":"PageSize","in":"query","required":false,"type":"integer","format":"int32"},{"name":"PageNumber","in":"query","required":false,"type":"integer","format":"int32"},{"name":"SortDirection","in":"query","required":false,"type":"string"},{"name":"SortBy","in":"query","required":false,"type":"string"},{"name":"TempSortBy","in":"query","required":false,"type":"string"},{"name":"TotalItems","in":"query","required":false,"type":"integer","format":"int32"},{"name":"CompanyId","in":"query","description":"The company ID of the asset.","required":false,"type":"integer","format":"int32"},{"name":"SiteId","in":"query","required":false,"type":"integer","format":"int32"},{"name":"CategoryId","in":"query","required":false,"type":"integer","format":"int32"},{"name":"GeofenceId","in":"query","required":false,"type":"integer","format":"int32"},{"name":"AssetId","in":"query","required":false,"type":"integer","format":"int32"},{"name":"DriverId","in":"query","required":false,"type":"integer","format":"int32"},{"name":"ReportId","in":"query","required":false,"type":"integer","format":"int32"},{"name":"AssetIds","in":"query","required":false,"type":"array","items":{"type":"integer","format":"int32"},"collectionFormat":"multi","uniqueItems":false},{"name":"StartDate","in":"query","required":false,"type":"string","format":"date-time"},{"name":"EndDate","in":"query","required":false,"type":"string","format":"date-time"},{"name":"FilterDate","in":"query","required":false,"type":"string","format":"date-time"}],"responses":{"200":{"description":"List of fuel log details `FuelLogDTO`","schema":{"$ref":"#/definitions/PaginationResponse[FuelLogDTO]"}},"400":{"description":"If an error occurs."},"401":{"description":"If user doesn't have permission to perform the action."},"403":{"description":"If the user doesn't have access to this resource."}}}},"/api/FuelLogs/{companyId}":{"post":{"tags":["FuelLogs"],"summary":"Create a new fuel Log.","operationId":"GetFuelLogs","consumes":["application/json-patch+json","application/json","text/json","application/*+json"],"produces":["text/plain","application/json","text/json"],"parameters":[{"name":"companyId","in":"path","description":"The company ID.","required":true,"type":"integer","format":"int32"},{"name":"model","in":"body","description":"The details of the fuel Log","required":false,"schema":{"$ref":"#/definitions/FuelLogDTO"}}],"responses":{"200":{"description":"The newly created fuel Log ID","schema":{"format":"int32","type":"integer"}},"400":{"description":"If an error occurs."},"401":{"description":"If user doesn't have permission to perform the action."},"403":{"description":"If the user doesn't have access to this resource."}}}}},"definitions":{"FuelLogDTO":{"type":"object","properties":{"fuelId":{"format":"int32","type":"integer"},"companyId":{"format":"int32","type":"integer"},"assetId":{"format":"int32","type":"integer"},"reference":{"type":"string"},"currencyId":{"format":"int32","type":"integer"},"currencySymbol":{"type":"string"},"fuelType":{"format":"int32","enum":[1,2,3],"type":"integer"},"fuelTypeName":{"type":"string"},"date":{"format":"date-time","type":"string"},"invoiceNumber":{"type":"string"},"odometerReading":{"format":"int32","type":"integer"},"pricePerLiter":{"format":"double","type":"number"},"quantity":{"format":"double","type":"number"},"total":{"format":"double","type":"number"}}},"Dropdown":{"type":"object","properties":{"id":{"format":"int32","type":"integer"},"stringId":{"type":"string"},"name":{"type":"string"}}},"PaginationResponse[FuelLogDTO]":{"type":"object","properties":{"totalItems":{"format":"int32","type":"integer"},"data":{"uniqueItems":false,"type":"array","items":{"$ref":"#/definitions/FuelLogDTO"}}}}},"securityDefinitions":{"Bearer":{"name":"Authorization","in":"header","type":"apiKey","description":"JWT Authorization header using the Bearer scheme. Example: \"Authorization: Bearer {token}\""}},"security":[{"Bearer":[]}],"tags":[]}
  </code></pre>